Update cheatsheets

This commit is contained in:
ivuorinen
2025-10-11 00:18:10 +00:00
parent 4ccd905055
commit d185573d5d
9 changed files with 193 additions and 1 deletions

14
tldr/gh-preview Normal file
View File

@@ -0,0 +1,14 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# gh preview
> Preview GitHub CLI programs for testing and development purposes.
> These commands are unstable and may change at any time.
> More information: <https://cli.github.com/manual/gh_preview>.
- Run a specific preview command:
`gh preview {{command}}`

29
tldr/linux/evince Normal file
View File

@@ -0,0 +1,29 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# evince
> View documents.
> More information: <https://manned.org/evince>.
- Open a PDF file:
`evince {{path/to/file.pdf}}`
- Open multiple documents:
`evince {{file1.pdf file2.pdf ...}}`
- Open in fullscreen mode:
`evince {{[-f|--fullscreen]}} {{path/to/file.pdf}}`
- Open in presentation mode:
`evince {{[-s|--presentation]}} {{path/to/file.pdf}}`
- Open a specific page number:
`evince {{[-i|--page-index]}} {{5}} {{path/to/file.pdf}}`

41
tldr/linux/grub-mount Normal file
View File

@@ -0,0 +1,41 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# grub-mount
> Mount a file system or file system image read-only using GRUB's file system drivers.
> More information: <https://www.gnu.org/software/grub/manual/grub/grub.html#Invoking-grub_002dmount>.
- Mount a block device or file system image to a mount point:
`grub-mount {{/dev/sdXY}} {{/mnt}}`
- Mount an entire disk image's second partition, `-r` specifies the partition number in the image:
`grub-mount {{[-r|--root]}} {{2}} {{disk.img}} {{/mnt}}`
- Mount an encrypted device and prompt for a passphrase:
`grub-mount {{[-C|--crypto]}} {{/dev/sdXY}} {{/mnt}}`
- Load a ZFS encryption key from a file:
`grub-mount {{[-K|--zfs-key]}} {{/path/to/zfs.key}} {{/dev/sdX}} {{/mnt}}`
- Show debugging output for a matching category:
`grub-mount {{[-d|--debug]}} {{string}} {{image}} {{/mnt}}`
- Enable verbose output:
`grub-mount {{[-v|--verbose]}} {{image}} {{/mnt}}`
- Display help:
`grub-mount {{[-?|--help]}}`
- Display version:
`grub-mount --version`

21
tldr/linux/lsmem Normal file
View File

@@ -0,0 +1,21 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# lsmem
> List the characteristics of the system's memory, including size and type of memory modules.
> More information: <https://manned.org/lsmem>.
- List memory information:
`lsmem`
- List memory information in JSON format:
`lsmem {{[-J|--json]}}`
- List memory information with size in bytes:
`lsmem {{[-b|--bytes]}}`

View File

@@ -23,7 +23,7 @@ source: https://github.com/tldr-pages/tldr.git
- Remove a module and those that depend on it from the kernel:
`sudo modprobe --remove-dependencies {{module_name}}`
`sudo modprobe {{[-r|--remove]}} --remove-holders {{module_name}}`
- Show a kernel module's dependencies:

37
tldr/linux/pvchange Normal file
View File

@@ -0,0 +1,37 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# pvchange
> Change attributes of physical volume(s).
> More information: <https://manned.org/pvchange>.
- Allow allocation on a physical volume:
`pvchange {{[-x|--allocatable]}} y {{/dev/sdXN}}`
- Disallow allocation on a physical volume:
`pvchange {{[-x|--allocatable]}} n {{/dev/sdXN}}`
- Ignore metadata areas on a physical volume:
`pvchange --metadataignore y {{/dev/sdXN}}`
- Stop ignoring metadata areas on a physical volume:
`pvchange --metadataignore n {{/dev/sdXN}}`
- Add a tag to a physical volume:
`pvchange --addtag {{tag}} {{/dev/sdXN}}`
- Generate a new UUID for a physical volume (use with care):
`pvchange --uuid {{/dev/sdXN}}`
- Change all visible physical volumes (combine with other options such as allocatable):
`pvchange {{[-a|--all]}} {{[-x|--allocatable]}} y`

View File

@@ -0,0 +1,17 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# systemctl default
> Enter system default mode.
> More information: <https://www.freedesktop.org/software/systemd/man/latest/systemctl.html#default>.
- Enter default mode as a blocking operation:
`systemctl default`
- Enter default mode as asynchronous operation:
`systemctl default --no-block`

25
tldr/mvn-compile Normal file
View File

@@ -0,0 +1,25 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# mvn compile
> Compile a Maven project's source code.
> More information: <https://manned.org/mvn>.
- Compile the project's source code:
`mvn compile`
- Clean compiled files and recompile:
`mvn clean compile`
- Compile a specific module in a multi-module project:
`mvn compile {{[-pl|--projects]}} {{module_name}}`
- Skip tests while compiling:
`mvn compile {{[-D|--define]}} skipTests`

View File

@@ -20,6 +20,10 @@ source: https://github.com/tldr-pages/tldr.git
`pulumi up {{[-s|--stack]}} {{stack}}`
- Refresh the state of the stack's resources before updating:
`pulumi up {{[-r|--refresh]}}`
- Don't display stack outputs:
`pulumi up --suppress-outputs`
@@ -27,3 +31,7 @@ source: https://github.com/tldr-pages/tldr.git
- Continue updating the resources, even if an error is encountered:
`pulumi up --continue-on-error`
- Display help:
`pulumi up {{[-h|--help]}}`