mirror of
https://github.com/DictXiong/dotfiles.git
synced 2024-11-24 19:17:01 +08:00
Dict Xiong
9a4c9556f6
* common.sh: export vars in env; zshrc: gdebug * fix error when locale not exists * DFS_COLOR * common.sh: parse args automatically * ci: test common.sh getopts * common.sh: argparser supports spaces * ciot: init * ciot -> diot; remove sibd, sob and snasp * rename diot -> riot * update home0 ssh pubkey; fix ci temperarily * gdebug will record time * gdebug supports empty; --dry-run wip * get.dotfiles.cn * bug fix (Thu Jan 5 20:53:58 CST 2023) * fix ci * fix ci * install.sh: -d will set -x * ci: -asl * getdfs: install for another user using -u <uname> * try fix when su doesnot exist * bug fix (Thu Jan 5 22:58:40 CST 2023) * bug fix (Thu Jan 5 22:59:33 CST 2023) * introduce SUDOE and so debug * ask_for_yn now use stdout to return * getdfs: support multiple users * install.sh: -x to set dfs config; ci * fix ci * bug fix (Fri Jan 6 15:11:24 CST 2023) * auto-detect DFS_NO_WALL * bug fix (Fri Jan 6 15:43:25 CST 2023) * getdfs: ${repo} * bug fix (Fri Jan 6 16:08:41 CST 2023) * getdfs: prompt user Co-authored-by: xiongdian.me <xiongdian.me@bytedance.com>
131 lines
3.1 KiB
YAML
131 lines
3.1 KiB
YAML
name: test
|
|
on:
|
|
push: ~
|
|
workflow_dispatch: ~
|
|
jobs:
|
|
test-ubuntu:
|
|
name: test on ubuntu
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: checkout repo
|
|
uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: install dfs
|
|
run: |
|
|
rev=`git rev-parse HEAD`
|
|
pwd
|
|
set -x
|
|
DFS_NO_WALL=0 ./install.sh -adl
|
|
test `git rev-parse HEAD` = "$rev"
|
|
|
|
- name: antigen build
|
|
shell: /bin/zsh -ileo PIPE_FAIL {0}
|
|
run: |
|
|
echo $SHELL
|
|
antigen list
|
|
|
|
- name: run tests and reset
|
|
shell: /bin/zsh -ileo PIPE_FAIL {0}
|
|
run: |
|
|
source tools/test.zsh
|
|
antigen reset
|
|
rm -rf $ANTIGEN $HOME/.antigen $HOME/.config/dotfiles
|
|
./install.sh -dl
|
|
|
|
- name: antigen build with DFS_NO_WALL
|
|
shell: /bin/zsh -ileo PIPE_FAIL {0}
|
|
run: |
|
|
echo $SHELL
|
|
antigen list
|
|
|
|
- name: run tests
|
|
shell: /bin/zsh -ileo PIPE_FAIL {0}
|
|
run: source tools/test.zsh
|
|
|
|
test-macos:
|
|
name: test on macos
|
|
runs-on: macos-12
|
|
steps:
|
|
- name: checkout repo
|
|
uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: install dfs
|
|
run: |
|
|
rev=`git rev-parse HEAD`
|
|
pwd
|
|
set -x
|
|
DFS_NO_WALL=0 ./install.sh -adl
|
|
test `git rev-parse HEAD` = "$rev"
|
|
|
|
- name: antigen build
|
|
shell: /bin/zsh -ileo PIPE_FAIL {0}
|
|
run: |
|
|
echo $SHELL
|
|
antigen list
|
|
|
|
- name: run tests and reset
|
|
shell: /bin/zsh -ileo PIPE_FAIL {0}
|
|
run: |
|
|
source tools/test.zsh
|
|
antigen reset
|
|
rm -rf $ANTIGEN $HOME/.antigen $HOME/.config/dotfiles
|
|
./install.sh -dl
|
|
|
|
- name: antigen build with DFS_NO_WALL
|
|
shell: /bin/zsh -ileo PIPE_FAIL {0}
|
|
run: |
|
|
echo $SHELL
|
|
antigen list
|
|
|
|
- name: run tests
|
|
shell: /bin/zsh -ileo PIPE_FAIL {0}
|
|
run: source tools/test.zsh
|
|
|
|
test-autodep:
|
|
name: test of auto-install dependencies
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: remove dependencies
|
|
run: |
|
|
sudo apt-get -y remove curl vim python3
|
|
|
|
- name: checkout repo
|
|
uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: install dfs
|
|
run: |
|
|
rev=`git rev-parse HEAD`
|
|
set -x
|
|
./install.sh -dal
|
|
test `git rev-parse HEAD` = "$rev"
|
|
|
|
- name: antigen build
|
|
shell: /bin/zsh -ileo PIPE_FAIL {0}
|
|
run: |
|
|
echo $SHELL
|
|
antigen list
|
|
|
|
test-get-dotfiles-cn:
|
|
name: test of get.dotfiles.cn script
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: checkout repo
|
|
uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: run the script
|
|
run: |
|
|
repo=https://github.com/DictXiong/dotfiles bash tools/get.dotfiles.cn -asl
|
|
|
|
- name: run tests
|
|
shell: /bin/zsh -ileo PIPE_FAIL {0}
|
|
run: |
|
|
dfs cd
|
|
source tools/test.zsh |