11name : Build, test, deploy documentation
2- env :
3- BUILD_DIR : ${{github.workspace}}
4- JOB_NUMBER : ${{github.run_number}}
52
63on :
74 push :
129 workflow_dispatch :
1310
1411concurrency : ${{github.ref}}
15-
1612defaults :
1713 run :
1814 shell : bash
@@ -21,13 +17,12 @@ jobs:
2117
2218 build-and-test :
2319 name : Build and test on ${{matrix.db_version_name}} DB
20+ runs-on : ubuntu-latest
2421 env :
2522 ORACLE_VERSION : ${{matrix.oracle-version}}
2623 CONNECTION_STR : ${{matrix.connection-str}}
2724 ORACLE_PASSWORD : oracle
2825 DOCKER_VOLUME : ${{matrix.docker-volume}}
29-
30- runs-on : ubuntu-latest
3126 strategy :
3227 fail-fast : false
3328 matrix :
6762 image : ${{matrix.oracle-version}}
6863 env :
6964 ORACLE_PASSWORD : oracle
70- # credentials:
71- # username: ${{ secrets.DOCKER_USER }}
72- # password: ${{ secrets.DOCKER_PASSWORD }}
65+ MATRIX_JOB_ID : ${{matrix.id}}
66+ credentials :
67+ username : ${{ secrets.DOCKER_USER }}
68+ password : ${{ secrets.DOCKER_PASSWORD }}
7369 ports :
7470 - 1521:1521
7571 options : >-
@@ -82,11 +78,37 @@ jobs:
8278 - uses : actions/checkout@v2
8379 with :
8480 fetch-depth : 0
85- - uses : nelonoel/branch-name@v1.0.1
8681 - uses : c-py/action-dotenv-to-setenv@v2
8782 with :
8883 env-file : .github/variables/.env
89-
84+ - uses : FranzDiebold/github-env-vars-action@v2 # https://github.com/marketplace/actions/github-environment-variables-action
85+
86+ - name : Print environment variables
87+ run : |
88+ echo "CI_REPOSITORY_SLUG=$CI_REPOSITORY_SLUG"
89+ echo "CI_REPOSITORY_OWNER=$CI_REPOSITORY_OWNER"
90+ echo "CI_REPOSITORY_OWNER_SLUG=$CI_REPOSITORY_OWNER_SLUG"
91+ echo "CI_REPOSITORY_NAME=$CI_REPOSITORY_NAME"
92+ echo "CI_REPOSITORY_NAME_SLUG=$CI_REPOSITORY_NAME_SLUG"
93+ echo "CI_REPOSITORY=$CI_REPOSITORY"
94+ echo "CI_REF_SLUG=$CI_REF_SLUG"
95+ echo "CI_ACTION_REF_NAME=$CI_ACTION_REF_NAME"
96+ echo "CI_ACTION_REF_NAME_SLUG=$CI_ACTION_REF_NAME_SLUG"
97+ echo "CI_REF_NAME=$CI_REF_NAME"
98+ echo "CI_REF_NAME_SLUG=$CI_REF_NAME_SLUG"
99+ echo "CI_REF=$CI_REF"
100+ echo "CI_HEAD_REF_SLUG=$CI_HEAD_REF_SLUG"
101+ echo "CI_HEAD_REF=$CI_HEAD_REF"
102+ echo "CI_BASE_REF_SLUG=$CI_BASE_REF_SLUG"
103+ echo "CI_BASE_REF=$CI_BASE_REF"
104+ echo "CI_SHA_SHORT=$CI_SHA_SHORT"
105+ echo "CI_SHA=$CI_SHA"
106+ echo "CI_ACTOR=$CI_ACTOR"
107+ echo "CI_EVENT_NAME=$CI_EVENT_NAME"
108+ echo "CI_RUN_ID=$CI_RUN_ID"
109+ echo "CI_RUN_NUMBER=$CI_RUN_NUMBER"
110+ echo "CI_WORKFLOW=$CI_WORKFLOW"
111+ echo "CI_ACTION=$CI_ACTION"
90112
91113 - name : Set build version number env variables
92114 id : set-build-version-number-vars
@@ -147,19 +169,19 @@ jobs:
147169 concurrency : publish
148170 runs-on : ubuntu-latest
149171 if : |
150- ${{ github.repository == 'utPLSQL/utPLSQL' && github.base_ref == null
151- && ( startsWith( github.ref, 'refs/heads/release/v' ) || github.ref == 'refs/heads/develop' )
152- }}
172+ github.repository == 'utPLSQL/utPLSQL' &&
173+ github.base_ref == null &&
174+ ( startsWith( github.ref, 'refs/heads/release/v' ) ||
175+ github.ref == 'refs/heads/develop' )
153176
154177 steps :
155178 - uses : actions/checkout@v2
156179 with :
157180 fetch-depth : 0
158- # Populates the value of BRANCH_NAME env variable
159- - uses : nelonoel/branch-name@v1.0.1
160181 - uses : c-py/action-dotenv-to-setenv@v2
161182 with :
162183 env-file : .github/variables/.env
184+ - uses : FranzDiebold/github-env-vars-action@v2 # https://github.com/marketplace/actions/github-environment-variables-action
163185
164186 - name : Set buid version number env variables
165187 id : set-build-version-number-vars
@@ -171,7 +193,10 @@ jobs:
171193
172194 - name : Push version update to repository
173195 id : push-version-number-update
174- run : .travis/push_project_version.sh
196+ run : |
197+ git add sonar-project.properties VERSION source/* docs/*
198+ git commit -m 'Updated project version after build [skip ci]'
199+ git push --quiet origin HEAD:${CI_ACTION_REF_NAME}
175200
176201 - name : Copy and push documentation to utPLSQL-github-io repo
177202 id : push-documentation
0 commit comments