File tree Expand file tree Collapse file tree 1 file changed +14
-8
lines changed Expand file tree Collapse file tree 1 file changed +14
-8
lines changed Original file line number Diff line number Diff line change 1+ # If it's a pull request, don't build the plugin, just fail if it can't be built
2+ # If it's a push to main, build the plugin
3+
14name : plugin-build
25
36on :
47 push :
5- branches : [main]
6-
8+ branches : [ main ]
9+ pull_request :
10+ branches : [ main ]
11+
712 workflow_dispatch :
813
914jobs :
1015 build :
1116 runs-on : ubuntu-latest
12-
17+
1318 permissions :
1419 contents : write
15-
20+
1621 steps :
1722 - uses : actions/checkout@v4
18-
23+
1924 - name : Use Node.js
2025 uses : actions/setup-node@v4
2126 with :
2227 node-version : 18.x
23-
28+
2429 - name : Install dependencies
2530 working-directory : ./resources/js/
2631 run : npm install
27-
32+
2833 - name : Build plugin
2934 working-directory : ./resources/js/
3035 run : npm run plugin:build
31-
36+
3237 - name : Commit changes
38+ if : github.event_name != 'pull_request'
3339 uses : stefanzweifel/git-auto-commit-action@v5
3440 with :
3541 commit_message : Build plugin
You can’t perform that action at this time.
0 commit comments