-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: force checkout with ref input
- Loading branch information
1 parent
59399c7
commit c7e81b1
Showing
1 changed file
with
29 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,8 +37,10 @@ jobs: | |
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
# this allow the workflow to be rerun after changes have been pushed from previous jobs | ||
ref: ${{ github.ref }} | ||
fetch-depth: 0 | ||
|
||
- name: Set modules required | ||
id: modules | ||
run: | | ||
|
@@ -56,35 +58,35 @@ jobs: | |
arrIN=(${in//,/ }) | ||
for i in "${arrIN[@]}"; do | ||
case $i in | ||
fe-piattaforma) | ||
echo "::set-output name=fe-piattaforma::true" | ||
;; | ||
ms-ente) | ||
echo "::set-output name=ms-ente::true" | ||
;; | ||
ms-gestione-utente) | ||
echo "::set-output name=ms-gestione-utente::true" | ||
;; | ||
ms-notifiche-integration) | ||
echo "::set-output name=ms-notifiche-integration::true" | ||
;; | ||
ms-open-data) | ||
echo "::set-output name=ms-open-data::true" | ||
;; | ||
ms-programma-progetto) | ||
echo "::set-output name=ms-programma-progetto::true" | ||
;; | ||
ms-questionario-cittadino) | ||
echo "::set-output name=ms-questionario-cittadino::true" | ||
;; | ||
*) | ||
echo "Unknown $i" | ||
exit 1 | ||
|
@@ -100,7 +102,7 @@ jobs: | |
echo "::set-output name=ms-programma-progetto::true" | ||
echo "::set-output name=ms-questionario-cittadino::true" | ||
fi | ||
DryRunRelease: | ||
needs: CheckInputModules | ||
name: Dry-Run Release | ||
|
@@ -111,6 +113,8 @@ jobs: | |
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
# this allow the workflow to be rerun after changes have been pushed from previous jobs | ||
ref: ${{ github.ref }} | ||
fetch-depth: 0 | ||
|
||
- name: Setup Node.js environment | ||
|
@@ -166,6 +170,8 @@ jobs: | |
steps: | ||
- uses: actions/[email protected] | ||
with: | ||
# this allow the workflow to be rerun after changes have been pushed from previous jobs | ||
ref: ${{ github.ref }} | ||
lfs: 'true' | ||
|
||
- name: Setup Node.js | ||
|
@@ -227,6 +233,8 @@ jobs: | |
steps: | ||
- uses: actions/[email protected] | ||
with: | ||
# this allow the workflow to be rerun after changes have been pushed from previous jobs | ||
ref: ${{ github.ref }} | ||
lfs: 'true' | ||
|
||
- name: Set up JDK 11 | ||
|
@@ -409,13 +417,14 @@ jobs: | |
steps: | ||
- uses: actions/[email protected] | ||
with: | ||
# this allow the workflow to be rerun after changes have been pushed from previous jobs | ||
ref: ${{ github.ref }} | ||
fetch-depth: '0' | ||
|
||
- name: Check Input Version | ||
if: ${{ github.event.inputs.version != '' }} | ||
id: checkver | ||
run: | | ||
set -x | ||
version="${{ github.event.inputs.version }}" | ||
echo "==> Version: $version" | ||
if [ $(git tag -l "$version" | wc -l) -gt 0 ]; then | ||
|
@@ -424,7 +433,6 @@ jobs: | |
echo "Version $version doesn't exist. INVALID INPUT." | ||
exit 1 | ||
fi | ||
set +x | ||
- uses: azure/[email protected] | ||
with: | ||
|
@@ -580,6 +588,8 @@ jobs: | |
- uses: actions/[email protected] | ||
with: | ||
token: ${{ secrets.SEMANTICRELEASE }} | ||
# this allow the workflow to be rerun after changes have been pushed from previous jobs | ||
ref: ${{ github.ref }} | ||
persist-credentials: 'true' | ||
fetch-depth: '0' | ||
|
||
|
@@ -651,15 +661,17 @@ jobs: | |
steps: | ||
- uses: actions/[email protected] | ||
with: | ||
# this allow the workflow to be rerun after changes have been pushed from previous jobs | ||
ref: ${{ github.ref }} | ||
token: ${{ secrets.SEMANTICRELEASE }} | ||
persist-credentials: 'true' | ||
fetch-depth: '0' | ||
|
||
- name: Setup Node.js environment | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 'lts/*' | ||
|
||
- name: Install semantic-release extra plugins | ||
run: | | ||
npm install --save-dev \ | ||
|
@@ -670,18 +682,18 @@ jobs: | |
@semantic-release/release-notes-generator \ | ||
@semantic-release/exec \ | ||
conventional-changelog-conventionalcommits | ||
- name: Create .VERSION file | ||
run: echo "There are no relevant changes, so no new version is released" > .VERSION | ||
|
||
- name: Release | ||
env: | ||
# ad-hoc token (PAT) in order to permit the push on a protected branch | ||
# without protected branches can be use secrets.GITHUB_TOKEN | ||
GITHUB_TOKEN: ${{ secrets.SEMANTICRELEASE }} | ||
run: | | ||
npx semantic-release | ||
- name: Version | ||
id: version | ||
run: | | ||
|