diff --git a/tldr/^ b/tldr/^ index 008f9092..699f2ce2 100644 --- a/tldr/^ +++ b/tldr/^ @@ -20,3 +20,7 @@ source: https://github.com/tldr-pages/tldr.git - Replace `string1` with `string2` in the previous command and add `string3` to its end: `^{{string1}}^{{string2}}^{{string3}}` + +- Replace all occurrences of `string1`: + +`^{{string1}}^{{string2}}^:&` diff --git a/tldr/adb-reboot b/tldr/adb-reboot new file mode 100644 index 00000000..d5612024 --- /dev/null +++ b/tldr/adb-reboot @@ -0,0 +1,25 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# adb reboot + +> Reboot a connected Android device or emulator. +> More information: . + +- Reboot the device normally: + +`adb reboot` + +- Reboot the device into bootloader mode: + +`adb reboot bootloader` + +- Reboot the device into recovery mode: + +`adb reboot recovery` + +- Reboot the device into fastboot mode: + +`adb reboot fastboot` diff --git a/tldr/compopt b/tldr/compopt new file mode 100644 index 00000000..3c00cefd --- /dev/null +++ b/tldr/compopt @@ -0,0 +1,17 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# compopt + +> Print or change the completion options for a command. +> More information: . + +- Print the options for the currently executing completion: + +`compopt` + +- Print the completion options for given command: + +`compopt {{command}}` diff --git a/tldr/disown b/tldr/disown new file mode 100644 index 00000000..51b2816d --- /dev/null +++ b/tldr/disown @@ -0,0 +1,26 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# disown + +> Allow sub-processes to live beyond the shell that they are attached to. +> See also the `jobs` command. +> More information: . + +- Disown the current job: + +`disown` + +- Disown a specific job: + +`disown %{{job_number}}` + +- Disown all jobs: + +`disown -a` + +- Keep job (do not disown it), but mark it so that no future SIGHUP is received on shell exit: + +`disown -h %{{job_number}}` diff --git a/tldr/fc b/tldr/fc index 763c95a3..56d9adf1 100644 --- a/tldr/fc +++ b/tldr/fc @@ -5,10 +5,10 @@ source: https://github.com/tldr-pages/tldr.git --- # fc -> Open the most recent command and edit it. +> Open the most recent command for editing and then run it. > More information: . -- Open in the default system editor: +- Open the last command in the default system editor and run it after editing: `fc` @@ -24,6 +24,14 @@ source: https://github.com/tldr-pages/tldr.git `fc -l -r` -- List commands in a given interval: +- Edit and run a command from history: + +`fc {{number}}` + +- Edit commands in a given interval and run them: `fc '{{416}}' '{{420}}'` + +- Display help: + +`fc --help` diff --git a/tldr/git-standup b/tldr/git-standup index 42954ddb..518a645b 100644 --- a/tldr/git-standup +++ b/tldr/git-standup @@ -15,7 +15,7 @@ source: https://github.com/tldr-pages/tldr.git - Show a given author's commits from the last 10 days and whether they are GPG signed: -`git standup -a {[name|email}} -d {{10}} -g` +`git standup -a {{name|email}} -d {{10}} -g` - Show all the commits from all contributors for the last 10 days: diff --git a/tldr/help b/tldr/help new file mode 100644 index 00000000..1af87157 --- /dev/null +++ b/tldr/help @@ -0,0 +1,33 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# help + +> Display information about Bash builtin commands. +> More information: . + +- Display the full list of builtin commands: + +`help` + +- Print instructions on how to use the `while` loop construct: + +`help while` + +- Print instructions on how to use the `for` loop construct: + +`help for` + +- Print instructions on how to use `[[ ]]` for conditional commands: + +`help [[ ]]` + +- Print instruction on how to use `(( ))` to evaluate arithmetic expressions: + +`help \( \)` + +- Print instructions on how to use the `cd` command: + +`help cd` diff --git a/tldr/linux/pve-firewall b/tldr/linux/pve-firewall new file mode 100644 index 00000000..6ff853f4 --- /dev/null +++ b/tldr/linux/pve-firewall @@ -0,0 +1,37 @@ +--- +syntax: markdown +tags: [tldr, linux] +source: https://github.com/tldr-pages/tldr.git +--- +# pve-firewall + +> Manage Proxmox VE Firewall. +> More information: . + +- Compile and print all firewall rules: + +`pve-firewall compile` + +- Show information about the local network: + +`pve-firewall localnet` + +- Restart the Proxmox VE Firewall service: + +`pve-firewall restart` + +- Start the Proxmox VE Firewall service: + +`pve-firewall start` + +- Stop the Proxmox VE Firewall service: + +`pve-firewall stop` + +- Simulate all firewall rules: + +`pve-firewall simulate` + +- Show the status of Proxmox VE Firewall: + +`pve-firewall status` diff --git a/tldr/linux/pvecm b/tldr/linux/pvecm new file mode 100644 index 00000000..c8d0f4d6 --- /dev/null +++ b/tldr/linux/pvecm @@ -0,0 +1,37 @@ +--- +syntax: markdown +tags: [tldr, linux] +source: https://github.com/tldr-pages/tldr.git +--- +# pvecm + +> Proxmox VE Cluster Manager. +> More information: . + +- Add the current node to an existing cluster: + +`pvecm add {{hostname_or_ip}}` + +- Add a node to the cluster configuration (internal use): + +`pvecm addnode {{node}}` + +- Display the version of the cluster join API available on this node: + +`pvecm apiver` + +- Generate new cluster configuration: + +`pvecm create {{clustername}}` + +- Remove a node from the cluster configuration: + +`pvecm delnode {{node}}` + +- Display the local view of the cluster nodes: + +`pvecm nodes` + +- Display the local view of the cluster status: + +`pvecm status` diff --git a/tldr/linux/pveperf b/tldr/linux/pveperf new file mode 100644 index 00000000..fe895b3a --- /dev/null +++ b/tldr/linux/pveperf @@ -0,0 +1,13 @@ +--- +syntax: markdown +tags: [tldr, linux] +source: https://github.com/tldr-pages/tldr.git +--- +# pveperf + +> A benchmarking tool in Proxmox Server. Gather CPU and hard disk performance data for the hard disk. +> More information: . + +- Show CPU and hard disk performance data for the hard disk mounted at `/`: + +`pveperf` diff --git a/tldr/linux/qm-nbdstop b/tldr/linux/qm-nbdstop new file mode 100644 index 00000000..dce1e81b --- /dev/null +++ b/tldr/linux/qm-nbdstop @@ -0,0 +1,13 @@ +--- +syntax: markdown +tags: [tldr, linux] +source: https://github.com/tldr-pages/tldr.git +--- +# qm nbdstop + +> Stop embedded nbd server. +> More information: . + +- Stop embedded nbd server: + +`qm nbdstop {{VM_ID}}` diff --git a/tldr/linux/qm-stop b/tldr/linux/qm-stop new file mode 100644 index 00000000..4181d918 --- /dev/null +++ b/tldr/linux/qm-stop @@ -0,0 +1,25 @@ +--- +syntax: markdown +tags: [tldr, linux] +source: https://github.com/tldr-pages/tldr.git +--- +# qm stop + +> Stop a virtual machine. +> More information: . + +- Stop a virtual machine immediately: + +`qm stop {{VM_ID}}` + +- Stop a virtual machine and wait for at most 10 seconds: + +`qm stop --timeout {{10}} {{VM_ID}}` + +- Stop a virtual machine and skip lock (only root can use this option): + +`qm stop --skiplock {{true}} {{VM_ID}}` + +- Stop a virtual machine and don't deactivate storage volumes: + +`qm stop --keepActive {{true}} {{VM_ID}}` diff --git a/tldr/linux/sestatus b/tldr/linux/sestatus new file mode 100644 index 00000000..521d751b --- /dev/null +++ b/tldr/linux/sestatus @@ -0,0 +1,21 @@ +--- +syntax: markdown +tags: [tldr, linux] +source: https://github.com/tldr-pages/tldr.git +--- +# sestatus + +> Print the current SELinux status. +> More information: . + +- Print the current status: + +`sestatus` + +- Print the current states of all policy booleans: + +`sestatus -b` + +- Print the current file and process contexts: + +`sestatus -v` diff --git a/tldr/linux/speaker-test b/tldr/linux/speaker-test new file mode 100644 index 00000000..edc7572e --- /dev/null +++ b/tldr/linux/speaker-test @@ -0,0 +1,26 @@ +--- +syntax: markdown +tags: [tldr, linux] +source: https://github.com/tldr-pages/tldr.git +--- +# speaker-test + +> Speaker test tone generator for ALSA. +> See also: `aplay`, `arecord`, `amixer`. +> More information: . + +- Test the default speakers with pink noise: + +`speaker-test` + +- Test the default speakers with a sine wave: + +`speaker-test {{-t|--test}} sine {{-f|--frequency}} {{frequency}}` + +- Test the default speakers with a predefined WAV file: + +`speaker-test {{-t|--test}} wav` + +- Test the default speakers with a WAV file: + +`speaker-test {{-t|--test}} wav {{-w|--wavfile}} {{path/to/file}}` diff --git a/tldr/linux/vzdump b/tldr/linux/vzdump new file mode 100644 index 00000000..2bf73c26 --- /dev/null +++ b/tldr/linux/vzdump @@ -0,0 +1,33 @@ +--- +syntax: markdown +tags: [tldr, linux] +source: https://github.com/tldr-pages/tldr.git +--- +# vzdump + +> Backup Utility for virtual machines and containers. +> More information: . + +- Dump a guest virtual machine into the default dump directory (usually `/var/lib/vz/dump/`), excluding snapshots: + +`vzdump {{vm_id}}` + +- Back up the guest virtual machines with the IDs 101, 102, and 103: + +`vzdump {{101 102 103}}` + +- Dump a guest virtual machine using a specific mode: + +`vzdump {{vm_id}} --mode {{suspend|snapshot}}` + +- Back up all guest systems and send an notification email to the root and admin users: + +`vzdump --all --mode {{suspend}} --mailto {{root}} --mailto {{admin}}` + +- Use snapshot mode (no downtime required) and a non-default dump directory: + +`vzdump {{vm_id}} --dumpdir {{path/to/directory}} --mode {{snapshot}}` + +- Back up all guest virtual machines excluding the IDs 101 and 102: + +`vzdump --mode {{suspend}} --exclude {{101, 102}}` diff --git a/tldr/npm-restart b/tldr/npm-restart new file mode 100644 index 00000000..bb406a34 --- /dev/null +++ b/tldr/npm-restart @@ -0,0 +1,12 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# npm restart + +> This command is an alias of `npm run restart`. + +- View documentation for the original command: + +`tldr npm run` diff --git a/tldr/npm-run b/tldr/npm-run new file mode 100644 index 00000000..a23d085c --- /dev/null +++ b/tldr/npm-run @@ -0,0 +1,33 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# npm run + +> Run a script. +> More information: . + +- Run a script: + +`npm run {{script_name}}` + +- Pass arguments to a script: + +`npm run {{script_name}} -- {{argument}} {{--option}}` + +- Run a script named `start`: + +`npm start` + +- Run a script named `stop`: + +`npm stop` + +- Run a script named `restart`: + +`npm restart` + +- Run a script named `test`: + +`npm test` diff --git a/tldr/npm-start b/tldr/npm-start new file mode 100644 index 00000000..b2713376 --- /dev/null +++ b/tldr/npm-start @@ -0,0 +1,12 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# npm start + +> This command is an alias of `npm run start`. + +- View documentation for the original command: + +`tldr npm run` diff --git a/tldr/npm-stop b/tldr/npm-stop new file mode 100644 index 00000000..deb6868f --- /dev/null +++ b/tldr/npm-stop @@ -0,0 +1,12 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# npm stop + +> This command is an alias of `npm run stop`. + +- View documentation for the original command: + +`tldr npm run` diff --git a/tldr/npm-test b/tldr/npm-test new file mode 100644 index 00000000..7edd93e3 --- /dev/null +++ b/tldr/npm-test @@ -0,0 +1,12 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# npm test + +> This command is an alias of `npm run test`. + +- View documentation for the original command: + +`tldr npm run` diff --git a/tldr/ntfy b/tldr/ntfy new file mode 100644 index 00000000..28a99977 --- /dev/null +++ b/tldr/ntfy @@ -0,0 +1,33 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# ntfy + +> Send and receive HTTP POST notifications. +> More information: . + +- Send a message to the `security` topic: + +`ntfy pub security "{{Front door has been opened.}}"` + +- Send with a title, priority and tags: + +`ntfy publish --title="{{Someone bought your item}}" --priority={{high}} --tags={{duck}} {{ebay}} "{{Someone just bought your item: Platypus Sculpture}}"` + +- Send at 8:30am: + +`ntfy pub --at=8:30am {{delayed_topic}} "{{Time for school, sleepyhead...}}"` + +- Trigger a webhook: + +`ntfy trigger {{my_webhook}}` + +- Subscribe to a topic (Ctrl-C to stop listening): + +`ntfy sub {{home_automation}}` + +- Display help: + +`ntfy --help` diff --git a/tldr/redshift b/tldr/redshift index 39018b48..f3505833 100644 --- a/tldr/redshift +++ b/tldr/redshift @@ -24,6 +24,6 @@ source: https://github.com/tldr-pages/tldr.git `redshift -g {{red}}:{{green}}:{{blue}}` -- Turn on Redshift with a constant unchanging color temperature: +- [P]urge existing temperature changes and set a constant unchanging color temperature in [O]ne-shot mode: -`redshift -O {{temperature}}` +`redshift -PO {{temperature}}` diff --git a/tldr/unset b/tldr/unset new file mode 100644 index 00000000..91d25b61 --- /dev/null +++ b/tldr/unset @@ -0,0 +1,21 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# unset + +> Remove shell variables or functions. +> More information: . + +- Remove the variable `foo`, or if the variable doesn't exist, remove the function `foo`: + +`unset {{foo}}` + +- Remove the variables foo and bar: + +`unset -v {{foo}} {{bar}}` + +- Remove the function my_func: + +`unset -f {{my_func}}` diff --git a/tldr/wget2 b/tldr/wget2 new file mode 100644 index 00000000..72e01982 --- /dev/null +++ b/tldr/wget2 @@ -0,0 +1,43 @@ +--- +syntax: markdown +tags: [tldr, common] +source: https://github.com/tldr-pages/tldr.git +--- +# wget2 + +> An improved version of `wget` for downloading files from the web. +> Supports HTTP, HTTPS, and HTTP/2 protocols with enhanced performance. +> By default, `wget2` uses multiple threads for faster downloads. +> More information: . + +- Download the contents of a URL to a file using multiple threads (default behavior differs from `wget`): + +`wget2 {{https://example.com/foo}}` + +- Limit the number of threads used for downloading (default is 5 threads): + +`wget2 --max-threads={{10}} {{https://example.com/foo}}` + +- Download a single web page and all its resources (scripts, stylesheets, images, etc.): + +`wget2 --page-requisites --convert-links {{https://example.com/somepage.html}}` + +- Mirror a website, but do not ascend to the parent directory (does not download embedded page elements): + +`wget2 --mirror --no-parent {{https://example.com/somepath/}}` + +- Limit the download speed and the number of connection retries: + +`wget2 --limit-rate={{300k}} --tries={{100}} {{https://example.com/somepath/}}` + +- Continue an incomplete download (behavior is consistent with `wget`): + +`wget2 --continue {{https://example.com}}` + +- Download all URLs stored in a text file to a specific directory: + +`wget2 --directory-prefix {{path/to/directory}} --input-file {{URLs.txt}}` + +- Download a file from an HTTP server using Basic Auth (also works for HTTPS): + +`wget2 --user={{username}} --password={{password}} {{https://example.com}}` diff --git a/tldr/windows/sdelete b/tldr/windows/sdelete new file mode 100644 index 00000000..56e8d286 --- /dev/null +++ b/tldr/windows/sdelete @@ -0,0 +1,25 @@ +--- +syntax: markdown +tags: [tldr, windows] +source: https://github.com/tldr-pages/tldr.git +--- +# sdelete + +> Securely delete file/directory from disk, or clean the free space on a volume/physical disk. +> More information: . + +- Delete files with 3 [p]asses: + +`sdelete -p 3 {{path o ile1 path o ile2 ...}}` + +- Delete folders and its [s]ubdirectories with 1 pass (default): + +`sdelete -s {{path o\directory1 path o\directory2 ...}}` + +- Clean the free space of volume D: with 3 [p]asses: + +`sdelete -p 3 D:` + +- Clean the free space with [z]eros of physical disk 2, which should not contain any volumes to be cleaned: + +`sdelete -z 2` diff --git a/tldr/windows/sdelete64 b/tldr/windows/sdelete64 new file mode 100644 index 00000000..c6f9f514 --- /dev/null +++ b/tldr/windows/sdelete64 @@ -0,0 +1,12 @@ +--- +syntax: markdown +tags: [tldr, windows] +source: https://github.com/tldr-pages/tldr.git +--- +# sdelete64 + +> This command is the 64 bit version of `sdelete`. + +- View documentation for the original command: + +`tldr sdelete`