clean up old formatting

This commit is contained in:
2026-04-27 13:13:22 +02:00
parent ea4f44e096
commit 319ae8df79
11 changed files with 39 additions and 28 deletions

View File

@@ -41,7 +41,7 @@ Check your `~/.config/profanity/profrc` for how to data's saved.
## Automatically Sign In
To automatically sign in, add your password to [pass](../data/pass.md).
To automatically sign in, add your password to [pass](data/pass.md).
```
/account set ${name}@${host} eval_password pass *xmpp*

View File

@@ -10,7 +10,7 @@ tags:
Combine many files and directories into a single t-archive file.
```sh
tar cf "$ARCHIVE".tar $DIR
tar cf "${archive}".tar ${dir}
```
You can remember this with the mnemonic '*C*reate *F*ile'.
@@ -18,13 +18,13 @@ Unfortunately, this stores the full file path, so making a tar archive of `/etc/
It's often better to tell tar which path to start from using the `-C` flag.
```sh
tar cf "$ARCHIVE".tar -C /etc/ nginx
tar cf "${archive}".tar -C /etc/ nginx
```
Check the contents of your archive with:
```sh
tar tf "$ARCHIVE".tar
tar tf "${archive}".tar
```
If you want to store 'everything in a directory', then using `*` will not work, because it will target everything in the *current* directory.
@@ -33,7 +33,7 @@ Instead, you can store the target in a variable:
```sh
files=$(ls /etc/nginx)
tar cf "$ARCHIVE".tar -C /etc/nginx/ $file
tar cf "${archive}".tar -C /etc/nginx/ $file
```
# Extract
@@ -41,7 +41,7 @@ tar cf "$ARCHIVE".tar -C /etc/nginx/ $file
Extract the tar archive with
```sh
tar xf "$ARCHIVE".tar
tar xf "${archive}".tar
```
You can remember this with the mnemonic 'e*X*tract *F*ile'.
@@ -51,7 +51,7 @@ You can remember this with the mnemonic 'e*X*tract *F*ile'.
Create a zip-compressed archive with the `z` flag.
```sh
tar czf "$ARCHIVE".tgz -C /etc/nginx/ $file
tar czf "${archive}".tgz -C /etc/nginx/ $file
```
You can use any file ending you want, but sane people like to use '.tgz' or '.tar.tgz'.

View File

