mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-02-09 18:46:35 +00:00
Update cheatsheets
This commit is contained in:
@@ -9,7 +9,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> Part of `azure-cli` (also known as `az`).
|
||||
> More information: <https://learn.microsoft.com/cli/azure/storage/account>.
|
||||
|
||||
- Create an storage account:
|
||||
- Create a storage account:
|
||||
|
||||
`az storage account create {{[-n|--name]}} {{storage_account_name}} {{[-g|--resource-group]}} {{azure_resource_group}} --location {{azure_location}} --sku {{storage_account_sku}}`
|
||||
|
||||
|
||||
21
tldr/dos/boot
Normal file
21
tldr/dos/boot
Normal file
@@ -0,0 +1,21 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# BOOT
|
||||
|
||||
> Boot floppy or hard disk images directly, bypassing OS emulation.
|
||||
> More information: <https://www.dosbox.com/wiki/BOOT>.
|
||||
|
||||
- Boot from floppy image:
|
||||
|
||||
`BOOT {{path/to/floppy.img}}`
|
||||
|
||||
- Boot from hard disk image:
|
||||
|
||||
`BOOT {{path/to/hard_disk.img}}`
|
||||
|
||||
- Boot multiple floppy images:
|
||||
|
||||
`BOOT {{path/to/floppy1.img path/to/floppy2.img ...}}`
|
||||
13
tldr/dos/choice
Normal file
13
tldr/dos/choice
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# CHOICE
|
||||
|
||||
> Wait for keypress and set `ERRORLEVEL` in batch scripts.
|
||||
> More information: <https://www.dosbox.com/wiki/Commands#CHOICE>.
|
||||
|
||||
- Prompt for yes/no:
|
||||
|
||||
`CHOICE "{{prompt}}"`
|
||||
33
tldr/dos/config
Normal file
33
tldr/dos/config
Normal file
@@ -0,0 +1,33 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# CONFIG
|
||||
|
||||
> Change or query DOSBox settings at runtime; save configs/languages.
|
||||
> More information: <https://www.dosbox.com/wiki/CONFIG>.
|
||||
|
||||
- Write current config to file (local drive):
|
||||
|
||||
`CONFIG -writeconf {{path/to/file.conf}}`
|
||||
|
||||
- Write current language strings to file:
|
||||
|
||||
`CONFIG -writelang {{path/to/file.lang}}`
|
||||
|
||||
- Enable secure mode (disables MOUNT/IMGMOUNT/BOOT):
|
||||
|
||||
`CONFIG -securemode`
|
||||
|
||||
- Set a property (e.g., CPU cycles):
|
||||
|
||||
`CONFIG -set "cpu cycles={{10000}}"`
|
||||
|
||||
- Set property (e.g., disable EMS):
|
||||
|
||||
`CONFIG -set "dos ems=off"`
|
||||
|
||||
- Get property value (stored in %CONFIG%):
|
||||
|
||||
`CONFIG -get "cpu core"`
|
||||
13
tldr/dos/copy
Normal file
13
tldr/dos/copy
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# COPY
|
||||
|
||||
> Copy files.
|
||||
> More information: <https://www.dosbox.com/wiki/Commands#COPY>.
|
||||
|
||||
- Copy a file:
|
||||
|
||||
`COPY {{path/to/source_file}} {{path/to/destination_file}}`
|
||||
17
tldr/dos/del
Normal file
17
tldr/dos/del
Normal file
@@ -0,0 +1,17 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# DEL
|
||||
|
||||
> Delete one or more files.
|
||||
> More information: <https://www.dosbox.com/wiki/Commands#DEL>.
|
||||
|
||||
- Delete a file:
|
||||
|
||||
`DEL {{path/to/file}}`
|
||||
|
||||
- Delete all files matching a pattern:
|
||||
|
||||
`DEL {{path/to/*.ext}}`
|
||||
21
tldr/dos/loadfix
Normal file
21
tldr/dos/loadfix
Normal file
@@ -0,0 +1,21 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# LOADFIX
|
||||
|
||||
> Reduce available conventional memory for old programs (default: 64KB).
|
||||
> More information: <https://www.dosbox.com/wiki/LOADFIX>.
|
||||
|
||||
- Start a program with 64KB allocated memory:
|
||||
|
||||
`LOADFIX {{program}}`
|
||||
|
||||
- Load with custom KB reduction (1-1024):
|
||||
|
||||
`LOADFIX -{{32}} {{program}}`
|
||||
|
||||
- Free all previously allocated memory:
|
||||
|
||||
`LOADFIX -f`
|
||||
13
tldr/dos/loadhigh
Normal file
13
tldr/dos/loadhigh
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# LOADHIGH
|
||||
|
||||
> Load program into upper memory (requires `xms=true`, `umb=true`).
|
||||
> More information: <https://www.dosbox.com/wiki/Commands#LOADHIGH>.
|
||||
|
||||
- Load program into upper memory:
|
||||
|
||||
`LOADHIGH {{program}}`
|
||||
13
tldr/dos/md
Normal file
13
tldr/dos/md
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# MD
|
||||
|
||||
> Make a directory.
|
||||
> More information: <https://www.dosbox.com/wiki/Commands#MD>.
|
||||
|
||||
- Create directory:
|
||||
|
||||
`MD {{path/to/directory}}`
|
||||
13
tldr/dos/mem
Normal file
13
tldr/dos/mem
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# MEM
|
||||
|
||||
> Display free memory info.
|
||||
> More information: <https://www.dosbox.com/wiki/Commands#MEM>.
|
||||
|
||||
- Display free memory:
|
||||
|
||||
`MEM`
|
||||
33
tldr/dos/mixer
Normal file
33
tldr/dos/mixer
Normal file
@@ -0,0 +1,33 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# MIXER
|
||||
|
||||
> Display/set sound levels.
|
||||
> More information: <https://www.dosbox.com/wiki/MIXER>.
|
||||
|
||||
- Display current volumes:
|
||||
|
||||
`MIXER`
|
||||
|
||||
- Set master volume (left:right percentages):
|
||||
|
||||
`MIXER master {{80}}:{{80}}`
|
||||
|
||||
- Set Sound Blaster volume in decibels:
|
||||
|
||||
`MIXER sb d{{10}}:d{{10}}`
|
||||
|
||||
- Set GUS left channel only:
|
||||
|
||||
`MIXER gus {{50}}`
|
||||
|
||||
- Set volumes without displaying result:
|
||||
|
||||
`MIXER gus {{40}}:{{40}} /NOSHOW`
|
||||
|
||||
- List available MIDI devices (Windows only):
|
||||
|
||||
`MIXER /LISTMIDI`
|
||||
37
tldr/dos/mount
Normal file
37
tldr/dos/mount
Normal file
@@ -0,0 +1,37 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# MOUNT
|
||||
|
||||
> Mount host directories/drives/images as virtual DOS drives.
|
||||
> More information: <https://www.dosbox.com/wiki/MOUNT>.
|
||||
|
||||
- Mount current directory as C:
|
||||
|
||||
`MOUNT C .`
|
||||
|
||||
- Mount specific directory as C:
|
||||
|
||||
`MOUNT C {{C:\path o\directory}}`
|
||||
|
||||
- Mount with free space limit (MB):
|
||||
|
||||
`MOUNT C {{C:\path o\directory}} -freesize {{1024}}`
|
||||
|
||||
- Mount floppy drive:
|
||||
|
||||
`MOUNT A {{A:\}} -t floppy`
|
||||
|
||||
- Mount CD-ROM drive:
|
||||
|
||||
`MOUNT D {{D:\}} -t cdrom`
|
||||
|
||||
- Mount CD with extra options:
|
||||
|
||||
`MOUNT D {{D:\}} -t cdrom -usecd {{0}} -ioctl`
|
||||
|
||||
- Unmount drive:
|
||||
|
||||
`MOUNT -u {{C}}`
|
||||
13
tldr/dos/rd
Normal file
13
tldr/dos/rd
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, dos]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# RD
|
||||
|
||||
> Remove a directory.
|
||||
> More information: <https://www.dosbox.com/wiki/Commands#RD>.
|
||||
|
||||
- Remove directory:
|
||||
|
||||
`RD {{path o\directory}}`
|
||||
@@ -13,7 +13,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`gcloud iam list-grantable-roles {{resource}}`
|
||||
|
||||
- Create a custom role for a organization or project:
|
||||
- Create a custom role for an organization or project:
|
||||
|
||||
`gcloud iam roles create {{role_name}} --{{organization|project}} {{organization|project_id}} --file {{path/to/role.yaml}}`
|
||||
|
||||
|
||||
@@ -8,10 +8,10 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> Create contour lines and polygons from a digital elevation model.
|
||||
> More information: <https://gdal.org/en/stable/programs/gdal_contour.html>.
|
||||
|
||||
- Create a vector dataset with contour lines spread over an 100-meter [i]nterval while [a]ttributing the elevation property as "ele":
|
||||
- Create a vector dataset with contour lines spread over a 100-meter [i]nterval while [a]ttributing the elevation property as "ele":
|
||||
|
||||
`gdal_contour -a {{ele}} -i {{100.0}} {{path/to/input.tif}} {{path/to/output.gpkg}}`
|
||||
|
||||
- Create a vector dataset with [p]olygons spread over an 100-meter [i]nterval:
|
||||
- Create a vector dataset with [p]olygons spread over a 100-meter [i]nterval:
|
||||
|
||||
`gdal_contour -i {{100.0}} -p {{path/to/input.tif}} {{path/to/output.gpkg}}`
|
||||
|
||||
@@ -13,10 +13,10 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`git force-clone {{remote_repository_location}} {{path/to/directory}}`
|
||||
|
||||
- Clone a Git repository into a new directory, checking out an specific branch:
|
||||
- Clone a Git repository into a new directory, checking out a specific branch:
|
||||
|
||||
`git force-clone {{[-b|--branch]}} {{branch_name}} {{remote_repository_location}} {{path/to/directory}}`
|
||||
|
||||
- Clone a Git repository into an existing directory of a Git repository, performing a force-reset to resemble it to the remote and checking out an specific branch:
|
||||
- Clone a Git repository into an existing directory of a Git repository, performing a force-reset to resemble it to the remote and checking out a specific branch:
|
||||
|
||||
`git force-clone {{[-b|--branch]}} {{branch_name}} {{remote_repository_location}} {{path/to/directory}}`
|
||||
|
||||
@@ -33,6 +33,6 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`hledger {{[bs|balancesheet]}} {{[-Qt|--quarterly --tree]}} {{[-2|--depth 2]}}`
|
||||
|
||||
- Same as above above, and generate HTML output in `bs.html`:
|
||||
- Same as above, and generate HTML output in `bs.html`:
|
||||
|
||||
`hledger {{[bs|balancesheet]}} {{[-Qt|--quarterly --tree]}} {{[-2|--depth 2]}} {{[-o|--output-file]}} bs.html`
|
||||
|
||||
@@ -25,7 +25,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`huggingface-cli env`
|
||||
|
||||
- Download files from an repository and print out the path (omit filenames to download entire repository):
|
||||
- Download files from a repository and print out the path (omit filenames to download entire repository):
|
||||
|
||||
`huggingface-cli download --repo-type {{repo_type}} {{repo_id}} {{filename1 filename2 ...}}`
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# ifne
|
||||
|
||||
> Run a command depending on the emptyness of `stdin`.
|
||||
> Run a command depending on the emptiness of `stdin`.
|
||||
> More information: <https://manned.org/ifne>.
|
||||
|
||||
- Run the specified command if and only if `stdin` is not empty:
|
||||
|
||||
@@ -8,7 +8,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> Open a file descriptor for read and write.
|
||||
> More information: <https://www.gnu.org/software/bash/manual/bash.html#Opening-File-Descriptors-for-Reading-and-Writing>.
|
||||
|
||||
- Open a file in a file descriptor for read an write:
|
||||
- Open a file in a file descriptor for read and write:
|
||||
|
||||
`exec {{3}}<>{{path/to/file}}`
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`gs -dQUIET -dBATCH {{file.pdf}}`
|
||||
|
||||
- Reduce PDF file size to 150 dpi images for reading on a e-book device:
|
||||
- Reduce PDF file size to 150 dpi images for reading on an e-book device:
|
||||
|
||||
`gs -dNOPAUSE -dQUIET -dBATCH -sDEVICE=pdfwrite -dPDFSETTINGS=/ebook -sOutputFile={{output.pdf}} {{input.pdf}}`
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# i2cget
|
||||
|
||||
> Read from an register of an I2C device.
|
||||
> Read from a register of an I2C device.
|
||||
> See also: `i2cdetect`, `i2cdump`, `i2cset`.
|
||||
> Note: All addresses should be specified in hexadecimal.
|
||||
> More information: <https://manned.org/i2cget>.
|
||||
|
||||
@@ -8,7 +8,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> View the last logged in users.
|
||||
> More information: <https://manned.org/last>.
|
||||
|
||||
- View last login infromation (e.g., username, terminal, boot time, kernel) of all users as read from `/var/log/wtmp`:
|
||||
- View last login information (e.g., username, terminal, boot time, kernel) of all users as read from `/var/log/wtmp`:
|
||||
|
||||
`last`
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> Manipulate network interface MAC addresses.
|
||||
> More information: <https://manned.org/macchanger>.
|
||||
|
||||
- View the current and permanent MAC addresses of a interface:
|
||||
- View the current and permanent MAC addresses of an interface:
|
||||
|
||||
`macchanger {{[-s|--show]}} {{interface}}`
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> When adding an RPM repository, you must also import the corresponding RPM key.
|
||||
> More information: <https://rpm-software-management.github.io/rpm/man/rpmkeys.8>.
|
||||
|
||||
- List all imported RPM keys. Also outputs its Key ID needed for deleting a imported RPM key:
|
||||
- List all imported RPM keys. Also outputs its Key ID needed for deleting an imported RPM key:
|
||||
|
||||
`sudo rpmkeys --list`
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`smem`
|
||||
|
||||
- Print memory usage for current processes for a every user on a system:
|
||||
- Print memory usage for current processes for every user on a system:
|
||||
|
||||
`smem --users`
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
# tcpick
|
||||
|
||||
> Packet sniffing and network traffic analysis tool.
|
||||
> It can capture and display TCP connections and data. It can also monitor network traffic on a interface, host, or port.
|
||||
> It can capture and display TCP connections and data. It can also monitor network traffic on an interface, host, or port.
|
||||
> More information: <https://manned.org/tcpick>.
|
||||
|
||||
- Capture traffic on a specific interface, port, and host:
|
||||
|
||||
@@ -20,7 +20,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`vzdump {{vm_id}} --mode {{suspend|snapshot}}`
|
||||
|
||||
- Back up all guest systems and send an notification email to the root and admin users:
|
||||
- Back up all guest systems and send a notification email to the root and admin users:
|
||||
|
||||
`vzdump --all --mode {{suspend}} --mailto {{root}} --mailto {{admin}}`
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`lprm -h {{server}}:{{port}} {{job_id}}`
|
||||
|
||||
- Cancel multiple jobs with a encrypted connection to the server:
|
||||
- Cancel multiple jobs with an encrypted connection to the server:
|
||||
|
||||
`lprm -E {{job_id1 job_id2 ...}}`
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`pgmramp -rectangle > {{path/to/output.pgm}}`
|
||||
|
||||
- Generate a elliptical greyscale map:
|
||||
- Generate an elliptical greyscale map:
|
||||
|
||||
`pgmramp -ellipse {{path/to/image.pgm}} > {{path/to/output.pgm}}`
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# uniq
|
||||
|
||||
> Output the unique lines from a input or file.
|
||||
> Output the unique lines from an input or file.
|
||||
> Since it does not detect repeated lines unless they are adjacent, we need to sort them first.
|
||||
> See also: `sort`.
|
||||
> More information: <https://www.gnu.org/software/coreutils/manual/html_node/uniq-invocation.html>.
|
||||
|
||||
@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
# iscc
|
||||
|
||||
> Compiler for Inno Setup installers.
|
||||
> It compiles an Inno Setup scripts into an Windows installer executable.
|
||||
> It compiles an Inno Setup scripts into a Windows installer executable.
|
||||
> More information: <https://jrsoftware.org/isinfo.php>.
|
||||
|
||||
- Compile an Inno Setup script:
|
||||
|
||||
@@ -29,7 +29,7 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`slmgr.vbs /ato`
|
||||
|
||||
- [a]c[t]ivate the Windows [p]roduct license offline. Requires Administrator privileges and an Confirmation ID provided by Microsoft Product Activation Center:
|
||||
- [a]c[t]ivate the Windows [p]roduct license offline. Requires Administrator privileges and a Confirmation ID provided by Microsoft Product Activation Center:
|
||||
|
||||
`slmgr.vbs /atp {{confirmation_id}}`
|
||||
|
||||
|
||||
Reference in New Issue
Block a user