Skip to content

Commit

Permalink
Docs for backups, install scripts touch ups
Browse files Browse the repository at this point in the history
  • Loading branch information
curusarn committed Mar 19, 2023
1 parent a0adcee commit a692aae
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
16 changes: 16 additions & 0 deletions installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,3 +75,19 @@ RESH also adds a following lines to `~/.zshrc` and `~/.bashrc` to load itself on
```

:information_source: RESH follows [XDG directory specification ⇗](https://maex.me/2019/12/the-power-of-the-xdg-base-directory-specification/)

#### Backup files

During update **config** and **history** files are backed up to:

- `~/.config/resh.toml.backup-<timestamp>`
- `~/.local/share/resh/history.reshjson.backup-<timestamp>`
- `$XDG_DATA_HOME/resh/history.reshjson.backup-<timestamp>` (if set)

Backups allow safe rollbacks during or after installation.
They are not deleted automatically. You can delete them with:

```shell
rm ~/.config/resh.toml.backup-*
rm ${XDG_DATA_HOME-~/.local/share}/resh/history.reshjson.backup-*
```
2 changes: 1 addition & 1 deletion scripts/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ if [ -z "${__RESH_VERSION-}" ]; then
# First installation
# Stop the daemon anyway just to be sure
# But don't output anything
./scripts/resh-daemon-stop.sh -q
./scripts/resh-daemon-stop.sh -q ||:
else
./scripts/resh-daemon-stop.sh
fi
Expand Down
2 changes: 1 addition & 1 deletion scripts/rawinstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ fname_binaries="resh_${version}_${OS}_${ARCH}.tar.gz"
dl_binaries="$dl_base/$fname_binaries"


tmpdir="$(mktemp -d /tmp/resh-rawinstall-XXXXXX)"
tmpdir="$(mktemp -d /tmp/resh-rawinstall-XXXXXXXX)"
# echo
# echo "Changing to $tmpdir ..."
cd "$tmpdir"
Expand Down

0 comments on commit a692aae

Please sign in to comment.