@@ -132,7 +132,7 @@ Refreshing keys will tell you if some key you have contains a signature from som
gpg --refresh-keys
```
You can use the [crontab](../../system/cron.md) to refresh keys, but this will mostly fail, since keyservers often don't hold the right data.
You can use the [crontab](system/cron.md) to refresh keys, but this will mostly fail, since keyservers often don't hold the right data.
# Export

View File

@@ -8,7 +8,7 @@ requires:
- data/gpg.md
---
Setup [gpg](gpg.md) keys.
Setup [gpg](data/gpg.md) keys.
Show your gpg secret it:
@@ -19,28 +19,37 @@ gpg --list-secret-keys
Then use the id number under `sec` to make a pass repo:
```sh
KEY="$(gpg --list-secret-keys | grep -m 1 -A1 '^sec' | tail -n 1)"
key="$(gpg --list-secret-keys | grep -m 1 -A1 '^sec' | tail -n 1)"
```
```sh
pass init $KEY
pass init $key
cat .password-store/.gpg-id
```
To add a basic password, e.g. for `$WEBSITE`:
To add a basic password, e.g. for `${website}`:
```sh
pass $WEBSITE
pass ${website}
```
To insert a multi-line password, e.g. with a login name:
```sh
pass add -m $WEBSITE
pass add -m ${website}
```
Remove a password:
```sh
pass rm $WEBSITE
pass rm ${website}
```
You can generate passwords with `xkcdpass`.
Automatically insert a password with `pass insert`:
```sh
xkcdpass | pass insert --echo ${website}
```

View File

@@ -44,10 +44,11 @@ You might get it in the `apache` package or similar.
`htpasswd` allows you to generate passwords for users, and place them in `/etc/radicale/users`.
```sh
PASS="$(xkcdpass)"
htpasswd -nb $USER "$PASS" | sudo tee -a /etc/radicale/users
echo "Your username is $USER"
echo "Your password is $PASS"
pass="$(xkcdpass)"
username=alice
htpasswd -nb ${username} "${pass}" | sudo tee -a /etc/radicale/users
echo "Your username is ${username}"
echo "Your password is ${pass}"
```
Right now, you can't sign into the server except through the localhost, which is pointless.
So now we add a subdomain to `nginx`.
@@ -97,8 +98,8 @@ sudo ln -s /etc/nginx/sites-available/radicale /etc/nginx/sites-enables/
Finally, replace the example `DOMAIN` with your actual domain name.
```sh
DOMAIN=whatever.com
sudo sed -i "s/DOMAIN/$DOMAIN/g" /etc/nginx/sites-available/radicale
domain=whatever.com
sudo sed -i "s/DOMAIN/${domain}/g" /etc/nginx/sites-available/radicale
```
(optional: replace that `cal.` prefix with anything else)
@@ -111,7 +112,7 @@ sudo nginx -t
You will almost certainly need a new SSL certificate for the site:
```sh
sudo certbod -d cal.$DOMAIN
sudo certbod -d cal.${domain}
```
Start or restart both services:

View File

@@ -26,7 +26,7 @@ Once you have the database, you can find nearly any file instantly.
- Search for jpg images with 'dog' or 'Dog' in the name: `locate -i dog jpg`
- Search for videos: `plocate --regex '.mp4$|.mkv$|.wmv$|.webm$|.mov$|.avi$'`
For best results, run `updatedb` regularly, perhaps in [crontab](../system/cron.md).
For best results, run `updatedb` regularly, perhaps in [crontab](system/cron.md).
## Search More Places

View File

@@ -41,7 +41,7 @@ git clone http://localhost:23232/${some_repo}.git
### `https` Setup
Put this file at `/etc/nginx/sites-enabled/$DOMAIN.tld`, then set up standard certificates with [nginx](../../networking/website/nginx.md).
Put this file at `/etc/nginx/sites-enabled/$DOMAIN.tld`, then set up standard certificates with [nginx](networking/nginx.md).
(replace `${DOMAIN_NAME}` with your domain's name).

View File

@@ -58,5 +58,5 @@ brightnessctl s 10%+
- [autologin](autologin.md)
- [services](sv.md)
- [wifi](../../networking/wpa_supplicant.md)
- [wifi](networking/wpa_supplicant.md)

View File

@@ -3,9 +3,10 @@ title: printers
tags:
- hardware
---
# Cups: The Common Unix Printing System
Configure cups at /etc/cups/supsd.conf, or visit the local webpage at http://localhost:631 if you want to use the Apple interface, otherwise, it's the printing daemon.
Configure cups at `/etc/cups/supsd.conf`, or visit the local webpage at http://localhost:631 if you want to use the Apple interface, otherwise, it's the printing daemon.
# The Printing Daemon

View File

@@ -16,7 +16,7 @@ rdfind $dir
$EDITOR results.txt
```
Replace the duplicated files with [hard links](../basics/hard_links.md).
Replace the duplicated files with [hard links](system/hard_links.md).
```sh
rdfind -makehardlinks true $dir

View File

@@ -5,7 +5,7 @@ tags:
- make
---
Using the [basic example](../makefiles.md), you can make a complete backup of all backup files.
Using the [basic example](system/makefiles.md), you can make a complete backup of all backup files.
This file will depend upon everything inside the `$(storage_directory)`.
Unlike `bash`, you can't just say `storage_directory/*`: the pattern must be stated as a 'wildcard'.