Update cheatsheets

This commit is contained in:
ivuorinen
2026-02-21 00:26:53 +00:00
parent d1fa360568
commit fac4aab4b1
15 changed files with 93 additions and 24 deletions

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# adb disconnect
> This command has been moved to `adb connect`.
> The examples for this command have been moved together with `adb connect`.
- View documentation for `adb disconnect`:

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# adb pair
> This command has been moved to `adb connect`.
> The examples for this command have been moved together with `adb connect`.
- View documentation for `adb pair`:

34
tldr/azcopy Normal file
View File

@@ -0,0 +1,34 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# azcopy
> Copy data to and from Azure Storage.
> See also: `az storage`.
> More information: <https://learn.microsoft.com/en-us/azure/storage/common/storage-use-azcopy-v10#list-of-commands>.
- Log in to an Azure Tenant:
`azcopy login`
- Upload a local file:
`azcopy {{[c|copy]}} '{{path/to/source_file}}' 'https://{{storage_account_name}}.blob.core.windows.net/{{container_name}}/{{blob_name}}'`
- Upload files with `.txt` and `.jpg` extensions:
`azcopy {{[c|copy]}} '{{path/to/source_directory}}' 'https://{{storage_account_name}}.blob.core.windows.net/{{container_name}}' --include-pattern '*.txt;*.jpg'`
- Copy a container directly between two Azure storage accounts:
`azcopy {{[c|copy]}} 'https://{{source_storage_account_name}}.blob.core.windows.net/{{container_name}}' 'https://{{destination_storage_account_name}}.blob.core.windows.net/{{container_name}}'`
- Synchronize a local directory and delete files in the destination if they no longer exist in the source:
`azcopy {{[s|sync]}} '{{path/to/source_directory}}' 'https://{{storage_account_name}}.blob.core.windows.net/{{container_name}}' --delete-destination true`
- Display help:
`azcopy {{[-h|--help]}}`

33
tldr/fresh Normal file
View File

@@ -0,0 +1,33 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# fresh
> A fully-featured terminal-based text editor.
> More information: <https://getfresh.dev/docs/>.
- Open a file:
`fresh {{path/to/file}}`
- Search for a pattern:
`<Ctrl f>{{search_pattern}}<Enter>`
- Replace a pattern:
`<Ctrl r>{{search_pattern}}<Enter>{{replacement}}<Enter>`
- Show File Explorer:
`<Ctrl e>`
- Save file:
`<Ctrl s>`
- Quit:
`<Ctrl q>`

View File

@@ -10,11 +10,11 @@ source: https://github.com/tldr-pages/tldr.git
- Revert the most recent commit:
`git revert {{HEAD}}`
`git revert HEAD`
- Revert the 5th last commit:
`git revert HEAD~{{4}}`
`git revert HEAD~4`
- Revert a specific commit:
@@ -22,11 +22,11 @@ source: https://github.com/tldr-pages/tldr.git
- Revert multiple commits:
`git revert {{branch_name~5..branch_name~2}}`
`git revert {{branch_name~5}}..{{branch_name~2}}`
- Don't create new commits, just change the working tree:
`git revert {{[-n|--no-commit]}} {{0c01a9..9a1743}}`
`git revert {{[-n|--no-commit]}} {{0c01a9}}..{{9a1743}}`
- Cancel a Git revert after a merge conflict:

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# trash-empty
> This command has been moved to `trash`.
> The examples for this command have been moved together with `trash`.
- View documentation for `trash-empty`:

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# trash-list
> This command has been moved to `trash`.
> The examples for this command have been moved together with `trash`.
- View documentation for `trash-list`:

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# trash-restore
> This command has been moved to `trash`.
> The examples for this command have been moved together with `trash`.
- View documentation for `trash-restore`:

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# trash-rm
> This command has been moved to `trash`.
> The examples for this command have been moved together with `trash`.
- View documentation for `trash-rm`:

View File

@@ -9,29 +9,29 @@ source: https://github.com/tldr-pages/tldr.git
> Some subcommands such as `req` have their own usage documentation.
> More information: <https://docs.openssl.org/master/man1/openssl/>.
- Generate a private key and encrypt the output file using AES256:
- Generate a private key and encrypt the output file using AES-256:
`openssl genpkey -algorithm {{rsa|ec}} -out {{private.key}} -aes256`
`openssl genpkey -algorithm {{rsa|ec}} -out {{path/to/private.key}} -aes256`
- Generate the corresponding public key from private key `private.key` using `rsa`:
- Generate the corresponding public key from the private key `private.key` using `rsa`:
`openssl rsa -in {{private.key}} -pubout -out {{public.key}}`
`openssl rsa -in {{path/to/private.key}} -pubout -out {{path/to/public.key}}`
- Generate a self-signed certificate valid for a specified number of days (`365`):
- Generate a self-signed certificate valid for a specified number of days (365):
`openssl req -new -x509 -key {{private.key}} -out {{certificate.crt}} -days {{365}}`
`openssl req -new -x509 -key {{path/to/private.key}} -out {{path/to/certificate.crt}} -days 365`
- Convert certificate to `pem` or `der` format:
- Convert a certificate to `.pem` or `.der` format:
`openssl x509 -in {{certificate.crt}} -out {{certificate.pem|certificate.der}} -outform {{pem|der}}`
`openssl x509 -in {{path/to/certificate.crt}} -out {{path/to/certificate.pem|path/to/certificate.der}} -outform {{pem|der}}`
- Check certificate details:
`openssl x509 -in {{certificate.crt}} -text -noout`
`openssl x509 -in {{path/to/certificate.crt}} -text -noout`
- Generate a certificate signing request (CSR):
`openssl req -new -key {{private.key}} -out {{request.csr}}`
`openssl req -new -key {{path/to/private.key}} -out {{path/to/request.csr}}`
- Display help:

View File

@@ -6,6 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# qr
> Generate QR codes in the terminal with ANSI VT-100 escape codes.
> See also: `qrencode`.
> More information: <https://manned.org/qr>.
- Generate a QR code:

View File

@@ -6,6 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# qrencode
> QR Code generator. Supports PNG and EPS.
> See also: `qr`.
> More information: <https://manned.org/qrencode>.
- Convert a string to a QR code and save to an output file:

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# sfdk emulator device-model-list
> This command has been moved to `sfdk emulator device-model-show`.
> The examples for this command have been moved together with `sfdk emulator device-model-show`.
- View documentation for `sfdk emulator device-model-show`:

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# sfdk emulator remove
> This command has been moved to `sfdk emulator install`.
> The examples for this command have been moved together with `sfdk emulator install`.
- View documentation for `sfdk emulator install`:

View File

@@ -25,6 +25,6 @@ source: https://github.com/tldr-pages/tldr.git
`watchexec {{[-r|--restart]}} --stop-signal {{SIGKILL}} {{my_server}}`
- Restart the execution of a command when any Java source file in the current directory changes, sending `SIGKILL` and only checking for updates every `n`ms:
- Restart the execution of a command when any Java source file in the current directory changes, sending `SIGKILL` and only checking for updates every `10000` ms:
`watchexec {{[-r|--restart]}} --stop-signal {{SIGKILL}} --poll {{10000}} {{[-e|--exts]}} {{java}} {{command}}`
`watchexec {{[-r|--restart]}} --stop-signal {{SIGKILL}} --poll 10000 {{[-e|--exts]}} {{java}} {{command}}`