Update cheatsheets

This commit is contained in:
ivuorinen
2024-10-09 00:17:12 +00:00
parent 31e38d1972
commit 8fdd4c7ea2
24 changed files with 186 additions and 18 deletions

8
tldr/!
View File

@@ -31,3 +31,11 @@ source: https://github.com/tldr-pages/tldr.git
- Substitute with the last argument of the latest command:
`{{command}} !$`
- Substitute with the last command but without the last argument:
`!:-`
- Print last command that starts with a string without executing it:
`!{{string}}:p`

17
tldr/adb-devices Normal file
View File

@@ -0,0 +1,17 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# adb devices
> List connected Android devices.
> More information: <https://manned.org/adb>.
- List devices:
`adb devices`
- List devices and their system info:
`adb devices -l`

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# adb install
> Android Debug Bridge Install: push packages to an Android emulator instance or connected Android devices.
> Push packages to a connected Android device or emulator.
> More information: <https://developer.android.com/tools/adb>.
- Push an Android application to an emulator/device:

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# adb reverse
> Android Debug Bridge Reverse: reverse socket connections from an Android emulator instance or connected Android devices.
> Reverse socket connections from a connected Android device or emulator.
> More information: <https://developer.android.com/tools/adb>.
- List all reverse socket connections from emulators and devices:

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# adb shell
> Android Debug Bridge Shell: run remote shell commands on an Android emulator instance or connected Android devices.
> Run shell commands on a connected Android device or emulator.
> More information: <https://developer.android.com/tools/adb>.
- Start a remote interactive shell on the emulator or device:

View File

@@ -7,7 +7,7 @@ source: https://github.com/tldr-pages/tldr.git
> A collection of tools for indexing, inspecting, and visualizing disk usage.
> Duc maintains a database of accumulated sizes of directories of the file system, allowing queries in this database, or creating fancy graphs to show where data is.
> More information: <https://duc.zevv.nl/>.
> More information: <http://duc.zevv.nl>.
- Index the /usr directory, writing to the default database location ~/.duc.db:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# check-language-support
> Display a list of missing language packages on Ubuntu.
> More information: <https://manpages.ubuntu.com/manpages/latest/man1/check-language-support.html>.
> More information: <https://manned.org/check-language-support>.
- Display a list of missing language packages based on installed software and enabled locales:

View File

@@ -0,0 +1,33 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# dnf config-manager
> Manage DNF configuration options and repositories on Fedora-based systems.
> More information: <https://manned.org/dnf-config-manager>.
- Add (and enable) a repository from a URL:
`dnf config-manager --add-repo={{repository_url}}`
- Print current configuration values:
`dnf config-manager --dump`
- Enable a specific repository:
`dnf config-manager --set-enabled {{repository_id}}`
- Disable specified repositories:
`dnf config-manager --set-disabled {{repository_id1 repository_id2 ...}}`
- Set a configuration option for a repository:
`dnf config-manager --setopt={{option}}={{value}}`
- Display help:
`dnf config-manager --help-cmd`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# do-release-upgrade
> The Ubuntu release upgrader.
> More information: <https://ubuntu.com/server/docs/upgrade-introduction>.
> More information: <https://manned.org/do-release-upgrade.8>.
- Upgrade to the latest release:

View File

@@ -7,7 +7,7 @@ source: https://github.com/tldr-pages/tldr.git
> A collection of tools for indexing, inspecting and visualizing disk usage.
> Duc maintains a database of accumulated sizes of directories in the file system, allowing to query this database, or creating fancy graphs to show where data is.
> More information: <https://duc.zevv.nl/>.
> More information: <http://duc.zevv.nl>.
- Index the `/usr` directory, writing to the default database location `~/.duc.db`:

37
tldr/linux/gpclient Normal file
View File

