File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Release
2+
3+ on :
4+ workflow_dispatch :
5+ inputs :
6+ version :
7+ description : ' Version to release (e.g., v1.0.0)'
8+ required : true
9+ type : string
10+ dojo_version :
11+ description : ' Dojo version to use'
12+ required : true
13+ type : string
14+
15+ jobs :
16+ create-release :
17+ runs-on : ubuntu-latest
18+ env :
19+ DOJO_VERSION : ${{ inputs.dojo_version }}
20+ steps :
21+ - uses : actions/checkout@v3
22+
23+ # Setup and test with specified Dojo version
24+ - run : curl -L https://install.dojoengine.org | bash
25+ - run : /home/runner/.config/.dojo/bin/dojoup -v ${{ env.DOJO_VERSION }}
26+ - run : |
27+ /home/runner/.config/.dojo/bin/sozo build
28+ /home/runner/.config/.dojo/bin/sozo test
29+
30+ # Create tag and release
31+ - name : Create Tag
32+ run : |
33+ git tag ${{ inputs.version }}
34+ git push origin ${{ inputs.version }}
35+
36+ - name : Create Release
37+ uses : softprops/action-gh-release@v1
38+ with :
39+ tag_name : ${{ inputs.version }}
40+ name : Release ${{ inputs.version }}
41+ draft : false
42+ prerelease : false
43+ generate_release_notes : true
Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on :
4+ push :
5+ branches :
6+ - " main"
7+ pull_request :
8+
9+ jobs :
10+ sozo-test :
11+ runs-on : ubuntu-latest
12+ env :
13+ DOJO_VERSION : v1.1.1
14+ steps :
15+ - uses : actions/checkout@v3
16+ - uses : software-mansion/setup-scarb@v1
17+ with :
18+ scarb-version : " 2.9.2"
19+ - run : |
20+ curl -L https://install.dojoengine.org | bash
21+ /home/runner/.config/.dojo/bin/dojoup -v ${{ env.DOJO_VERSION }}
22+ - run : |
23+ /home/runner/.config/.dojo/bin/sozo build
24+ /home/runner/.config/.dojo/bin/sozo test
25+ if [[ `git status --porcelain` ]]; then
26+ echo The git repo is dirty
27+ echo "Make sure to run \"sozo build\" after changing Scarb.toml"
28+ exit 1
29+ fi
You can’t perform that action at this time.
0 commit comments