forked from manoharrmnhr/samplejavaapp
-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (38 loc) · 1 KB
/
demo.yaml
File metadata and controls
38 lines (38 loc) · 1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: demo
on:
- workflow_dispatch # helps to trigger manually on github actions page
- push
jobs:
sampleapp-build:
runs-on: ubuntu-latest
steps:
- name: get code
uses: actions/checkout@v4
# - name: compile
# run: mvn compile
# - name: review
# run: mvn -P metrics pmd:pmd
# - name: test
# run: mvn test
# - name: verify
# run: mvn verify
- name: Configure Maven Settings
run: |
mkdir -p ~/.m2
cat > ~/.m2/settings.xml <<EOF
<settings>
<servers>
<server>
<id>github</id>
<username>\${env.GITHUB_ACTOR}</username>
<password>\${env.GITHUB_TOKEN}</password>
</server>
</servers>
</settings>
EOF
- name: deploy
run: |
mvn deploy
env:
GITHUB_USERNAME: x-access-token
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}