File tree Expand file tree Collapse file tree 1 file changed +46
-0
lines changed
Expand file tree Collapse file tree 1 file changed +46
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CI/CD
2+
3+ on :
4+ push :
5+ branches : [main]
6+ tags : ["v*"]
7+ pull_request :
8+ branches : [main]
9+
10+ jobs :
11+ test :
12+ runs-on : ubuntu-latest
13+ steps :
14+ - uses : actions/checkout@v4
15+ - name : Install Zsh
16+ run : sudo apt-get update && sudo apt-get install -y zsh
17+ - name : Install Oh My Zsh
18+ run : |
19+ sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended
20+ - name : Setup plugin
21+ run : |
22+ mkdir -p ~/.oh-my-zsh/custom/plugins/venvswitch
23+ cp venvswitch.plugin.zsh ~/.oh-my-zsh/custom/plugins/venvswitch/
24+ echo 'plugins=(venvswitch)' >> ~/.zshrc
25+ - name : Check syntax
26+ run : zsh -n venvswitch.plugin.zsh
27+ - name : Test basic functionality
28+ run : |
29+ zsh -c 'source ~/.zshrc && venvswitch_config'
30+ - name : Install shellcheck
31+ run : sudo apt-get install -y shellcheck
32+ - name : Lint with shellcheck
33+ run : shellcheck venvswitch.plugin.zsh
34+
35+ release :
36+ if : startsWith(github.ref, 'refs/tags/v')
37+ needs : test
38+ runs-on : ubuntu-latest
39+ steps :
40+ - uses : actions/checkout@v4
41+ - name : Create Release
42+ uses : softprops/action-gh-release@v1
43+ with :
44+ generate_release_notes : true
45+ env :
46+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments