Skip to content

Commit

Permalink
masesgroup#116: updates to remove workflow warning
Browse files Browse the repository at this point in the history
  • Loading branch information
masesdevelopers committed Nov 8, 2022
1 parent d425391 commit af05a16
Show file tree
Hide file tree
Showing 7 changed files with 51 additions and 49 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 2

Expand All @@ -31,25 +31,25 @@ jobs:
echo "=============== list changed files ==============="
git diff --name-only HEAD^ HEAD
echo "::set-output name=run_job::false"
echo "run_job=false" >> $GITHUB_OUTPUT
echo "========== check paths of changed files =========="
git diff --name-only HEAD^ HEAD > files.txt
while IFS= read -r file
do
echo $file
if [[ $file == "netreflected/docs/README.md"* ]]; then
echo "Recreate docs was requested"
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $file == ".github/workflows/docs.yaml"* ]]; then
echo "Recreate docs was requested"
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $file == "netreflected/src/"* ]]; then
echo "This file is under the directory 'netreflected/src/'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
echo "This files are not in a source directory no action required"
Expand All @@ -70,7 +70,7 @@ jobs:
run: git config --system core.longpaths true

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
persist-credentials: false
submodules: 'true'
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/linux.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 2

Expand All @@ -31,25 +31,25 @@ jobs:
echo "=============== list changed files ==============="
git diff --name-only HEAD^ HEAD
echo "::set-output name=run_job::false"
echo "run_job=false" >> $GITHUB_OUTPUT
echo "========== check paths of changed files =========="
git diff --name-only HEAD^ HEAD > files.txt
while IFS= read -r file
do
echo $file
if [[ $file == ".github/workflows/linux.yaml"* ]]; then
echo "This file is under the directory '.github/workflows/linux.yaml'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $file == "netreflected/src/"* ]]; then
echo "This file is under the directory 'netreflected/src'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $file == "netreflected-tests/"* ]]; then
echo "This file is under the directory 'netreflected-tests/'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
echo "This files are not in a source directory no action required"
Expand All @@ -65,7 +65,7 @@ jobs:
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: '1'

Expand Down
17 changes: 9 additions & 8 deletions .github/workflows/maven.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 2

Expand All @@ -31,25 +31,25 @@ jobs:
echo "=============== list changed files ==============="
git diff --name-only HEAD^ HEAD
echo "::set-output name=run_job::false"
echo "run_job=false" >> $GITHUB_OUTPUT
echo "========== check paths of changed files =========="
git diff --name-only HEAD^ HEAD > files.txt
while IFS= read -r file
do
echo $file
if [[ $file == ".github/workflows/maven.yaml"* ]]; then
echo "A change in workflow was made, a run is requested"
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $file == "src/engine/JCOPOMJCOReflector.template"* ]]; then
echo "A change in template was made, a run is requested"
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $file == "netreflected/src/"* ]]; then
echo "This file is under the directory 'netreflected/src/'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
echo "This files are not in a source directory no action required"
Expand All @@ -70,10 +70,10 @@ jobs:
run: git config --system core.longpaths true

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Cache local Maven repository
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
Expand Down Expand Up @@ -104,8 +104,9 @@ jobs:
run: .\bin\net462\MASES.JCOReflectorCLI -JobType CreatePOM -JobFile .github\workflows\createpom_win19.job

- name: Set up Apache Maven Central
uses: actions/setup-java@v1
uses: actions/setup-java@v3
with: # running setup-java again overwrites the settings.xml
distribution: temurin
java-version: 11
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml
server-username: MAVEN_USERNAME # env variable for username in deploy
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/pullrequests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,22 +28,22 @@ jobs:
for added_modified_file in "${added_modified_files[@]}"; do
if [[ $added_modified_file == ".github/workflows/pullrequests.yaml"* ]]; then
echo "$added_modified_file is under the directory '.github/workflows'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $added_modified_file == "netreflected/src/JCOReflector/"* ]]; then
echo "$added_modified_file is under the directory 'netreflected/src/JCOReflector'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $added_modified_file == "src/"* ]]; then
echo "$added_modified_file is under the directory 'src/'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $added_modified_file == "netreflected-tests/"* ]]; then
echo "$added_modified_file is under the directory 'netreflected-tests/'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
done
Expand All @@ -67,15 +67,15 @@ jobs:
run: git config --system core.longpaths true

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: '1'

# Runs a set of commands using the runners shell
- name: Build JCOReflectorCLI
run: dotnet build --no-incremental --configuration Release /p:Platform="Any CPU" src\JCOReflectorCLI.sln

- uses: nuget/setup-nuget@v1
- uses: nuget/setup-nuget@v1.1.1
with:
nuget-version: '5.x'

Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,15 @@ jobs:
run: git config --system core.longpaths true

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
submodules: 'true'

# Runs a set of commands using the runners shell
- name: Build JCOReflectorCLI
run: dotnet build --no-incremental --configuration Release /p:Platform="Any CPU" src\JCOReflectorCLI.sln

