2022-11-05 19:45:21 +08:00
|
|
|
#!/bin/false "This script should be sourced in zsh, not executed directly"
|
2022-08-28 20:51:44 +08:00
|
|
|
|
|
|
|
set -ex
|
|
|
|
|
|
|
|
# check files
|
|
|
|
cd /
|
2022-11-05 19:45:21 +08:00
|
|
|
l
|
|
|
|
cd ~
|
|
|
|
l
|
2022-08-28 20:51:44 +08:00
|
|
|
dfs cd
|
2022-11-05 19:45:21 +08:00
|
|
|
l
|
2022-08-28 20:51:44 +08:00
|
|
|
pwd
|
|
|
|
test -f .zshrc2
|
|
|
|
diff -q ./.ssh/authorized_keys2 ~/.ssh/authorized_keys2
|
|
|
|
grep -q ".zshrc2" ~/.zshrc
|
|
|
|
|
|
|
|
# check scripts and functions
|
|
|
|
dfs version
|
|
|
|
dfs log 1
|
2022-11-05 19:45:21 +08:00
|
|
|
z ~
|
|
|
|
test ~ -ef "$(pwd)"
|
2022-08-28 20:51:44 +08:00
|
|
|
dogo
|
2022-11-14 01:37:48 +08:00
|
|
|
doll
|
2022-11-05 19:45:21 +08:00
|
|
|
dfs cd
|
2022-08-28 20:51:44 +08:00
|
|
|
tools/common.sh get_os_type
|
|
|
|
tools/common.sh get_linux_dist
|
|
|
|
|
|
|
|
# check alias
|
2022-11-15 01:28:38 +08:00
|
|
|
alias p114
|
|
|
|
sibd || which sibd
|
|
|
|
piv-agent || which piv-agent
|
2022-11-15 22:18:16 +08:00
|
|
|
git-branches || which git-branches
|
2022-08-28 20:51:44 +08:00
|
|
|
|
|
|
|
# check update
|
2022-11-05 19:45:21 +08:00
|
|
|
DFS_VERSION=`dfs version`
|
2022-08-28 20:51:44 +08:00
|
|
|
dfs update
|
|
|
|
dfs version
|
|
|
|
test `git rev-parse HEAD` = `curl -fsSL https://api.beardic.cn/get-var/dfs-commit-id`
|
2022-11-05 19:45:21 +08:00
|
|
|
|
|
|
|
# clean
|
|
|
|
git reset --hard $DFS_VERSION
|
2022-11-12 20:05:29 +08:00
|
|
|
|
|
|
|
# then check install.sh
|
|
|
|
./install.sh -l
|
|
|
|
dfs version
|
|
|
|
test `git rev-parse HEAD` = `curl -fsSL https://api.beardic.cn/get-var/dfs-commit-id`
|
|
|
|
|
|
|
|
# clean
|
|
|
|
git reset --hard $DFS_VERSION
|
|
|
|
|
2022-11-05 19:45:21 +08:00
|
|
|
set +x
|