mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-02-16 10:49:07 +00:00
Update cheatsheets
This commit is contained in:
@@ -14,15 +14,15 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Print how long users have been connected in hours:
|
||||
|
||||
`ac --individual-totals`
|
||||
`ac {{[-p|--individual-totals]}}`
|
||||
|
||||
- Print how long a particular user has been connected in hours:
|
||||
|
||||
`ac --individual-totals {{username}}`
|
||||
`ac {{[-p|--individual-totals]}} {{username}}`
|
||||
|
||||
- Print how long a particular user has been connected in hours per day (with total):
|
||||
|
||||
`ac --daily-totals --individual-totals {{username}}`
|
||||
`ac {{[-d|--daily-totals]}} {{[-p|--individual-totals]}} {{username}}`
|
||||
|
||||
- Also display additional details:
|
||||
|
||||
|
||||
@@ -5,21 +5,34 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# at
|
||||
|
||||
> Executes commands at a specified time.
|
||||
> More information: <https://manned.org/at.1>.
|
||||
> Execute commands once at a later time.
|
||||
> Results will be sent to the users mail.
|
||||
> More information: <https://manned.org/at>.
|
||||
|
||||
- Open an `at` prompt to create a new set of scheduled commands, press `Ctrl + D` to save and exit:
|
||||
- Start the `atd` daemon:
|
||||
|
||||
`systemctl start atd`
|
||||
|
||||
- Create commands interactively and execute them in 5 minutes (press `<Ctrl d>` when done):
|
||||
|
||||
`at now + 5 minutes`
|
||||
|
||||
- Create commands interactively and execute them at a specific time:
|
||||
|
||||
`at {{hh:mm}}`
|
||||
|
||||
- Execute the commands and email the result using a local mailing program such as Sendmail:
|
||||
- Execute a command from `stdin` at 10:00 AM today:
|
||||
|
||||
`at {{hh:mm}} -m`
|
||||
`echo "{{command}}" | at 1000`
|
||||
|
||||
- Execute a script at the given time:
|
||||
- Execute commands from a given file next Tuesday:
|
||||
|
||||
`at {{hh:mm}} -f {{path/to/file}}`
|
||||
`at -f {{path/to/file}} 9:30 PM Tue`
|
||||
|
||||
- Display a system notification at 11pm on February 18th:
|
||||
- List all queued jobs for the current user (same as `atq`):
|
||||
|
||||
`echo "notify-send '{{Wake up!}}'" | at {{11pm}} {{Feb 18}}`
|
||||
`at -l`
|
||||
|
||||
- View a specied job:
|
||||
|
||||
`at -c {{job_number}}`
|
||||
|
||||
@@ -6,20 +6,20 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
# atool
|
||||
|
||||
> Manage archives of various formats.
|
||||
> More information: <https://www.nongnu.org/atool/>.
|
||||
> More information: <https://manned.org/man/atool>.
|
||||
|
||||
- List files in a Zip archive:
|
||||
|
||||
`atool --list {{path/to/archive.zip}}`
|
||||
`atool {{[-l|--list]}} {{path/to/archive.zip}}`
|
||||
|
||||
- Unpack a tar.gz archive into a new subdirectory (or current directory if it contains only one file):
|
||||
|
||||
`atool --extract {{path/to/archive.tar.gz}}`
|
||||
`atool {{[-x|--extract]}} {{path/to/archive.tar.gz}}`
|
||||
|
||||
- Create a new 7z archive with two files:
|
||||
|
||||
`atool --add {{path/to/archive.7z}} {{path/to/file1 path/to/file2 ...}}`
|
||||
`atool {{[-a|--add]}} {{path/to/archive.7z}} {{path/to/file1 path/to/file2 ...}}`
|
||||
|
||||
- Extract all Zip and rar archives in the current directory:
|
||||
|
||||
`atool --each --extract {{*.zip *.rar}}`
|
||||
`atool {{[-e|--each]}} {{[-E|--extract]}} {{*.zip *.rar}}`
|
||||
|
||||
23
tldr/linux/batch
Normal file
23
tldr/linux/batch
Normal file
@@ -0,0 +1,23 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, linux]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# batch
|
||||
|
||||
> Execute commands at a later time when the system load levels permit.
|
||||
> Results will be sent to the user's mail.
|
||||
> See also: `at`, `atq`, `atrm` `mail`.
|
||||
> More information: <https://manned.org/batch>.
|
||||
|
||||
- Start the `atd` daemon:
|
||||
|
||||
`systemctl start atd`
|
||||
|
||||
- Execute commands from `stdin` (press `<Ctrl d>` when done):
|
||||
|
||||
`batch`
|
||||
|
||||
- Execute a command from `stdin`:
|
||||
|
||||
`echo "{{./make_db_backup.sh}}" | batch`
|
||||
@@ -11,11 +11,11 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- View security context of a file:
|
||||
|
||||
`ls -lZ {{path/to/file}}`
|
||||
`ls {{[-lZ|-l --context]}} {{path/to/file}}`
|
||||
|
||||
- Change the security context of a target file, using a reference file:
|
||||
|
||||
`chcon --reference={{reference_file}} {{target_file}}`
|
||||
`chcon --reference {{reference_file}} {{target_file}}`
|
||||
|
||||
- Change the full SELinux security context of a file:
|
||||
|
||||
@@ -23,16 +23,16 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Change only the user part of SELinux security context:
|
||||
|
||||
`chcon -u {{user}} {{filename}}`
|
||||
`chcon {{[-u|--user]}} {{user}} {{filename}}`
|
||||
|
||||
- Change only the role part of SELinux security context:
|
||||
|
||||
`chcon -r {{role}} {{filename}}`
|
||||
`chcon {{[-r|--role]}} {{role}} {{filename}}`
|
||||
|
||||
- Change only the type part of SELinux security context:
|
||||
|
||||
`chcon -t {{type}} {{filename}}`
|
||||
`chcon {{[-t|--type]}} {{type}} {{filename}}`
|
||||
|
||||
- Change only the range/level part of SELinux security context:
|
||||
|
||||
`chcon -l {{range/level}} {{filename}}`
|
||||
`chcon {{[-l|--range]}} {{range/level}} {{filename}}`
|
||||
|
||||
@@ -10,16 +10,16 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Update a user's "Name" field in the output of `finger`:
|
||||
|
||||
`chfn -f {{new_display_name}} {{username}}`
|
||||
`chfn {{[-f|--full-name]}} {{new_display_name}} {{username}}`
|
||||
|
||||
- Update a user's "Office Room Number" field for the output of `finger`:
|
||||
|
||||
`chfn -o {{new_office_room_number}} {{username}}`
|
||||
`chfn {{[-o|--office]}} {{new_office_room_number}} {{username}}`
|
||||
|
||||
- Update a user's "Office Phone Number" field for the output of `finger`:
|
||||
|
||||
`chfn -p {{new_office_telephone_number}} {{username}}`
|
||||
`chfn {{[-p|--office-phone]}} {{new_office_telephone_number}} {{username}}`
|
||||
|
||||
- Update a user's "Home Phone Number" field for the output of `finger`:
|
||||
|
||||
`chfn -h {{new_home_telephone_number}} {{username}}`
|
||||
`chfn {{[-h|--home-phone]}} {{new_home_telephone_number}} {{username}}`
|
||||
|
||||
@@ -19,11 +19,11 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Split a file every 5 lines, ignoring exact-division error:
|
||||
|
||||
`csplit -k {{path/to/file}} 5 {*}`
|
||||
`csplit {{[-k|--keep-files]}} {{path/to/file}} 5 {*}`
|
||||
|
||||
- Split a file at line 5 and use a custom prefix for the output files:
|
||||
|
||||
`csplit {{path/to/file}} 5 -f {{prefix}}`
|
||||
`csplit {{path/to/file}} 5 {{[-f|--prefix]}} {{prefix}}`
|
||||
|
||||
- Split a file at a line matching a regular expression:
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
# datamash
|
||||
|
||||
> Perform basic numeric, textual and statistical operations on input textual data files.
|
||||
> More information: <https://www.gnu.org/software/datamash/>.
|
||||
> More information: <https://www.gnu.org/software/datamash/manual/html_node/Invoking-datamash.html>.
|
||||
|
||||
- Get max, min, mean and median of a single column of numbers:
|
||||
|
||||
@@ -28,7 +28,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
3
|
||||
4
|
||||
5
|
||||
5' | datamash -R {{number_of_decimals_wanted}} mean 1`
|
||||
5' | datamash {{[-R|--round]}} {{number_of_decimals_wanted}} mean 1`
|
||||
|
||||
- Get the mean of a single column of numbers ignoring "Na" and "NaN" (literal) strings:
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
# ddrescue
|
||||
|
||||
> Data recovery tool that reads data from damaged block devices.
|
||||
> More information: <https://www.gnu.org/software/ddrescue/>.
|
||||
> More information: <https://www.gnu.org/software/ddrescue/manual/ddrescue_manual.html#Invoking-ddrescue>.
|
||||
|
||||
- Take an image of a device, creating a log file:
|
||||
|
||||
@@ -14,4 +14,4 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Clone Disk A to Disk B, creating a log file:
|
||||
|
||||
`sudo ddrescue --force --no-scrape {{/dev/sdX}} {{/dev/sdY}} {{path/to/log.txt}}`
|
||||
`sudo ddrescue {{[-f|--force]}} {{[-n|--no-scrape]}} {{/dev/sdX}} {{/dev/sdY}} {{path/to/log.txt}}`
|
||||
|
||||
@@ -14,4 +14,4 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Show all changes, outlining conflicts:
|
||||
|
||||
`diff3 --show-all {{path/to/file1}} {{path/to/file2}} {{path/to/file3}}`
|
||||
`diff3 {{[-A|--show-all]}} {{path/to/file1}} {{path/to/file2}} {{path/to/file3}}`
|
||||
|
||||
@@ -10,12 +10,12 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Fold lines in a fixed width:
|
||||
|
||||
`fold --width {{width}} {{path/to/file}}`
|
||||
`fold {{[-w|--width]}} {{width}} {{path/to/file}}`
|
||||
|
||||
- Count width in bytes (the default is to count in columns):
|
||||
|
||||
`fold --bytes --width {{width_in_bytes}} {{path/to/file}}`
|
||||
`fold {{[-b|--bytes]}} {{[-w|--width]}} {{width_in_bytes}} {{path/to/file}}`
|
||||
|
||||
- Break the line after the rightmost blank within the width limit:
|
||||
|
||||
`fold --spaces --width {{width}} {{path/to/file}}`
|
||||
`fold {{[-s|--spaces]}} {{[-w|--width]}} {{width}} {{path/to/file}}`
|
||||
|
||||
@@ -15,20 +15,20 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Write individual execution counts for every basic block:
|
||||
|
||||
`gcov --all-blocks {{path/to/file.cpp}}`
|
||||
`gcov {{[-a|--all-blocks]}} {{path/to/file.cpp}}`
|
||||
|
||||
- Write branch frequencies to the output file and print summary information to `stdout` as a percentage:
|
||||
|
||||
`gcov --branch-probabilities {{path/to/file.cpp}}`
|
||||
`gcov {{[-b|--branch-probabilities]}} {{path/to/file.cpp}}`
|
||||
|
||||
- Write branch frequencies as the number of branches taken, rather than the percentage:
|
||||
|
||||
`gcov --branch-counts {{path/to/file.cpp}}`
|
||||
`gcov {{[-c|--branch-counts]}} {{path/to/file.cpp}}`
|
||||
|
||||
- Do not create a `gcov` output file:
|
||||
|
||||
`gcov --no-output {{path/to/file.cpp}}`
|
||||
`gcov {{[-n|--no-output]}} {{path/to/file.cpp}}`
|
||||
|
||||
- Write file level as well as function level summaries:
|
||||
|
||||
`gcov --function-summaries {{path/to/file.cpp}}`
|
||||
`gcov {{[-f|--function-summaries]}} {{path/to/file.cpp}}`
|
||||
|
||||
@@ -6,20 +6,20 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
# getopt
|
||||
|
||||
> Parse command-line arguments.
|
||||
> More information: <https://www.gnu.org/software/libc/manual/html_node/Getopt.html>.
|
||||
> More information: <https://manned.org/getopt>.
|
||||
|
||||
- Parse optional `verbose`/`version` flags with shorthands:
|
||||
|
||||
`getopt --options vV --longoptions verbose,version -- --version --verbose`
|
||||
`getopt {{[-o|--options]}} vV {{[-l|--longoptions]}} verbose,version -- --version --verbose`
|
||||
|
||||
- Add a `--file` option with a required argument with shorthand `-f`:
|
||||
|
||||
`getopt --options f: --longoptions file: -- --file=somefile`
|
||||
`getopt {{[-o|--options]}} f: {{[-l|--longoptions]}} file: -- --file=somefile`
|
||||
|
||||
- Add a `--verbose` option with an optional argument with shorthand `-v`, and pass a non-option parameter `arg`:
|
||||
|
||||
`getopt --options v:: --longoptions verbose:: -- --verbose arg`
|
||||
`getopt {{[-o|--options]}} v:: {{[-l|--longoptions]}} verbose:: -- --verbose arg`
|
||||
|
||||
- Accept a `-r` and `--verbose` flag, a `--accept` option with an optional argument and add a `--target` with a required argument option with shorthands:
|
||||
|
||||
`getopt --options rv::s::t: --longoptions verbose,source::,target: -- -v --target target`
|
||||
`getopt {{[-o|--options]}} rv::s::t: {{[-l|--longoptions]}} verbose,source::,target: -- -v --target target`
|
||||
|
||||
@@ -10,12 +10,12 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Install GRUB on a BIOS system:
|
||||
|
||||
`grub-install --target={{i386-pc}} {{path/to/device}}`
|
||||
`grub-install --target {{i386-pc}} {{path/to/device}}`
|
||||
|
||||
- Install GRUB on an UEFI system:
|
||||
|
||||
`grub-install --target={{x86_64-efi}} --efi-directory={{path/to/efi_directory}} --bootloader-id={{GRUB}}`
|
||||
`grub-install --target {{x86_64-efi}} --efi-directory {{path/to/efi_directory}} --bootloader-id {{GRUB}}`
|
||||
|
||||
- Install GRUB pre-loading specific modules:
|
||||
|
||||
`grub-install --target={{x86_64-efi}} --efi-directory={{path/to/efi_directory}} --modules="{{part_gpt part_msdos}}"`
|
||||
`grub-install --target {{x86_64-efi}} --efi-directory {{path/to/efi_directory}} --modules "{{part_gpt part_msdos}}"`
|
||||
|
||||
@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Generate the configuration file:
|
||||
|
||||
`sudo grub-mkconfig --output={{/boot/grub/grub.cfg}}`
|
||||
`sudo grub-mkconfig {{[-o|--output]}} {{/boot/grub/grub.cfg}}`
|
||||
|
||||
- Display help:
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Display each line of input after reading it:
|
||||
|
||||
`grub-script-check --verbose`
|
||||
`grub-script-check {{[-v|--verbose]}}`
|
||||
|
||||
- Display help:
|
||||
|
||||
|
||||
@@ -10,23 +10,23 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Install a new package:
|
||||
|
||||
`guix package -i {{package}}`
|
||||
`guix package {{[-i|--install]}} {{package}}`
|
||||
|
||||
- Remove a package:
|
||||
|
||||
`guix package -r {{package}}`
|
||||
`guix package {{[-r|--remove]}} {{package}}`
|
||||
|
||||
- Search the package database for a regular expression:
|
||||
|
||||
`guix package -s "{{search_pattern}}"`
|
||||
`guix package {{[-s|--search]}} "{{search_pattern}}"`
|
||||
|
||||
- List installed packages:
|
||||
|
||||
`guix package -I`
|
||||
`guix package {{[-I|--list-installed]}}`
|
||||
|
||||
- List generations:
|
||||
|
||||
`guix package -l`
|
||||
`guix package {{[-l|--list-generations]}}`
|
||||
|
||||
- Roll back to the previous generation:
|
||||
|
||||
|
||||
@@ -17,26 +17,26 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`ipcs {{--shmems|--queues|--semaphores}}`
|
||||
|
||||
- Show full details on the resource with a specific [i]D:
|
||||
- Show full details on the resource with a specific ID:
|
||||
|
||||
`ipcs {{--shmems|--queues|--semaphores}} --id {{resource_id}}`
|
||||
`ipcs {{--shmems|--queues|--semaphores}} {{[-i|--id]}} {{resource_id}}`
|
||||
|
||||
- Show [l]imits in [b]ytes or in a human-readable format:
|
||||
- Show limits in [b]ytes or in a human-readable format:
|
||||
|
||||
`ipcs --limits {{--bytes|--human}}`
|
||||
`ipcs {{[-l|--limits]}} {{--bytes|--human}}`
|
||||
|
||||
- Show s[u]mmary about current usage:
|
||||
|
||||
`ipcs --summary`
|
||||
`ipcs {{[-u|--summary]}}`
|
||||
|
||||
- Show [c]reator's and owner's UIDs and PIDs for all IPC facilities:
|
||||
- Show creator's and owner's UIDs and PIDs for all IPC facilities:
|
||||
|
||||
`ipcs --creator`
|
||||
`ipcs {{[-c|--creator]}}`
|
||||
|
||||
- Show the [p]ID of the last operators for all IPC facilities:
|
||||
- Show the PID of the last operators for all IPC facilities:
|
||||
|
||||
`ipcs --pid`
|
||||
`ipcs {{[-p|--pid]}}`
|
||||
|
||||
- Show last access [t]imes for all IPC facilities:
|
||||
- Show last access times for all IPC facilities:
|
||||
|
||||
`ipcs --time`
|
||||
`ipcs {{[-t|--time]}}`
|
||||
|
||||
21
tldr/linux/ipmitool
Normal file
21
tldr/linux/ipmitool
Normal file
@@ -0,0 +1,21 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, linux]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# ipmitool
|
||||
|
||||
> Interface with the Intelligent Platform Management Interface (IPMI).
|
||||
> More information: <https://manned.org/ipmitool>.
|
||||
|
||||
- Start the IPMI driver for local connections:
|
||||
|
||||
`systemctl start ipmidrv`
|
||||
|
||||
- Open IPMI shell on the local hardware :
|
||||
|
||||
`sudo ipmitool shell`
|
||||
|
||||
- Open IPMI shell on a remote host:
|
||||
|
||||
`ipmitool -H {{ip_address}} -U {{user_name}} shell`
|
||||
@@ -10,11 +10,11 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Compile a source file into a `libtool` object:
|
||||
|
||||
`libtool --mode=compile gcc -c {{path/to/source.c}} -o {{path/to/source.lo}}`
|
||||
`libtool --mode=compile gcc {{[-c|--compile]}} {{path/to/source.c}} {{[-o|--output]}} {{path/to/source.lo}}`
|
||||
|
||||
- Create a library or an executable:
|
||||
|
||||
`libtool --mode=link gcc -o {{path/to/library.lo}} {{path/to/source.lo}}`
|
||||
`libtool --mode=link gcc {{[-o|--output]}} {{path/to/library.lo}} {{path/to/source.lo}}`
|
||||
|
||||
- Automatically set the library path so that another program can use uninstalled `libtool` generated programs or libraries:
|
||||
|
||||
|
||||
@@ -11,4 +11,4 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Initialize a project for `libtool` by copying necessary files (avoiding symbolic links) and overwriting existing files if needed:
|
||||
|
||||
`libtoolize --copy --force`
|
||||
`libtoolize {{[-c|--copy]}} {{[-f|--force]}}`
|
||||
|
||||
@@ -22,4 +22,4 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Create a device file with default SELinux security context:
|
||||
|
||||
`sudo mknod -Z {{path/to/device_file}} {{type}} {{major_device_number}} {{minor_device_number}}`
|
||||
`sudo mknod {{[-Z |--context=]}}{{path/to/device_file}} {{type}} {{major_device_number}} {{minor_device_number}}`
|
||||
|
||||
@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Use a custom directory (defaults to `$TMPDIR`, or `/tmp`):
|
||||
|
||||
`mktemp --tmpdir={{/path/to/tempdir}}`
|
||||
`mktemp {{[-p |--tmpdir=]}}{{/path/to/tempdir}}`
|
||||
|
||||
- Use a custom path template (`X`s are replaced with random alphanumeric characters):
|
||||
|
||||
|
||||
@@ -7,19 +7,19 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
> A partition manipulation program.
|
||||
> See also: `parted-interactive`, `partprobe`.
|
||||
> More information: <https://www.gnu.org/software/parted/parted.html>.
|
||||
> More information: <https://www.gnu.org/software/parted/manual/html_node/Invoking-Parted.html>.
|
||||
|
||||
- List partitions on all block devices:
|
||||
|
||||
`sudo parted --list`
|
||||
`sudo parted {{[-l|--list]}}`
|
||||
|
||||
- Create a new partition table of the specified label-type:
|
||||
|
||||
`sudo parted {{/dev/sdX}} --script mklabel {{aix|amiga|bsd|dvh|gpt|loop|mac|msdos|pc98|sun}}`
|
||||
`sudo parted {{/dev/sdX}} {{[-s|--script]}} mklabel {{aix|amiga|bsd|dvh|gpt|loop|mac|msdos|pc98|sun}}`
|
||||
|
||||
- Create a new `gpt` partition table with a 500MiB boot partition and give the rest for the system partition:
|
||||
|
||||
`sudo parted {{/dev/sdX}} --script mklabel gpt mkpart primary 0% 500MiB mkpart primary 500MiB 100%`
|
||||
`sudo parted {{/dev/sdX}} {{[-s|--script]}} mklabel gpt mkpart primary 0% 500MiB mkpart primary 500MiB 100%`
|
||||
|
||||
- Start interactive mode with the specified disk selected:
|
||||
|
||||
|
||||
@@ -10,20 +10,20 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Generate a permuted index where the first field of each line is an index reference:
|
||||
|
||||
`ptx --references {{path/to/file}}`
|
||||
`ptx {{[-r|--references]}} {{path/to/file}}`
|
||||
|
||||
- Generate a permuted index with automatically generated index references:
|
||||
|
||||
`ptx --auto-reference {{path/to/file}}`
|
||||
`ptx {{[-A|--auto-reference]}} {{path/to/file}}`
|
||||
|
||||
- Generate a permuted index with a fixed width:
|
||||
|
||||
`ptx --width={{width_in_columns}} {{path/to/file}}`
|
||||
`ptx {{[-w|--width]}} {{width_in_columns}} {{path/to/file}}`
|
||||
|
||||
- Generate a permuted index with a list of filtered words:
|
||||
|
||||
`ptx --only-file={{path/to/filter}} {{path/to/file}}`
|
||||
`ptx {{[-o|--only-file]}} {{path/to/filter}} {{path/to/file}}`
|
||||
|
||||
- Generate a permuted index with SYSV-style behaviors:
|
||||
|
||||
`ptx --traditional {{path/to/file}}`
|
||||
`ptx {{[-G|--traditional]}} {{path/to/file}}`
|
||||
|
||||
@@ -14,12 +14,12 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Change the log output file:
|
||||
|
||||
`pw-profiler --output {{path/to/file.log}}`
|
||||
`pw-profiler {{[-o|--output]}} {{path/to/file.log}}`
|
||||
|
||||
- Profile a remote instance:
|
||||
|
||||
`pw-profiler --remote {{remote_name}}`
|
||||
`pw-profiler {{[-r|--remote]}} {{remote_name}}`
|
||||
|
||||
- Display help:
|
||||
|
||||
`pw-profiler --help`
|
||||
`pw-profiler {{[-h|--help]}}`
|
||||
|
||||
@@ -15,12 +15,12 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Copy a directory recursively:
|
||||
|
||||
`rcp -r {{path/to/local_directory}} {{username}}@{{remote_host}}:{{/path/to/destination/}}`
|
||||
`rcp {{[-r|--recursive]}} {{path/to/local_directory}} {{username}}@{{remote_host}}:{{/path/to/destination/}}`
|
||||
|
||||
- Preserve the file attributes:
|
||||
|
||||
`rcp -p {{path/to/local_file}} {{username}}@{{remote_host}}:{{/path/to/destination/}}`
|
||||
`rcp {{[-p|--preserve]}} {{path/to/local_file}} {{username}}@{{remote_host}}:{{/path/to/destination/}}`
|
||||
|
||||
- Force copy without a confirmation:
|
||||
|
||||
`rcp -f {{path/to/local_file}} {{username}}@{{remote_host}}:{{/path/to/destination/}}`
|
||||
`rcp {{[-f|--from]}} {{path/to/local_file}} {{username}}@{{remote_host}}:{{/path/to/destination/}}`
|
||||
|
||||
@@ -9,18 +9,18 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> Note: Use `rexec` with caution, as it transmits data in plain text. Consider secure alternatives like SSH for encrypted communication.
|
||||
> More information: <https://www.gnu.org/software/inetutils/manual/html_node/rexec-invocation.html>.
|
||||
|
||||
- Execute a command on a remote [h]ost:
|
||||
- Execute a command on a remote host:
|
||||
|
||||
`rexec -h={{remote_host}} {{ls -l}}`
|
||||
`rexec {{[-h|--host]}} {{remote_host}} {{ls -l}}`
|
||||
|
||||
- Specify the remote [u]sername on a remote [h]ost:
|
||||
- Specify the remote username on a remote host:
|
||||
|
||||
`rexec -username={{username}} -h={{remote_host}} {{ps aux}}`
|
||||
`rexec {{[-u|--username]}} {{username}} {{[-h|--host]}} {{remote_host}} {{ps aux}}`
|
||||
|
||||
- Redirect `stdin` from `/dev/null` on a remote [h]ost:
|
||||
- Redirect `stdin` from `/dev/null` on a remote host:
|
||||
|
||||
`rexec --no-err -h={{remote_host}} {{ls -l}}`
|
||||
`rexec {{[-n|--noerr]}} {{[-h|--host]}} {{remote_host}} {{ls -l}}`
|
||||
|
||||
- Specify the remote [P]ort on a remote [h]ost:
|
||||
- Specify the remote port on a remote host:
|
||||
|
||||
`rexec -P={{1234}} -h={{remote_host}} {{ls -l}}`
|
||||
`rexec {{[-P|--port]}} {{1234}} {{[-h|--host]}} {{remote_host}} {{ls -l}}`
|
||||
|
||||
@@ -14,4 +14,4 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Log in to a remote host with a specific username:
|
||||
|
||||
`rlogin -l {{username}} {{remote_host}}`
|
||||
`rlogin {{[-l|--user]}} {{username}} {{remote_host}}`
|
||||
|
||||
@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Execute a command on a remote host with a specific username:
|
||||
|
||||
`rsh {{remote_host}} -l {{username}} {{ls -l}}`
|
||||
`rsh {{remote_host}} {{[-l|--user]}} {{username}} {{ls -l}}`
|
||||
|
||||
- Redirect `stdin` to `/dev/null` when executing a command on a remote host:
|
||||
|
||||
|
||||
@@ -15,11 +15,11 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Specify the domain to run a command in:
|
||||
|
||||
`runcon -t {{domain}}_t {{command}}`
|
||||
`runcon {{[-t|--type]}} {{domain}}_t {{command}}`
|
||||
|
||||
- Specify the context role to run a command with:
|
||||
|
||||
`runcon -r {{role}}_r {{command}}`
|
||||
`runcon {{[-r|--role]}} {{role}}_r {{command}}`
|
||||
|
||||
- Specify the full context to run a command with:
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Execute a specific script file and print the result to `stdout`:
|
||||
|
||||
`{{command}} | sed {{-f|--file}} {{path/to/script.sed}}`
|
||||
`{{command}} | sed {{[-f|--file]}} {{path/to/script.sed}}`
|
||||
|
||||
- Print just the first line to `stdout`:
|
||||
|
||||
|
||||
@@ -10,20 +10,20 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Create a shell script that when executed extracts the given files from itself:
|
||||
|
||||
`shar --vanilla-operation {{path/to/file1 path/to/file2 ...}} > {{path/to/archive.sh}}`
|
||||
`shar {{[-V|--vanilla-operation]}} {{path/to/file1 path/to/file2 ...}} > {{path/to/archive.sh}}`
|
||||
|
||||
- Compress the files in the archive:
|
||||
|
||||
`shar --compactor {{xz}} {{path/to/file1 path/to/file2 ...}} > {{path/to/archive.sh}}`
|
||||
`shar {{[-C|--compactor]}} {{xz}} {{path/to/file1 path/to/file2 ...}} > {{path/to/archive.sh}}`
|
||||
|
||||
- Treat all files as binary (i.e. `uuencode` everything):
|
||||
|
||||
`shar --uuencode {{path/to/file1 path/to/file2 ...}} > {{path/to/archive.sh}}`
|
||||
`shar {{[-B|--uuencode]}} {{path/to/file1 path/to/file2 ...}} > {{path/to/archive.sh}}`
|
||||
|
||||
- Treat all files as text (i.e. `uuencode` nothing):
|
||||
|
||||
`shar --text-files {{path/to/file1 path/to/file2 ...}} > {{path/to/archive.sh}}`
|
||||
`shar {{[-T|--text-files]}} {{path/to/file1 path/to/file2 ...}} > {{path/to/archive.sh}}`
|
||||
|
||||
- Include a name and cut mark in the header comment of the archive:
|
||||
|
||||
`shar --archive-name "{{My files}}" --cut-mark {{path/to/file1 path/to/file2 ...}} > {{path/to/archive.sh}}`
|
||||
`shar {{[-n|--archive-name]}} "{{My files}}" {{[-c|--cut-mark]}} {{path/to/file1 path/to/file2 ...}} > {{path/to/archive.sh}}`
|
||||
|
||||
@@ -10,12 +10,12 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Switch to the other A/B partition:
|
||||
|
||||
`steamos-chroot --partset other`
|
||||
`steamos-chroot {{[-p|--partset]}} other`
|
||||
|
||||
- Switch to a partition on another drive:
|
||||
|
||||
`steamos-chroot --disk {{/dev/sdX}} --partset {{A|B}}`
|
||||
`steamos-chroot {{[-d|--disk]}} {{/dev/sdX}} {{[-p|--partset]}} {{A|B}}`
|
||||
|
||||
- Display help:
|
||||
|
||||
`steamos-chroot --help`
|
||||
`steamos-chroot {{[-h|--help]}}`
|
||||
|
||||
30
tldr/linux/wireplumber
Normal file
30
tldr/linux/wireplumber
Normal file
@@ -0,0 +1,30 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, linux]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# wireplumber
|
||||
|
||||
> A modular session/policy manager for PipeWire and a GObject-based high-level library that wraps PipeWire’s API.
|
||||
> See also: `wpctl`, `pipewire`.
|
||||
> More information: <https://pipewire.pages.freedesktop.org/wireplumber/>.
|
||||
|
||||
- Make WirePlumber start with the user session immediately (for systemd systems):
|
||||
|
||||
`systemctl --user --now enable wireplumber`
|
||||
|
||||
- Run WirePlumber, after `pipewire` is started (for non-systemd systems):
|
||||
|
||||
`wireplumber`
|
||||
|
||||
- Specify a different context configuration file:
|
||||
|
||||
`wireplumber --config-file {{path/to/file}}`
|
||||
|
||||
- Display help:
|
||||
|
||||
`wireplumber --help`
|
||||
|
||||
- Display version:
|
||||
|
||||
`wireplumber --version`
|
||||
Reference in New Issue
Block a user