File tree Expand file tree Collapse file tree 1 file changed +64
-0
lines changed
Expand file tree Collapse file tree 1 file changed +64
-0
lines changed Original file line number Diff line number Diff line change 1+ name : build addon
2+
3+ on :
4+ push :
5+ tags : ["*"]
6+ # To build on main/master branch, uncomment the following line:
7+ branches : [ main , master ]
8+
9+ pull_request :
10+ branches : [ main, master ]
11+
12+ workflow_dispatch :
13+
14+ jobs :
15+ build :
16+
17+ runs-on : ubuntu-latest
18+
19+ steps :
20+ - uses : actions/checkout@v3
21+
22+ - run : echo -e "pre-commit\nscons\nmarkdown">requirements.txt
23+
24+ - name : Set up Python
25+ uses : actions/setup-python@v4
26+ with :
27+ python-version : 3.9
28+ cache : ' pip'
29+
30+ - name : Install dependencies
31+ run : |
32+ python -m pip install --upgrade pip wheel
33+ pip install -r requirements.txt
34+ sudo apt-get update -y
35+ sudo apt-get install -y gettext
36+
37+ - name : Code checks
38+ run : export SKIP=no-commit-to-branch; pre-commit run --all
39+
40+ - name : building addon
41+ run : scons
42+
43+ - uses : actions/upload-artifact@v3
44+ with :
45+ name : packaged_addon
46+ path : ./*.nvda-addon
47+
48+ upload_release :
49+ runs-on : ubuntu-latest
50+ if : ${{ startsWith(github.ref, 'refs/tags/') }}
51+ needs : ["build"]
52+ steps :
53+ - uses : actions/checkout@v3
54+ - name : download releases files
55+ uses : actions/download-artifact@v3
56+ - name : Display structure of downloaded files
57+ run : ls -R
58+
59+ - name : Release
60+ uses : softprops/action-gh-release@v1
61+ with :
62+ files : packaged_addon/*.nvda-addon
63+ fail_on_unmatched_files : true
64+ prerelease : ${{ contains(github.ref, '-') }}
You can’t perform that action at this time.
0 commit comments