Update cheatsheets

This commit is contained in:
ivuorinen
2025-06-05 00:20:17 +00:00
parent 01a2679eb0
commit 24a1ff26c2
10 changed files with 195 additions and 6 deletions

View File

@@ -18,7 +18,7 @@ source: https://github.com/tldr-pages/tldr.git
- Run command in a one-off container in interactive mode and pseudo-TTY:
`docker run --rm {{[-i|--interactive]}} {{[-t|--tty]}} {{image}} {{command}}`
`docker run --rm {{[-it|--interactive --tty]}} {{image}} {{command}}`
- Run command in a new container with passed environment variables:

33
tldr/docker-search Normal file
View File

@@ -0,0 +1,33 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# docker search
> Search for Docker images on Docker Hub.
> More information: <https://docs.docker.com/reference/cli/docker/search/>.
- Search for Docker images by name or keyword:
`docker search {{keyword}}`
- Search for images and only show official ones:
`docker search {{[-f|--filter]}} is-official=true {{keyword}}`
- Search for images and only show automated builds:
`docker search {{[-f|--filter]}} is-automated=true {{keyword}}`
- Search for images with a minimum number of stars:
`docker search {{[-f|--filter]}} stars={{number}} {{keyword}}`
- Limit the number of results:
`docker search --limit {{number}} {{keyword}}`
- Customize the output format:
`docker search {{[-f|--format]}} "{{.Name}}: {{.Description}}" {{keyword}}`

View File

@@ -12,7 +12,7 @@ source: https://github.com/tldr-pages/tldr.git
`lspci`
- Display additional info:
- Display additional information (Note: the `-v` flag can be repeated to increase verbosity):
`lspci -v`

25
tldr/linux/mount.steamos Normal file
View File

@@ -0,0 +1,25 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# mount.steamos
> Mount or unmount SteamOS filesystem partitions.
> More information: <https://gitlab.com/users/evlaV/projects>.
- Mount all necessary partitions from a device to a target directory:
`sudo mount.steamos {{/dev/sdX}} {{/mnt}}`
- Mount with options to exclude specific partitions (e.g. `/home`, overlays):
`sudo mount.steamos {{[-o|--options]}} nohome,nooverlay {{/dev/sdX}} {{/mnt}}`
- Unmount all partitions mounted under a target directory:
`sudo mount.steamos -u {{/mnt}}`
- Display help:
`mount.steamos {{[-h|--help]}}`

View File

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

View File

@@ -0,0 +1,22 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# steamos-devmode
> Enable SteamOS developer mode.
> Note: Developer mode disables read-only protections and initializes the package manager.
> More information: <https://gitlab.com/users/evlaV/projects>.
- Enable developer mode:
`sudo steamos-devmode enable`
- Enable developer mode without confirmation prompt:
`sudo steamos-devmode enable --no-prompt`
- Check if developer mode is currently enabled:
`sudo steamos-devmode status`

View File

@@ -0,0 +1,29 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# steamos-finalize-install
> Complete a SteamOS installation by setting up bootloaders and applying system updates.
> More information: <https://gitlab.com/users/evlaV/projects>.
- Finalize the installation:
`sudo steamos-finalize-install`
- Finalize without updating bootloaders or kernel:
`sudo steamos-finalize-install --no-bootloaders --no-kernel`
- Skip all migration steps:
`sudo steamos-finalize-install --no-migrate`
- Set a specific root hash during finalization:
`sudo steamos-finalize-install --roothash {{hash}}`
- Force system migration steps regardless of environment:
`sudo steamos-finalize-install --force`

31
tldr/linux/zsync Normal file
View File

@@ -0,0 +1,31 @@
---
syntax: markdown
tags: [tldr, linux]
source: https://github.com/tldr-pages/tldr.git
---
# zsync
> Partial/differential file downloader.
> HTTPS is not supported - use HTTP URLs only.
> See also: `rsync`.
> More information: <https://manned.org/zsync>.
- Download a file using a `.zsync` control file:
`zsync {{path/to/url.zsync}}`
- Use a local file as a seed to avoid re-downloading unchanged parts:
`zsync -i {{path/to/existing_file}} {{path/to/url.zsync}}`
- Save the updated file under a specific name:
`zsync -i {{path/to/existing_file}} -o {{path/to/new_file}} {{path/to/url.zsync}}`
- Resume a partial download and keep the temporary file:
`zsync -k {{path/to/url.zsync}}`
- Run in quiet mode with minimal output (no progress bar, download rate, or ETA display):
`zsync -q {{path/to/url.zsync}}`

View File

@@ -10,16 +10,16 @@ source: https://github.com/tldr-pages/tldr.git
- Retrieve all public SSH keys of a remote host:
`ssh-keyscan {{host}}`
`ssh-keyscan {{hostname}}`
- Retrieve all public SSH keys of a remote host listening on a specific port:
`ssh-keyscan -p {{port}} {{host}}`
`ssh-keyscan -p {{port}} {{hostname}}`
- Retrieve certain types of public SSH keys of a remote host:
`ssh-keyscan -t {{rsa,dsa,ecdsa,ed25519}} {{host}}`
`ssh-keyscan -t {{rsa,dsa,ecdsa,ed25519}} {{hostname}}`
- Manually update the SSH known_hosts file with the fingerprint of a given host:
`ssh-keyscan -H {{host}} >> ~/.ssh/known_hosts`
`ssh-keyscan -H {{hostname}} >> ~/.ssh/known_hosts`

37
tldr/uv-init Normal file
View File

@@ -0,0 +1,37 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# uv init
> Create a new Python project.
> More information: <https://docs.astral.sh/uv/reference/cli/#uv-init>.
- Initialize a project in the current directory:
`uv init`
- Initialize a project with a certain name:
`uv init {{project_name}}`
- Create a project in a given directory:
`uv init --directory {{path/to/directory}} {{project_name}}`
- Create a project for a Python library:
`uv init {{[--lib|--library]}} {{project_name}}`
- Specify the build system:
`uv init --build-backend {{build_backend}} {{project_name}}`
- Only create a `pyproject.toml`:
`uv init --bare {{project_name}}`
- Set the project description:
`uv init --description "{{description}}" {{project_name}}`