mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-02-26 09:53:04 +00:00
Update cheatsheets
This commit is contained in:
13
tldr/linux/exch
Normal file
13
tldr/linux/exch
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, linux]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# exch
|
||||
|
||||
> Swap the filepaths and filenames of two files.
|
||||
> More information: <https://manned.org/exch>.
|
||||
|
||||
- Swap filepaths:
|
||||
|
||||
`exch {{path/to/file1}} {{path/to/file2}}`
|
||||
25
tldr/linux/lsfd
Normal file
25
tldr/linux/lsfd
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, linux]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# lsfd
|
||||
|
||||
> List open files and the corresponding processes in Linux.
|
||||
> More information: <https://manned.org/lsfd>.
|
||||
|
||||
- List all open file descriptors:
|
||||
|
||||
`lsfd`
|
||||
|
||||
- List all files kept open by a specific program:
|
||||
|
||||
`lsfd -Q 'PID == {{process_ID}}'`
|
||||
|
||||
- Check what program has a specific file open:
|
||||
|
||||
`lsfd -Q "NAME == '{{/path/to/file}}'"`
|
||||
|
||||
- List open IPv4 or IPv6 sockets:
|
||||
|
||||
`lsfd -i{{4|6}}`
|
||||
12
tldr/linux/pacman-q
Normal file
12
tldr/linux/pacman-q
Normal file
@@ -0,0 +1,12 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, linux]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# pacman -Q
|
||||
|
||||
> This command is an alias of `pacman --query`.
|
||||
|
||||
- View documentation for the original command:
|
||||
|
||||
`tldr pacman query`
|
||||
@@ -9,34 +9,34 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
> See also: `pacman`.
|
||||
> More information: <https://manned.org/pacman.8>.
|
||||
|
||||
- List installed packages and versions:
|
||||
- [Q]uery the local package database and list installed packages and versions:
|
||||
|
||||
`pacman --query`
|
||||
`pacman -Q`
|
||||
|
||||
- List only packages and versions that were explicitly installed:
|
||||
- List only packages and versions that were [e]xplicitly installed:
|
||||
|
||||
`pacman --query --explicit`
|
||||
`pacman -Qe`
|
||||
|
||||
- Find which package owns a file:
|
||||
- Find which package [o]wns a file:
|
||||
|
||||
`pacman --query --owns {{filename}}`
|
||||
`pacman -Qo {{filename}}`
|
||||
|
||||
- Display information about an installed package:
|
||||
- Display information about an [i]nstalled package:
|
||||
|
||||
`pacman --query --info {{package}}`
|
||||
`pacman -Qi {{package}}`
|
||||
|
||||
- List files owned by a package:
|
||||
- Display the [l]ist of files owned by a specific package:
|
||||
|
||||
`pacman --query --list {{package}}`
|
||||
`pacman -Ql {{package}}`
|
||||
|
||||
- List orphan packages (installed as dependencies but not required by any package):
|
||||
- List orphan packages (installed as [d]ependencies but unrequired ([t]) by any package and print in [q]uiet mode (only package name is displayed)):
|
||||
|
||||
`pacman --query --unrequired --deps --quiet`
|
||||
`pacman -Qdtq`
|
||||
|
||||
- List installed packages not found in the repositories:
|
||||
- List installed packages foreign ([m]) to the repository database:
|
||||
|
||||
`pacman --query --foreign`
|
||||
`pacman -Qm`
|
||||
|
||||
- List outdated packages:
|
||||
- List packages that can be [u]pgraded:
|
||||
|
||||
`pacman --query --upgrades`
|
||||
`pacman -Qu`
|
||||
|
||||
13
tldr/linux/pg
Normal file
13
tldr/linux/pg
Normal file
@@ -0,0 +1,13 @@
|
||||
---
|
||||
syntax: markdown
|
||||
tags: [tldr, linux]
|
||||
source: https://github.com/tldr-pages/tldr.git
|
||||
---
|
||||
# pg
|
||||
|
||||
> View files one page at a time.
|
||||
> More information: <https://manned.org/pg>.
|
||||
|
||||
- View a file:
|
||||
|
||||
`pg {{path/to/file}}`
|
||||
Reference in New Issue
Block a user