File tree Expand file tree Collapse file tree 1 file changed +21
-1
lines changed Expand file tree Collapse file tree 1 file changed +21
-1
lines changed Original file line number Diff line number Diff line change 1- name : Build and Tests
1+ name : Build, Tests and Deploy to GitHub Pages
22
33on :
44 push :
1111 - ' [0-9]+.[0-9]+.[0-9]+'
1212 pull_request :
1313 types : [ opened, synchronize, reopened ]
14+ workflow_dispatch : # Ajout du déclencheur manuel
1415
1516jobs :
1617 build :
4950 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
5051 SONAR_TOKEN : ${{ secrets.SONAR_TOKEN }}
5152 run : mvn -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
53+
54+ deploy :
55+ name : Deploy to GitHub Pages
56+ # Restrict GitHub Pages deploy only for "main" branch or release
57+ # if: github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/')
58+ runs-on : ubuntu-latest
59+ needs : build
60+ permissions :
61+ pages : write
62+ id-token : write
63+ steps :
64+ - name : Upload artifact for GitHub Pages
65+ 66+ with :
67+ path : target/classes
68+ destination-dir : ${{ github.ref_name }} # Use branch name or tag name as sub-directory
69+
70+ - name : Deploy to GitHub Pages
71+ uses : actions/deploy-pages@v2
You can’t perform that action at this time.
0 commit comments