@@ -35,84 +35,73 @@ jobs:
3535 echo "skip_commit=true" >> "$GITHUB_OUTPUT"
3636 echo "Normal branch - Will NOT commit of generated files"
3737 fi
38- generate :
38+ build :
3939 runs-on : ubuntu-latest
4040 needs : check
4141 if : needs.check.outputs.skip_job != 'true'
4242 steps :
43- - name : debug
44- run : |
45- echo ${{ needs.check.outputs.skip_job }}
46- echo ${{ needs.check.outputs.skip_commit }}
4743 - name : Checkout code
4844 uses : actions/checkout@v4
4945 with :
5046 fetch-depth : 0
5147 ssh-key : ${{ secrets.DEPLOY_KEY }}
5248 path : main
49+
5350 - name : Checkout BrAPI repo to temp directory
5451 uses : actions/checkout@v4
5552 with :
5653 repository : plantbreeding/BrAPI
5754 path : BrAPI
55+
5856 - name : Set up JDK 21
5957 uses : actions/setup-java@v4
6058 with :
6159 distribution : ' temurin'
6260 java-version : ' 21'
61+
6362 - name : Change wrapper permissions
6463 working-directory : ./main/generator
6564 run : chmod +x ./gradlew
65+
6666 - name : Generate R Code
6767 working-directory : ./main/generator
6868 run : ./gradlew generateR
69+
6970 - name : Set up R
7071 uses : r-lib/actions/setup-r@v2
72+
7173 - name : Install devtools
7274 working-directory : main/pkg
7375 run : Rscript -e "install.packages('devtools')"
76+
7477 - name : Document R package
7578 working-directory : main/pkg
7679 run : Rscript -e "devtools::document()"
77- - if : needs.check.outputs.skip_commit == 'false'
78- uses : stefanzweifel/git-auto-commit-action@v5
79- with :
80- repository : main
81- commit_message : Apply automatic changes
82- file_pattern : main/**
83- pkgdown :
84- runs-on : ubuntu-latest
85- needs : generate
86- concurrency :
87- group : pkgdown-${{ github.event_name != 'pull_request' || github.run_id }}
88- env :
89- GITHUB_PAT : ${{ secrets.GITHUB_TOKEN }}
90- permissions :
91- contents : write
92- steps :
93- - uses : actions/checkout@v4
9480
9581 - uses : r-lib/actions/setup-pandoc@v2
9682
97- - uses : r-lib/actions/setup-r@v2
98- with :
99- use-public-rspm : true
100-
10183 - uses : r-lib/actions/setup-r-dependencies@v2
10284 with :
10385 extra-packages : any::pkgdown, local::.
10486 needs : website
105- working-directory : pkg
87+ working-directory : main/ pkg
10688
10789 - name : Build site
10890 run : pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE)
10991 shell : Rscript {0}
110- working-directory : pkg
111-
92+ working-directory : main/pkg
93+ - if : needs.check.outputs.skip_commit == 'false'
94+ uses : stefanzweifel/git-auto-commit-action@v5
95+ with :
96+ repository : main
97+ commit_message : Apply automatic changes
98+ file_pattern : main/**
11299 - name : Deploy to GitHub pages 🚀
113100 if : github.event_name != 'pull_request'
114101 uses : JamesIves/github-pages-deploy-action@v4.5.0
115102 with :
116103 clean : false
117104 branch : gh-pages
118105 folder : pkg/docs
106+
107+
0 commit comments