Public release release-ff7f847f143d
Source commit: ff7f847f143dc67864bed68a86cf259114384bd5 Public tree identity: sha256:bb7dcd2ac78bdbad2f4eba0f49be649d446d67f96f4eb2796941c026412fc032
This commit is contained in:
commit
70319cde15
210 changed files with 78958 additions and 0 deletions
22
scripts/migrate-clusterflux-state.sh
Executable file
22
scripts/migrate-clusterflux-state.sh
Executable file
|
|
@ -0,0 +1,22 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
migrate_path() {
|
||||
local source="$1"
|
||||
local destination="$2"
|
||||
if [[ ! -e "$source" ]]; then
|
||||
return
|
||||
fi
|
||||
if [[ -e "$destination" ]]; then
|
||||
printf 'refusing to overwrite existing destination: %s\n' "$destination" >&2
|
||||
exit 1
|
||||
fi
|
||||
mv -- "$source" "$destination"
|
||||
printf 'migrated %s -> %s\n' "$source" "$destination"
|
||||
}
|
||||
|
||||
migrate_path "${HOME}/.disasmer" "${HOME}/.clusterflux"
|
||||
migrate_path "${XDG_CONFIG_HOME:-${HOME}/.config}/disasmer" \
|
||||
"${XDG_CONFIG_HOME:-${HOME}/.config}/clusterflux"
|
||||
migrate_path "${PWD}/.disasmer" "${PWD}/.clusterflux"
|
||||
migrate_path "${PWD}/disasmer.toml" "${PWD}/clusterflux.toml"
|
||||
Loading…
Add table
Add a link
Reference in a new issue