Update cheatsheets

This commit is contained in:
ivuorinen
2024-05-30 00:14:41 +00:00
parent 16a9d40c57
commit d224a84a35
4 changed files with 76 additions and 5 deletions

42
tldr/hledger-balance Normal file
View File

@@ -0,0 +1,42 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# hledger balance
> A flexible, general purpose "summing" report that shows accounts with some kind of numeric data.
> This can be balance changes per period, end balances, budget performance, unrealised capital gains, etc.
> More information: <https://hledger.org/hledger.html#balance>.
- Show the balance change in all accounts from all postings over all time:
`hledger balance`
- Show the balance change in accounts named `*expenses*`, as a tree, summarising the top two levels only:
`hledger balance {{expenses}} --tree --depth {{2}}`
- Show expenses each month, and their totals and averages, sorted by total; and their monthly budget goals:
`hledger balance {{expenses}} --monthly --row-total --average --sort-amount --budget`
- Similar to the above, shorter form, matching accounts by Expense type and summarising to two levels, without compression:
`hledger bal type:{{X}} -MTAS --budget -t -{{2}} --no-elide`
- Show end balances (including from postings before the start date), quarterly in 2024, in accounts named `*assets*` or `*liabilities*`:
`hledger balance --historical --period '{{quarterly in 2024}}' {{assets}} {{liabilities}}`
- Similar to the above, shorter form; also show zero balances, sort by total and summarise to three levels:
`hledger bal -HQ date:{{2024}} type:{{AL}} -ES -{{3}}`
- Show investment assets' market value in home currency at the end of each quarter:
`hledger bal -HVQ {{assets:investments}}`
- Show unrealised capital gain/loss from market price changes each quarter, in non-cryptocurrency investment assets:
`hledger bal --gain -Q {{assets:investments}} not:{{cryptocurrency}}`

View File

@@ -6,16 +6,12 @@ source: https://github.com/tldr-pages/tldr.git
# tor
> Enable anonymous communication through the Tor network.
> More information: <https://manned.org/man/tor>.
> More information: <https://manned.org/tor>.
- Connect to the Tor network:
`tor`
- Start a Tor relay:
`tor --relay`
- View Tor configuration:
`tor --config`

View File

@@ -12,6 +12,14 @@ source: https://github.com/tldr-pages/tldr.git
`pylint {{path/to/file.py}}`
- Lint a package or module (must be importable; no `.py` suffix):
`pylint {{package_or_module}}`
- Lint a package from a directory path (must contain an `__init__.py` file):
`pylint {{path/to/directory}}`
- Lint a file and use a configuration file (usually named `pylintrc`):
`pylint --rcfile {{path/to/pylintrc}} {{path/to/file.py}}`

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

@@ -0,0 +1,25 @@
---
syntax: markdown
tags: [tldr, common]
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 --root={{path/to/directory}} {{path/to/guest.xml}}`
- Run a QEMU virtual machine and display verbose information about the startup:
`virt-qemu-run --verbose {{path/to/guest.xml}}`
- Display help:
`virt-qemu-run --help`