- uses: nuget/setup-nuget@v1
- uses: nuget/setup-nuget@v1.1.1
with:
nuget-version: '5.x'

Expand All @@ -51,8 +51,9 @@ jobs:
run: .\bin\net462\MASES.JCOReflectorCLI -JobType CreatePOM -POMStagingType Release -JobFile .github\workflows\createpom_win19.job

- name: Set up Apache Maven Central
uses: actions/setup-java@v1
uses: actions/setup-java@v3
with: # running setup-java again overwrites the settings.xml
distribution: temurin
java-version: 11
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml
server-username: MAVEN_USERNAME # env variable for username in deploy
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/testbranch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,22 +34,22 @@ jobs:
for added_modified_file in "${added_modified_files[@]}"; do
if [[ $added_modified_file == ".github/workflows/testbranch.yaml"* ]]; then
echo "$added_modified_file is under the directory '.github/workflows'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $added_modified_file == "netreflected/src/JCOReflector/"* ]]; then
echo "$added_modified_file is under the directory 'netreflected/src/JCOReflector'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $added_modified_file == "src/"* ]]; then
echo "$added_modified_file is under the directory 'src/'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $added_modified_file == "netreflected-tests/"* ]]; then
echo "$added_modified_file is under the directory 'netreflected-tests/'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
done
Expand All @@ -69,7 +69,7 @@ jobs:
run: git config --system core.longpaths true

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: '1'

Expand All @@ -84,7 +84,7 @@ jobs:
- name: Build JCOReflectorCLI
run: dotnet build --no-incremental --configuration Release /p:Platform="Any CPU" src\JCOReflectorCLI.sln

- uses: nuget/setup-nuget@v1
- uses: nuget/setup-nuget@v1.1.1
with:
nuget-version: '5.x'

Expand Down
28 changes: 14 additions & 14 deletions .github/workflows/windows.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,22 +28,22 @@ jobs:
for added_modified_file in "${added_modified_files[@]}"; do
if [[ $added_modified_file == ".github/workflows/windows.yaml"* ]]; then
echo "$added_modified_file is under the directory '.github/workflows'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $added_modified_file == "netreflected/src/JCOReflector/"* ]]; then
echo "$added_modified_file is under the directory 'netreflected/src/JCOReflector'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $added_modified_file == "src/"* ]]; then
echo "$added_modified_file is under the directory 'src/'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
if [[ $added_modified_file == "netreflected-tests/"* ]]; then
echo "$added_modified_file is under the directory 'netreflected-tests/'."
echo "::set-output name=run_job::true"
echo "run_job=true" >> $GITHUB_OUTPUT
break
fi
done
Expand All @@ -67,7 +67,7 @@ jobs:
run: git config --system core.longpaths true

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: '1'

Expand All @@ -78,7 +78,7 @@ jobs:
- name: Build JCOReflectorCLI
run: dotnet build --no-incremental --configuration Release /p:Platform="Any CPU" src\JCOReflectorCLI.sln

- uses: nuget/setup-nuget@v1
- uses: nuget/setup-nuget@v1.1.1
with:
nuget-version: '5.x'

Expand Down Expand Up @@ -343,7 +343,7 @@ jobs:

- name: Commit statistics changes
if: ${{ github.repository_owner == 'masesgroup'}} #do not push any changes outside main repo
uses: EndBug/add-and-commit@v5
uses: EndBug/add-and-commit@v9
with:
author_name: github-actions
author_email: 41898282+github-actions[bot]@users.noreply.github.com
Expand All @@ -354,7 +354,7 @@ jobs:

- name: Commit report changes
if: ${{ github.repository_owner == 'masesgroup'}} #do not push any changes outside main repo
uses: EndBug/add-and-commit@v5
uses: EndBug/add-and-commit@v9
with:
author_name: github-actions
author_email: 41898282+github-actions[bot]@users.noreply.github.com
Expand All @@ -365,7 +365,7 @@ jobs:

- name: Commit source changes
if: ${{ github.repository_owner == 'masesgroup'}} #do not push any changes outside main repo
uses: EndBug/add-and-commit@v5
uses: EndBug/add-and-commit@v9
with:
author_name: github-actions
author_email: 41898282+github-actions[bot]@users.noreply.github.com
Expand All @@ -376,7 +376,7 @@ jobs:

- name: Commit source changes
if: ${{ github.repository_owner == 'masesgroup'}} #do not push any changes outside main repo
uses: EndBug/add-and-commit@v5
uses: EndBug/add-and-commit@v9
with:
author_name: github-actions
author_email: 41898282+github-actions[bot]@users.noreply.github.com
Expand All @@ -385,22 +385,22 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v3
with:
name: NuGet
path: .\bin\*nupkg

- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v3
with:
name: netcoreapp3.1
path: .\bin\netcoreapp3.1.zip

- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v3
with:
name: net6.0
path: .\bin\net6.0.zip

- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v3
with:
name: net462
path: .\bin\net462.zip

0 comments on commit af05a16

Please sign in to comment.