@@ -0,0 +1,37 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# gpclient
> Connect to a GlobalProtect VPN on Linux via OpenConnect.
> More information: <https://github.com/yuezk/GlobalProtect-openconnect>.
- Connect to a GlobalProtect VPN using a portal server:
`gpclient connect {{vpn_gateway_url}}`
- Disconnect from the currently connected VPN server:
`gpclient disconnect`
- Launch the graphical user interface (GUI) for VPN management:
`gpclient launch-gui`
- Use OpenSSL workaround to bypass legacy renegotiation errors:
`gpclient connect --fix-openssl {{vpn_gateway_url}}`
- Ignore TLS errors during connection:
`gpclient connect --ignore-tls-errors {{vpn_gateway_url}}`
- Display version:
`gpclient --version`
- Display help for any command:
`gpclient help {{command}}`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# pro
> Manage Ubuntu Pro services.
> More information: <https://manpages.ubuntu.com/manpages/latest/man1/ubuntu-advantage.1.html>.
> More information: <https://manned.org/ubuntu-advantage.1>.
- Connect your system to the Ubuntu Pro support contract:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# virt-manager
> A desktop user interface for managing KVM and Xen virtual machines and LXC containers.
> More information: <https://manpages.ubuntu.com/manpages/man1/virt-manager.1.html>.
> More information: <https://manned.org/virt-manager.1>.
- Launch the GUI:

View File

@@ -0,0 +1,12 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# yum config-manager
> This command is an alias of `dnf config-manager`.
- View documentation for the original command:
`tldr dnf config-manager`

View File

@@ -19,3 +19,7 @@ source: https://github.com/tldr-pages/tldr.git
- Receive data through a named pipe:
`cat {{path/to/pipe}}`
- Share your terminal session in real-time:
`mkfifo {{path/to/pipe}}; script -f {{path/to/pipe}}`

View File

@@ -11,4 +11,8 @@ source: https://github.com/tldr-pages/tldr.git
- Launch a program with altered priority:
`nice -n {{niceness_value}} {{command}}`
`nice -{{niceness_value}} {{command}}`
- Define the priority with an explicit option:
`nice {{-n|--adjustment}} {{niceness_value}} {{command}}`

12
tldr/npm-run-script Normal file
View File

@@ -0,0 +1,12 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# npm run-script
> This command is an alias of `npm run`.
- View documentation for the original command:
`tldr npm run`

View File

@@ -12,14 +12,14 @@ source: https://github.com/tldr-pages/tldr.git
`pandoc {{input.md}} -o {{output.pdf}}`
- Convert to a standalone file with the appropriate headers/footers (for LaTeX, HTML, etc.):
`pandoc {{input.md}} -s -o {{output.html}}`
- Force conversion to use a specific format:
`pandoc {{input.docx}} --to {{gfm}} -o {{output.md}}`
- Convert to a standalone file with the appropriate headers/footers (for LaTeX, HTML, etc.):
`pandoc {{input.md}} -s -o {{output.tex}}`
- List all supported input formats:
`pandoc --list-input-formats`

37
tldr/pulumi-stack Normal file
View File

@@ -0,0 +1,37 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# pulumi stack
> Manage stacks and view stack state.
> More information: <https://www.pulumi.com/docs/iac/cli/commands/pulumi_stack/>.
- Create a new stack:
`pulumi stack init {{stack_name}}`
- View the stack state:
`pulumi stack`
- List known stacks:
`pulumi stack ls`
- Select an active stack:
`pulumi stack select {{stack_name}}`
- Show stack outputs, including secrets, in plaintext:
`pulumi stack output --show-secrets`
- Export the stack state to a JSON file:
`pulumi stack export --file {{path/to/file.json}}`
- Display help:
`pulumi stack --help`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# runsv
> Start and manage a runit service.
> More information: <https://manpages.ubuntu.com/manpages/latest/man8/runsv.8.html>.
> More information: <https://manned.org/runsv.8>.
- Start a runit service as the current user:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# runsvchdir
> Change the directory `runsvdir` uses by default.
> More information: <https://manpages.ubuntu.com/manpages/latest/man8/runsvchdir.8.html>.
> More information: <https://manned.org/runsvchdir.8>.
- Switch `runsvdir` directories:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# runsvdir
> Run an entire directory of services.
> More information: <https://manpages.ubuntu.com/manpages/latest/man8/runsvdir.8.html>.
> More information: <https://manned.org/runsvdir.8>.
- Start and manage all services in a directory as the current user:

View File

@@ -24,6 +24,10 @@ source: https://github.com/tldr-pages/tldr.git
`set -o {{vi}}`
- Return to default mode:
`set -o {{emacs}}`
- Exit the shell when (some) commands fail:
`set -e`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# sv
> Control a running runsv service.
> More information: <https://manpages.ubuntu.com/manpages/latest/man8/sv.8.html>.
> More information: <https://manned.org/sv.8>.
- Start a service: