Update cheatsheets

This commit is contained in:
ivuorinen
2026-01-03 00:21:19 +00:00
parent fe5e4dcb31
commit a44c60008a
37 changed files with 286 additions and 21 deletions

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# acyclic
> Make a directed graph acyclic by reversing some edges.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://graphviz.org/pdf/acyclic.1.pdf>.
- Make a directed graph acyclic by reversing some edges:

View File

@@ -7,6 +7,7 @@ source: https://github.com/tldr-pages/tldr.git
> Fast download utility.
> Supports HTTP(S), FTP, SFTP, BitTorrent, and Metalink.
> See also: `axel`.
> More information: <https://aria2.github.io/manual/en/html/aria2c.html>.
- Download a specific URI to a file:

View File

@@ -6,7 +6,8 @@ source: https://github.com/tldr-pages/tldr.git
# axel
> Download accelerator.
> Supports HTTP, HTTPS, and FTP.
> Supports HTTP, HTTPS, FTP, and FTPs.
> See also: `aria2c`.
> More information: <https://manned.org/axel>.
- Download a URL to a file:
@@ -19,12 +20,20 @@ source: https://github.com/tldr-pages/tldr.git
- Download with a specific number connections:
`axel {{[-n|--num-connections]}} {{connections_num}} {{url}}`
`axel {{[-n|--num-connections]}} {{number}} {{url}}`
- Search for mirrors:
- Use a specific number of mirrors for searching and downloading:
`axel {{[-S|--search]}} {{mirrors_num}} {{url}}`
`axel {{[-S|--search=]}}{{number}} {{url}}`
- Limit download speed (bytes per second):
`axel {{[-s|--max-speed]}} {{speed}} {{url}}`
- Use the IPv4 protocol only when connecting to the host:
`axel {{[-4|--ipv4]}} {{url}}`
- Limit output to stdout and use a custom user-agent when downloading:
`axel {{[-q|--quiet]}} {{[-U|--user-agent]}} {{"Mozilla/5.0"}} {{url}}`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# bcomps
> Decompose graphs into their biconnected components.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://graphviz.org/pdf/bcomps.1.pdf>.
- Decompose one or more graphs into their biconnected components:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# ccomps
> Decompose graphs into their connected components.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://graphviz.org/pdf/ccomps.1.pdf>.
- Decompose one or more graphs into their connected components:

View File

@@ -7,6 +7,7 @@ source: https://github.com/tldr-pages/tldr.git
> Package, dependency, and environment management for any programming language.
> Some subcommands such as `create` have their own usage documentation.
> See also: `mamba`.
> More information: <https://docs.conda.io/projects/conda/en/latest/commands/index.html>.
- Create a new environment, installing named packages into it:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# edgepaint
> Colorize edges of a graph layout to clarify crossing edges.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://graphviz.org/pdf/edgepaint.1.pdf>.
- Colorize edges of one or more graph layouts (that already have layout information) to clarify crossing edges:

View File

@@ -6,6 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# entr
> Run arbitrary commands when files change.
> See also: `watchexec`.
> More information: <https://eradman.com/entrproject/>.
- Rebuild with `make` if any file in any subdirectory changes:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# fdp
> Render an image of a `force-directed` network graph from a `graphviz` file.
> Layouts: `dot`, `neato`, `twopi`, `circo`, `fdp`, `sfdp`, `osage` & `patchwork`.
> Layouts: `dot`, `neato`, `twopi`, `circo`, `fdp`, `sfdp`, `osage`, and `patchwork`.
> More information: <https://graphviz.org/doc/info/command.html>.
- Render a PNG image with a filename based on the input filename and output format (uppercase -O):

33
tldr/gettgt.py Normal file
View File

@@ -0,0 +1,33 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# getTGT.py
> Request a Ticket Granting Ticket (TGT).
> More information: <https://github.com/fortra/impacket>.
- Request a TGT using a password:
`getTGT.py {{domain}}/{{username}}:{{password}}`
- Request a TGT using NTLM hashes:
`getTGT.py -hashes {{LM_Hash}}:{{NT_Hash}} {{domain}}/{{username}}`
- Use Kerberos authentication (from existing ccache, no password needed):
`getTGT.py -k -no-pass {{domain}}/{{username}}`
- Request a TGT using an AES key (128 or 256 bits):
`getTGT.py -aesKey {{aes_key}} {{domain}}/{{username}}`
- Specify a domain controller IP:
`getTGT.py -dc-ip {{domain_controller_ip}} {{domain}}/{{username}}:{{password}}`
- Request a service ticket directly (AS-REQ) for a specific SPN:
`getTGT.py -service {{SPN}} {{domain}}/{{username}}:{{password}}`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# gvcolor
> Colorize a ranked digraph with a range of colors.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://graphviz.org/pdf/gvcolor.1.pdf>.
- Colorize one or more ranked digraph (that were already processed by `dot`):

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# gvpack
> Combine several graph layouts (that already have layout information).
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://graphviz.org/pdf/gvpack.1.pdf>.
- Combine several graph layouts (that already have layout information):

View File

@@ -6,6 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# http
> HTTPie: an HTTP client designed for testing, debugging, and generally interacting with APIs and HTTP servers.
> See also: `xh`.
> More information: <https://httpie.io/docs/cli/usage>.
- Make a simple GET request (shows response headers and content):

12
tldr/impacket-gettgt Normal file
View File

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

View File

@@ -26,7 +26,7 @@ source: https://github.com/tldr-pages/tldr.git
- Update the input cells in a notebook and preserve outputs and metadata:
`jupytext --update --to notebook {{path/to/notebook.py}}`
`jupytext --update --to notebook {{path/to/notebook}}.py`
- Update all paired representations of a notebook:

41
tldr/linux/fs_cli Normal file
View File

@@ -0,0 +1,41 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# fs_cli
> Connect to and control a running FreeSWITCH server using the FreeSWITCH Command Line Interface (ESL client).
> More information: <https://developer.signalwire.com/freeswitch/FreeSWITCH-Explained/Client-and-Developer-Interfaces/1048948/>.
- Connect to the local FreeSWITCH instance with an interactive session:
`fs_cli`
- Connect to a remote FreeSWITCH server:
`fs_cli {{[-H|--host]}} {{host}} {{[-P|--port]}} {{port}} {{[-p|--password]}} {{password}}`
- Execute a single FreeSWITCH command and exit:
`fs_cli {{[-x|--execute]}} "{{command}}"`
- Show FreeSWITCH system status:
`fs_cli {{[-x|--execute]}} "status"`
- Reload FreeSWITCH XML configuration:
`fs_cli {{[-x|--execute]}} "reloadxml"`
- Check if a module is loaded:
`fs_cli {{[-x|--execute]}} "module_exists {{module_name}}"`
- Show active calls:
`fs_cli {{[-x|--execute]}} "show calls"`
- Retry connection on failure:
`fs_cli {{[-r|--retry]}}`

View File

@@ -21,7 +21,7 @@ source: https://github.com/tldr-pages/tldr.git
`lid {{[-i|--ignore-case]}} {{token}}`
- Find tokens matching an extended regular expression:
- Find tokens matching an extended `regex`:
`lid {{[-r|--regexp]}} "{{pattern}}"`

View File

@@ -27,3 +27,7 @@ source: https://github.com/tldr-pages/tldr.git
- Only detect hardware virtualization:
`systemd-detect-virt {{[-v|--vm]}}`
- Detect whether in a `chroot` environment:
`systemd-detect-virt {{[-r|--chroot]}}`

17
tldr/linux/virt-clone Normal file
View File

@@ -0,0 +1,17 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# virt-clone
> Clone a libvirt virtual machine.
> More information: <https://manned.org/virt-clone>.
- Clone a virtual machine and automatically generate a new name, storage path, and MAC address:
`virt-clone {{[-o|--original]}} {{vm_name}} --auto-clone`
- Clone a virtual machine and specify the new name, storage path, and MAC address:
`virt-clone {{[-o|--original]}} {{vm_name}} {{[-n|--name]}} {{new_vm_name}} {{[-f|--file]}} {{path/to/new_storage}} {{[-m|--mac]}} {{ff:ff:ff:ff:ff:ff|RANDOM}}`

29
tldr/linux/virt-install Normal file
View File

@@ -0,0 +1,29 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# virt-install
> Create virtual machines with libvirt and begin OS installation.
> More information: <https://manned.org/virt-install>.
- Create a virtual machine with 1 GB RAM and 12 GB storage and start a Debian installation:
`virt-install {{[-n|--name]}} {{vm_name}} --memory {{1024}} --disk path={{path/to/image.qcow2}},size={{12}} {{[-c|--cdrom]}} {{path/to/debian.iso}}`
- Create a x86-64, KVM-accelerated, UEFI-based virtual machine with the Q35 chipset, 4 GiB RAM, 16 GiB RAW storage, and start a Fedora installation:
`virt-install {{[-n|--name]}} {{vm_name}} --arch {{x86_64}} --virt-type {{kvm}} --machine {{q35}} --boot {{uefi}} --memory {{4096}} --disk path={{path/to/image.raw}},size={{16}} {{[-c|--cdrom]}} {{path/to/fedora.iso}}`
- Create a diskless live virtual machine without an emulated sound device or a USB controller. Don't start an installation and don't autoconnect to console but attach a cdrom to it (might be useful for when using a live CD like tails):
`virt-install {{[-n|--name]}} {{vm_name}} --memory {{512}} --disk {{none}} --controller {{type=usb,model=none}} --sound {{none}} --autoconsole {{none}} --install {{no_install=yes}} {{[-c|--cdrom]}} {{path/to/tails.iso}}`
- Create a virtual machine with 16 GiB RAM, 250 GiB storage, 8 cores with hyperthreading, a specific CPU topology, and a CPU model that shares most features with the host CPU:
`virt-install {{[-n|--name]}} {{vm_name}} --cpu {{host-model}},topology.sockets={{1}},topology.cores={{4}},topology.threads={{2}} --memory {{16384}} --disk path={{path/to/image.qcow2}},size={{250}} {{[-c|--cdrom]}} {{path/to/debian.iso}}`
- Create a virtual machine and kickstart an automated deployment based on Fedora 35 using only remote resources (no ISO required):
`virt-install {{[-n|--name]}} {{vm_name}} --memory {{2048}} --disk path={{path/to/image.qcow2}},size={{20}} {{[-l|--location]}} {{https://download.fedoraproject.org/pub/fedora/linux/releases/35/Everything/x86_64/os/}} {{[-x|--extra-args]}} "{{inst.ks=https://path/to/valid_kickstart.org}}"`

25
tldr/linux/virt-qemu-run Normal file
View File

@@ -0,0 +1,25 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# virt-qemu-run
> Experimental tool to run a QEMU Guest VM independent of `libvirtd`.
> More information: <https://libvirt.org/manpages/virt-qemu-run.html>.
- Run a QEMU virtual machine:
`virt-qemu-run {{path/to/guest.xml}}`
- Run a QEMU virtual machine and store the state in a specific directory:
`virt-qemu-run {{[-r|--root]}} {{path/to/directory}} {{path/to/guest.xml}}`
- Run a QEMU virtual machine and display verbose information about the startup:
`virt-qemu-run {{[-v|--verbose]}} {{path/to/guest.xml}}`
- Display help:
`virt-qemu-run {{[-h|--help]}}`

18
tldr/linux/virt-sparsify Normal file
View File

@@ -0,0 +1,18 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# virt-sparsify
> Make virtual machine drive images thin-provisioned.
> Note: Use only for offline machines to avoid data corruption.
> More information: <https://manned.org/virt-sparsify>.
- Create a sparsified compressed image without snapshots from an unsparsified one:
`virt-sparsify --compress {{path/to/image.qcow2}} {{path/to/image_new.qcow2}}`
- Sparsify an image in-place:
`virt-sparsify --in-place {{path/to/image.img}}`

33
tldr/linux/virt-sysprep Normal file
View File

@@ -0,0 +1,33 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# virt-sysprep
> Reset, unconfigure, or customize a virtual machine image.
> More information: <https://manned.org/virt-sysprep>.
- List all supported operations (enabled operations are indicated with asterisks):
`virt-sysprep --list-operations`
- Remove sensitive system data from a virtual machine image:
`sudo virt-sysprep {{[-a|--add]}} {{path/to/image.qcow2}}`
- Specify a virtual machine by its name and run all enabled operations but don't actually apply the changes:
`sudo virt-sysprep {{[-d|--domain]}} {{vm_name}} {{[-n|--dry-run]}}`
- Run only the specified operations:
`sudo virt-sysprep {{[-d|--domain]}} {{vm_name}} --operations {{operation1,operation2,...}}`
- Generate a new `/etc/machine-id` file and enable customizations to be able to change the host name to avoid network conflicts:
`sudo virt-sysprep {{[-d|--domain]}} {{vm_name}} --enable {{customizations}} --hostname {{host_name}} --operation {{machine-id}}`
- Display help:
`virt-sysprep {{[-he|--help]}}`

View File

@@ -7,6 +7,7 @@ source: https://github.com/tldr-pages/tldr.git
> Fast, cross-platform package manager, intended as a drop-in replacement for conda.
> Some subcommands such as `repoquery` have their own usage documentation.
> See also: `conda`.
> More information: <https://mamba.readthedocs.io/en/latest/user_guide/mamba.html>.
- Create a new environment, installing the specified packages into it:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# mingle
> Bundle the edges of a graph layout.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://www.graphviz.org/pdf/mingle.1.pdf>.
- Bundle the edges of one or more graph layouts (that already have layout information):

View File

@@ -21,7 +21,7 @@ source: https://github.com/tldr-pages/tldr.git
`{{command}} | sed -fa {{path/to/script.sed}}`
- Turn on GNU re[g]ex extension:
- Turn on [g]NU `regex` extension:
`{{command}} | sed -fg {{path/to/script.sed}}`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# nop
> Check validity and pretty-print graphs in canonical format.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://www.graphviz.org/pdf/nop.1.pdf>.
- Pretty-print one or more graphs in canonical format:

View File

@@ -6,6 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# parallel
> Run commands on multiple CPU cores.
> See also: `xargs`.
> More information: <https://www.gnu.org/software/parallel/man.html>.
- Gzip several files at once, using all cores:

View File

@@ -8,7 +8,7 @@ source: https://github.com/tldr-pages/tldr.git
> Send ICMP ECHO_REQUEST packets to network hosts.
> More information: <https://manned.org/ping>.
- Ping host:
- Ping a host:
`ping {{host}}`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# sccmap
> Extract strongly connected components of directed graphs.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://www.graphviz.org/pdf/sccmap.1.pdf>.
- Extract strongly connected components of one or more directed graphs:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# snoop
> Network packet sniffer.
> SunOS equivalent of tcpdump.
> SunOS equivalent of `tcpdump`.
> More information: <https://www.unix.com/man-page/sunos/1m/snoop>.
- Capture packets on a specific network interface:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# tred
> Compute the transitive reduction of directed graphs.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://www.graphviz.org/pdf/tred.1.pdf>.
- Construct the transitive reduction graph of one or more directed graphs:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# unflatten
> Adjust directed graphs to improve the layout aspect ratio.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, & `unflatten`.
> Graphviz filters: `acyclic`, `bcomps`, `comps`, `edgepaint`, `gvcolor`, `gvpack`, `mingle`, `nop`, `sccmap`, `tred`, and `unflatten`.
> More information: <https://www.graphviz.org/pdf/unflatten.1.pdf>.
- Adjust one or more directed graphs to improve the layout aspect ratio:

31
tldr/virt-viewer Normal file
View File

@@ -0,0 +1,31 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# virt-viewer
> Minimal graphical interface for a virtual machine (VM).
> Note: `domain` refers to the name, UUID, or ID for the existing VMs.
> See also: `virsh`.
> More information: <https://manned.org/virt-viewer>.
- Launch `virt-viewer` with a prompt to select running virtual machines:
`virt-viewer`
- Launch `virt-viewer` for a specific virtual machine by ID, UUID, or name:
`virt-viewer "{{domain}}"`
- Wait for a virtual machine to start and automatically reconnect if it shutdown and restarts:
`virt-viewer --reconnect --wait "{{domain}}"`
- Connect to a specific remote virtual machine over TLS:
`virt-viewer --connect "xen//{{url}}" "{{domain}}"`
- Connect to a specific remote virtual machine over SSH:
`virt-viewer --connect "qemu+ssh//{{username}}@{{url}}/system" "{{domain}}"`

View File

@@ -6,6 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# watchexec
> Run arbitrary commands when files change.
> See also: `entr`.
> More information: <https://manned.org/watchexec>.
- Call `ls -la` when any file in the current directory changes:

View File

@@ -6,6 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# popd
> Change the current directory to the directory stored by the `pushd` command.
> See also: `pushd`.
> More information: <https://learn.microsoft.com/windows-server/administration/windows-commands/popd>.
- Switch to directory at the top of the stack:

View File

@@ -7,6 +7,7 @@ source: https://github.com/tldr-pages/tldr.git
> Execute a command with piped arguments coming from another command, a file, etc.
> The input is treated as a single block of text and split into separate pieces on spaces, tabs, newlines, and end-of-file.
> See also: `parallel`.
> More information: <https://www.gnu.org/software/findutils/manual/html_mono/find.html#Invoking-xargs>.
- Run a command using the input data as arguments:
@@ -36,3 +37,7 @@ source: https://github.com/tldr-pages/tldr.git
- Prompt user for confirmation before executing command (confirm with `y` or `Y`):
`{{arguments_source}} | xargs {{[-p|--interactive]}} {{command}}`
- Allow the command to access the terminal for interactive input:
`{{arguments_source}} | xargs {{[-o|--open-tty]}} {{command}}`