mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-02-16 19:49:20 +00:00
Update cheatsheets
This commit is contained in:
@@ -8,11 +8,11 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> Run and manage telephone and exchange (phone) server instances.
|
||||
> More information: <https://docs.asterisk.org>.
|
||||
|
||||
- [R]econnect to a running server, and turn on logging 3 levels of [v]erbosity:
|
||||
- [r]econnect to a running server, and turn on logging 3 levels of [v]erbosity:
|
||||
|
||||
`asterisk -r -vvv`
|
||||
|
||||
- [R]econnect to a running server, run a single command, and return:
|
||||
- [r]econnect to a running server, run a single command, and return:
|
||||
|
||||
`asterisk -r -x "{{command}}"`
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`cal {{[-3|--three]}}`
|
||||
|
||||
- Display the whole calendar for the current [y]ear:
|
||||
- Display the whole calendar for the current year:
|
||||
|
||||
`cal {{[-y|--year]}}`
|
||||
|
||||
|
||||
@@ -12,24 +12,24 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Run a command with the given scheduling class and priority:
|
||||
|
||||
`ionice -c {{scheduling_class}} -n {{priority}} {{command}}`
|
||||
`ionice {{[-c|--class]}} {{scheduling_class}} {{[-n|--classdata]}} {{priority}} {{command}}`
|
||||
|
||||
- Set I/O scheduling [c]lass of a running process with a specific [p]id, [P]gid or [u]id:
|
||||
- Set I/O scheduling class of a running process with a specific [p]id, [P]gid or [u]id:
|
||||
|
||||
`ionice -c {{scheduling_class}} -{{p|P|u}} {{id}}`
|
||||
`ionice {{[-c|--class]}} {{scheduling_class}} -{{p|P|u}} {{id}}`
|
||||
|
||||
- Run a command with custom I/O scheduling [c]lass and priority:
|
||||
- Run a command with custom I/O scheduling class and priority:
|
||||
|
||||
`ionice -c {{scheduling_class}} -n {{priority}} {{command}}`
|
||||
`ionice {{[-c|--class]}} {{scheduling_class}} {{[-n|--classdata]}} {{priority}} {{command}}`
|
||||
|
||||
- Ignore failure to set the requested priority:
|
||||
|
||||
`ionice -t -n {{priority}} -p {{pid}}`
|
||||
`ionice {{[-t|--ignore]}} {{[-n|--classdata]}} {{priority}} {{[-p|--pid]}} {{pid}}`
|
||||
|
||||
- Run the command even in case it was not possible to set the desired priority (this can happen due to insufficient privileges or an old kernel version):
|
||||
|
||||
`ionice -t -n {{priority}} -p {{pid}}`
|
||||
`ionice {{[-t|--ignore]}} {{[-n|--classdata]}} {{priority}} {{[-p|--pid]}} {{pid}}`
|
||||
|
||||
- Print the I/O scheduling class and priority of a running process:
|
||||
|
||||
`ionice -p {{pid}}`
|
||||
`ionice {{[-p|--pid]}} {{pid}}`
|
||||
|
||||
@@ -17,17 +17,17 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`kde-builder {{component_name}}`
|
||||
|
||||
- Compile a component without updating its local code and without compiling its [D]ependencies:
|
||||
- Compile a component without updating its local code and without compiling its dependencies:
|
||||
|
||||
`kde-builder --no-src --no-include-dependencies {{component_name}}`
|
||||
`kde-builder {{[-S|--no-src]}} {{[-D|--no-include-dependencies]}} {{component_name}}`
|
||||
|
||||
- [r]efresh the build directories before compiling:
|
||||
- Refresh the build directories before compiling:
|
||||
|
||||
`kde-builder --refresh-build {{component_name}}`
|
||||
`kde-builder {{[-r|--refresh-build]}} {{component_name}}`
|
||||
|
||||
- Resume compilation from a specific dependency:
|
||||
|
||||
`kde-builder --resume-from {{dependency_component}} {{component_name}}`
|
||||
`kde-builder {{[-f|--resume-from]}} {{dependency_component}} {{component_name}}`
|
||||
|
||||
- Run a component with a specified executable name:
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Print all properties of a specific session:
|
||||
|
||||
`loginctl show-session {{session_id}} --all`
|
||||
`loginctl show-session {{session_id}} {{[-a|--all]}}`
|
||||
|
||||
- Print all properties of a specific user:
|
||||
|
||||
@@ -22,11 +22,11 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Print a specific property of a user:
|
||||
|
||||
`loginctl show-user {{username}} --property {{property_name}}`
|
||||
`loginctl show-user {{username}} {{[-p|--property]}} {{property_name}}`
|
||||
|
||||
- Execute a `loginctl` operation on a remote host:
|
||||
|
||||
`loginctl list-users -H {{hostname}}`
|
||||
`loginctl list-users {{[-H|--host]}} {{hostname}}`
|
||||
|
||||
- Log a user out on all of their sessions:
|
||||
|
||||
|
||||
@@ -14,24 +14,24 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- List all configuration files that will be used by the PipeWire PulseAudio server:
|
||||
|
||||
`pw-config --name pipewire-pulse.conf`
|
||||
`pw-config {{[-n|--name]}} pipewire-pulse.conf`
|
||||
|
||||
- List all configuration sections used by the PipeWire PulseAudio server:
|
||||
|
||||
`pw-config --name pipewire-pulse.conf list`
|
||||
`pw-config {{[-n|--name]}} pipewire-pulse.conf list`
|
||||
|
||||
- List the `context.properties` fragments used by the JACK clients:
|
||||
|
||||
`pw-config --name jack.conf list context.properties`
|
||||
`pw-config {{[-n|--name]}} jack.conf list context.properties`
|
||||
|
||||
- List the merged `context.properties` used by the JACK clients:
|
||||
|
||||
`pw-config --name jack.conf merge context.properties`
|
||||
`pw-config {{[-n|--name]}} jack.conf merge context.properties`
|
||||
|
||||
- List the merged `context.modules` used by the PipeWire server and [r]eformat:
|
||||
- List the merged `context.modules` used by the PipeWire server and reformat:
|
||||
|
||||
`pw-config --name pipewire.conf --recurse merge context.modules`
|
||||
`pw-config {{[-n|--name]}} pipewire.conf {{[-r|--recurse]}} merge context.modules`
|
||||
|
||||
- Display help:
|
||||
|
||||
`pw-config --help`
|
||||
`pw-config {{[-h|--help]}}`
|
||||
|
||||
@@ -17,18 +17,18 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`pw-dump {{object_id}}`
|
||||
|
||||
- Dump the current state [m]onitoring changes, printing it again:
|
||||
- Dump the current state monitoring changes, printing it again:
|
||||
|
||||
`pw-dump --monitor`
|
||||
`pw-dump {{[-m|--monitor]}}`
|
||||
|
||||
- Dump the current state of a [r]emote instance to a file:
|
||||
- Dump the current state of a remote instance to a file:
|
||||
|
||||
`pw-dump --remote {{remote_name}} > {{path/to/dump_file.json}}`
|
||||
`pw-dump {{[-r|--remote]}} {{remote_name}} > {{path/to/dump_file.json}}`
|
||||
|
||||
- Set a [C]olor configuration:
|
||||
- Set a color configuration:
|
||||
|
||||
`pw-dump --color {{never|always|auto}}`
|
||||
`pw-dump {{[-C|--color]}} {{never|always|auto}}`
|
||||
|
||||
- Display help:
|
||||
|
||||
`pw-dump --help`
|
||||
`pw-dump {{[-h|--help]}}`
|
||||
|
||||
@@ -12,11 +12,11 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`shutdown -h now`
|
||||
|
||||
- [r]eboot immediately:
|
||||
- Reboot immediately:
|
||||
|
||||
`shutdown {{[-r|--reboot]}} now`
|
||||
|
||||
- [r]eboot in 5 minutes:
|
||||
- Reboot in 5 minutes:
|
||||
|
||||
`shutdown {{[-r|--reboot]}} +{{5}} &`
|
||||
|
||||
|
||||
17
tldr/linux/systemctl-enable
Normal file
17
tldr/linux/systemctl-enable
Normal file
@@ -0,0 +1,17 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, linux]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# systemctl enable
|
||||
|
||||
> Enable systemd services.
|
||||
> More information: <https://www.freedesktop.org/software/systemd/man/latest/systemctl.html#enable%20UNIT%E2%80%A6>.
|
||||
|
||||
- Enable a service to run on boot:
|
||||
|
||||
`systemctl enable {{unit}}`
|
||||
|
||||
- Enable a service to run on boot and start it now:
|
||||
|
||||
`systemctl enable {{unit}} --now`
|
||||
@@ -27,7 +27,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Plot a dependency graph and convert it to an SVG file:
|
||||
|
||||
`systemd-analyze dot | dot -T{{svg}} > {{path/to/file.svg}}`
|
||||
`systemd-analyze dot | dot -T {{svg}} > {{path/to/file.svg}}`
|
||||
|
||||
- Show security scores of running units:
|
||||
|
||||
|
||||
17
tldr/linux/systemd-disable
Normal file
17
tldr/linux/systemd-disable
Normal file
@@ -0,0 +1,17 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, linux]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# systemctl disable
|
||||
|
||||
> Disable systemd services.
|
||||
> More information: <https://www.freedesktop.org/software/systemd/man/latest/systemctl.html#disable%20UNIT%E2%80%A6>.
|
||||
|
||||
- Stop a service from running on boot:
|
||||
|
||||
`systemctl disable {{unit}}`
|
||||
|
||||
- Stop a service from running on boot and stop its current execution:
|
||||
|
||||
`systemctl disable {{unit}} --now`
|
||||
17
tldr/linux/ubuntu-drivers
Normal file
17
tldr/linux/ubuntu-drivers
Normal file
@@ -0,0 +1,17 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, linux]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# ubuntu-drivers
|
||||
|
||||
> Install drivers on Ubuntu.
|
||||
> More information: <https://documentation.ubuntu.com/server/how-to/graphics/install-nvidia-drivers/index.html>.
|
||||
|
||||
- List available drivers for the current hardware:
|
||||
|
||||
`sudo ubuntu-drivers list`
|
||||
|
||||
- Install drivers for detected hardware:
|
||||
|
||||
`sudo ubuntu-drivers install`
|
||||
@@ -8,26 +8,26 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> X11 selection and clipboard manipulation tool.
|
||||
> More information: <https://manned.org/xsel>.
|
||||
|
||||
- Use a command's output as input of the clip[b]oard (equivalent to `<Ctrl c>`):
|
||||
- Use a command's output as input of the clipboard (equivalent to `<Ctrl c>`):
|
||||
|
||||
`echo 123 | xsel -ib`
|
||||
`echo 123 | xsel {{[-ib|--input --clipboard]}}`
|
||||
|
||||
- Use the contents of a file as input of the clipboard:
|
||||
|
||||
`cat {{path/to/file}} | xsel -ib`
|
||||
`cat {{path/to/file}} | xsel {{[-ib|--input --clipboard]}}`
|
||||
|
||||
- Output the clipboard's contents into the terminal (equivalent to `<Ctrl v>`):
|
||||
|
||||
`xsel -ob`
|
||||
`xsel {{[-ob|--output --clipboard]}}`
|
||||
|
||||
- Output the clipboard's contents into a file:
|
||||
|
||||
`xsel -ob > {{path/to/file}}`
|
||||
`xsel {{[-ob|--output --clipboard]}} > {{path/to/file}}`
|
||||
|
||||
- Clear the clipboard:
|
||||
|
||||
`xsel -cb`
|
||||
`xsel {{[-cb|--clear --clipboard]}}`
|
||||
|
||||
- Output the X11 primary selection's contents into the terminal (equivalent to a mouse `<MiddleClick>`):
|
||||
|
||||
`xsel -op`
|
||||
`xsel {{[-op|--output --primary]}}`
|
||||
|
||||
@@ -29,7 +29,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`zip {{[-r|--recurse-paths]}} {{[-e|--encrypt]}} {{path/to/compressed.zip}} {{path/to/file_or_directory1 path/to/file_or_directory2 ...}}`
|
||||
|
||||
- Archive files/directories to a multi-part [s]plit Zip archive (e.g. 3 GB parts):
|
||||
- Archive files/directories to a multi-part split Zip archive (e.g. 3 GB parts):
|
||||
|
||||
`zip {{[-r|--recurse-paths]}} {{[-s|--split-size]}} {{3g}} {{path/to/compressed.zip}} {{path/to/file_or_directory1 path/to/file_or_directory2 ...}}`
|
||||
|
||||
|
||||
Reference in New Issue
Block a user