From 68c5844edbb309214fa598b16a623bbf383e48b5 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 9 Apr 2023 11:48:12 +0300 Subject: [PATCH 01/71] Migrate to github actions --- .github/workflows/ci-cd.yml | 22 ++++++++++++++++++++++ OData.QueryBuilder.sln | 9 +++++++++ 2 files changed, 31 insertions(+) create mode 100644 .github/workflows/ci-cd.yml diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml new file mode 100644 index 00000000..68fcab16 --- /dev/null +++ b/.github/workflows/ci-cd.yml @@ -0,0 +1,22 @@ +name: OData.QueryBuilder +on: [push] + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + dotnet-version: [ '3.1.x' ] + + steps: + - uses: actions/checkout@v3 + - name: Setup .NET Core SDK ${{ matrix.dotnet-version }} + uses: actions/setup-dotnet@v3 + with: + dotnet-version: ${{ matrix.dotnet-version }} + - name: Install dependencies + run: dotnet restore + - name: Build + run: dotnet build --configuration Release --no-restore + - name: Test + run: dotnet test --no-restore diff --git a/OData.QueryBuilder.sln b/OData.QueryBuilder.sln index 308a2b38..98f3e98d 100644 --- a/OData.QueryBuilder.sln +++ b/OData.QueryBuilder.sln @@ -27,6 +27,13 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OData.QueryBuilder.Benchmar EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OData.QueryBuilder.Fakes", "test\OData.QueryBuilder.Fakes\OData.QueryBuilder.Fakes.csproj", "{421FF96A-2F4E-4589-AF2A-604FDC8BE2AC}" EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "github", "github", "{C1D8FFE9-07E2-4EA7-AF59-C5A68F7DB89C}" +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "workflows", "workflows", "{D95B88FB-7257-421E-8AA3-BD85C63ECBE6}" + ProjectSection(SolutionItems) = preProject + .github\workflows\ci-cd.yml = .github\workflows\ci-cd.yml + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -59,6 +66,8 @@ Global {B8F31CF9-EDE2-4813-A9AC-EBF3514FFE82} = {179F88B9-A06D-4505-9266-A5D66004601C} {3C66CF4E-8FA0-4E81-90DB-B22234A2670C} = {26982440-340F-48A2-9D73-44DB6C52EBF1} {421FF96A-2F4E-4589-AF2A-604FDC8BE2AC} = {26982440-340F-48A2-9D73-44DB6C52EBF1} + {C1D8FFE9-07E2-4EA7-AF59-C5A68F7DB89C} = {179F88B9-A06D-4505-9266-A5D66004601C} + {D95B88FB-7257-421E-8AA3-BD85C63ECBE6} = {C1D8FFE9-07E2-4EA7-AF59-C5A68F7DB89C} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {1D51B9A3-94B0-48DF-BFF5-110B13303535} From 4a8121a16837fe20be7e278d4576b2f100a40201 Mon Sep 17 00:00:00 2001 From: Borisov Zakhar Date: Sun, 9 Apr 2023 12:29:34 +0300 Subject: [PATCH 02/71] fix --- .github/workflows/ci-cd.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 68fcab16..4cfa8b52 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -1,19 +1,21 @@ name: OData.QueryBuilder on: [push] - +env: + DOTNET_VERSION: '3.1.x' jobs: - build: - runs-on: ubuntu-latest + build-and-test: + name: build-and-test-${{matrix.os}} + runs-on: ${{ matrix.os }} strategy: matrix: - dotnet-version: [ '3.1.x' ] - + os: [ubuntu-latest, windows-latest, macOS-latest] steps: + - name: Checkout - uses: actions/checkout@v3 - - name: Setup .NET Core SDK ${{ matrix.dotnet-version }} + - name: Setup .NET SDK ${{ matrix.dotnet-version }} uses: actions/setup-dotnet@v3 with: - dotnet-version: ${{ matrix.dotnet-version }} + dotnet-version: ${{ env.DOTNET_VERSION }} - name: Install dependencies run: dotnet restore - name: Build From 2b3bf18ed763cdf13847f217a1586af60eb16ad0 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 9 Apr 2023 12:30:42 +0300 Subject: [PATCH 03/71] fix 1 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 4cfa8b52..4997bc53 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -11,7 +11,7 @@ jobs: os: [ubuntu-latest, windows-latest, macOS-latest] steps: - name: Checkout - - uses: actions/checkout@v3 + uses: actions/checkout@v3 - name: Setup .NET SDK ${{ matrix.dotnet-version }} uses: actions/setup-dotnet@v3 with: From 6fd58eb960b8a0b4fc186f777c644ddb3a689e5f Mon Sep 17 00:00:00 2001 From: Borisov Zakhar Date: Sun, 9 Apr 2023 13:24:35 +0300 Subject: [PATCH 04/71] Update ci-cd.yml --- .github/workflows/ci-cd.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 4997bc53..675edbad 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -12,6 +12,8 @@ jobs: steps: - name: Checkout uses: actions/checkout@v3 + with: + token: ${{ secrets.GRT }} - name: Setup .NET SDK ${{ matrix.dotnet-version }} uses: actions/setup-dotnet@v3 with: From a9d651f9b681f1f4d94d7f8fd2f459838c193dfc Mon Sep 17 00:00:00 2001 From: Borisov Zakhar Date: Sun, 9 Apr 2023 13:38:09 +0300 Subject: [PATCH 05/71] Update ci-cd.yml --- .github/workflows/ci-cd.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 675edbad..ec4bfe42 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -13,7 +13,7 @@ jobs: - name: Checkout uses: actions/checkout@v3 with: - token: ${{ secrets.GRT }} + token: ${{ env.GRT }} - name: Setup .NET SDK ${{ matrix.dotnet-version }} uses: actions/setup-dotnet@v3 with: @@ -21,6 +21,6 @@ jobs: - name: Install dependencies run: dotnet restore - name: Build - run: dotnet build --configuration Release --no-restore + run: dotnet build --configuration ${{ env.CONFIGURATION }} --no-restore - name: Test run: dotnet test --no-restore From 50794d0d691084105c8ea7063166bd1e2cbf8c4a Mon Sep 17 00:00:00 2001 From: Borisov Zakhar Date: Sun, 9 Apr 2023 13:39:29 +0300 Subject: [PATCH 06/71] Update ci-cd.yml --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index ec4bfe42..a9794e29 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -13,7 +13,7 @@ jobs: - name: Checkout uses: actions/checkout@v3 with: - token: ${{ env.GRT }} + token: ${{ secrets.GRT }} - name: Setup .NET SDK ${{ matrix.dotnet-version }} uses: actions/setup-dotnet@v3 with: From b067910c6b471b551c2325455bdd727424bffddb Mon Sep 17 00:00:00 2001 From: Borisov Zakhar Date: Sun, 9 Apr 2023 13:43:21 +0300 Subject: [PATCH 07/71] Update ci-cd.yml --- .github/workflows/ci-cd.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index a9794e29..8e9b8a46 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -12,8 +12,6 @@ jobs: steps: - name: Checkout uses: actions/checkout@v3 - with: - token: ${{ secrets.GRT }} - name: Setup .NET SDK ${{ matrix.dotnet-version }} uses: actions/setup-dotnet@v3 with: From 6c59bb529d01678d0e86f0bcdcf9e83f6dcfaf7e Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 9 Apr 2023 13:47:02 +0300 Subject: [PATCH 08/71] test --- .github/workflows/ci-cd.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 8e9b8a46..8a1ae0b4 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -1,5 +1,6 @@ name: OData.QueryBuilder on: [push] + env: DOTNET_VERSION: '3.1.x' jobs: From 0426fb1fb674613ff86c1876b603eccfdbef075e Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 9 Apr 2023 14:10:33 +0300 Subject: [PATCH 09/71] test 1 --- .github/workflows/ci-cd.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 8a1ae0b4..3223705d 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -4,7 +4,7 @@ on: [push] env: DOTNET_VERSION: '3.1.x' jobs: - build-and-test: + ci-cd: name: build-and-test-${{matrix.os}} runs-on: ${{ matrix.os }} strategy: @@ -20,6 +20,6 @@ jobs: - name: Install dependencies run: dotnet restore - name: Build - run: dotnet build --configuration ${{ env.CONFIGURATION }} --no-restore + run: dotnet build --configuration ${{ vars.CONFIGURATION }} --no-restore - name: Test run: dotnet test --no-restore From dde87f5ff2b8f6717738ada9bdf7a0f5b3a1d008 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 9 Apr 2023 14:28:45 +0300 Subject: [PATCH 10/71] test 2 --- .github/workflows/ci-cd.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 3223705d..c3348dfb 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -4,6 +4,7 @@ on: [push] env: DOTNET_VERSION: '3.1.x' jobs: + environment: ci-cd ci-cd: name: build-and-test-${{matrix.os}} runs-on: ${{ matrix.os }} From 0b4837435c06f60f5e3071e053f2b5a184c1aac9 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 9 Apr 2023 14:29:46 +0300 Subject: [PATCH 11/71] fix --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index c3348dfb..1d3beb83 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -4,10 +4,10 @@ on: [push] env: DOTNET_VERSION: '3.1.x' jobs: - environment: ci-cd ci-cd: name: build-and-test-${{matrix.os}} runs-on: ${{ matrix.os }} + environment: ci-cd strategy: matrix: os: [ubuntu-latest, windows-latest, macOS-latest] From 8de2889dc8bdc3f9a6de6393657597a3e6430e40 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 9 Apr 2023 23:52:30 +0300 Subject: [PATCH 12/71] remove travis --- .github/workflows/ci-cd.yml | 14 +++++++++--- .travis.yml | 44 ------------------------------------- OData.QueryBuilder.sln | 1 - 3 files changed, 11 insertions(+), 48 deletions(-) delete mode 100644 .travis.yml diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 1d3beb83..8ac4dc70 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -18,9 +18,17 @@ jobs: uses: actions/setup-dotnet@v3 with: dotnet-version: ${{ env.DOTNET_VERSION }} - - name: Install dependencies + - name: Restore run: dotnet restore - name: Build - run: dotnet build --configuration ${{ vars.CONFIGURATION }} --no-restore + run: dotnet build --c ${{ vars.CONFIGURATION }} --no-restore - name: Test - run: dotnet test --no-restore + run: dotnet test -c $CONFIGURATION + - name: Coveralls + run: | + dotnet minicover instrument + dotnet minicover reset + dotnet test -c ${{ vars.CONFIGURATION }} --no-build + dotnet minicover uninstrument + dotnet minicover report + dotnet minicover coverallsreport --service-name "github-actions" --service-job-id $GITHUB_ACTION \ No newline at end of file diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index a8bbf9fa..00000000 --- a/.travis.yml +++ /dev/null @@ -1,44 +0,0 @@ -language: csharp -dotnet: 3.1 -mono: none -solution: OData.QueryBuilder.sln -branches: - only: - - main -before_script: - - dotnet restore -script: - - dotnet build - - dotnet test ./test/OData.QueryBuilder.Test -c $CONFIGURATION -f netcoreapp3.1 -after_success: - - dotnet minicover instrument - - dotnet minicover reset - - dotnet test --no-build ./test/OData.QueryBuilder.Test -c $CONFIGURATION -f netcoreapp3.1 - - dotnet minicover uninstrument - - dotnet minicover report - - dotnet minicover coverallsreport --service-name "travis-ci" --service-job-id $TRAVIS_JOB_ID -before_deploy: - - git checkout origin/main && git fetch && git remote set-url origin https://${GITHUB_OAUTH_TOKEN}@github.com/ZEXSM/OData.QueryBuilder.git - - PR_TITLE=$(git log -1 --pretty='%f') - - LAST_TAG=$(echo $(git describe --tags $(git rev-list --tags --max-count=1)) | cut -d'v' -f 2) - - CURRENT_MAJOR=$(echo $LAST_TAG | cut -d. -f 1) - - CURRENT_MINOR=$(echo $LAST_TAG | cut -d. -f 2) - - CURRENT_PATCH=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 1) - - RC=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 2) - - MAJOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MAJOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo $(($CURRENT_MAJOR+1))) || echo $CURRENT_MAJOR) - - MINOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MINOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo $(($CURRENT_MINOR+1))) || echo $CURRENT_MINOR) - - PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) - - NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) - - PACKAGE_VERSION=${NEW_TAG:-$DEFAULT_PACKAGE_VERSION} - - git tag v$PACKAGE_VERSION && git push origin v$PACKAGE_VERSION - - dotnet pack -c $CONFIGURATION -p:PackageVersion=$PACKAGE_VERSION -deploy: - provider: releases - name: v$PACKAGE_VERSION - token: $GITHUB_OAUTH_TOKEN - cleanup: true - repo: ZEXSM/OData.QueryBuilder - on: - branch: main -after_deploy: - - dotnet nuget push ./src/OData.QueryBuilder/bin/Release/OData.QueryBuilder.$PACKAGE_VERSION.nupkg -k $NUGET_API_KEY -s $NUGET_SOURCE \ No newline at end of file diff --git a/OData.QueryBuilder.sln b/OData.QueryBuilder.sln index 98f3e98d..61cab4c1 100644 --- a/OData.QueryBuilder.sln +++ b/OData.QueryBuilder.sln @@ -14,7 +14,6 @@ EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "items", "items", "{179F88B9-A06D-4505-9266-A5D66004601C}" ProjectSection(SolutionItems) = preProject .gitignore = .gitignore - .travis.yml = .travis.yml README.md = README.md EndProjectSection EndProject From 5b1c4f6cf9821a0c0687c30b8b9dadd56da6bc94 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 9 Apr 2023 23:54:05 +0300 Subject: [PATCH 13/71] fix --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 8ac4dc70..0f505c43 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -21,7 +21,7 @@ jobs: - name: Restore run: dotnet restore - name: Build - run: dotnet build --c ${{ vars.CONFIGURATION }} --no-restore + run: dotnet build -c ${{ vars.CONFIGURATION }} --no-restore - name: Test run: dotnet test -c $CONFIGURATION - name: Coveralls From d9d064af8dc11e3b879b6ec855a60428a328a6f6 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 9 Apr 2023 23:56:01 +0300 Subject: [PATCH 14/71] fix test --- .github/workflows/ci-cd.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 0f505c43..98ea18fd 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -10,7 +10,8 @@ jobs: environment: ci-cd strategy: matrix: - os: [ubuntu-latest, windows-latest, macOS-latest] + # os: [ubuntu-latest, windows-latest, macOS-latest] + os: [ubuntu-latest] steps: - name: Checkout uses: actions/checkout@v3 @@ -23,7 +24,7 @@ jobs: - name: Build run: dotnet build -c ${{ vars.CONFIGURATION }} --no-restore - name: Test - run: dotnet test -c $CONFIGURATION + run: dotnet test -c ${{ vars.CONFIGURATION }} - name: Coveralls run: | dotnet minicover instrument From a61dcae6cd1b0299da79d3d755ef0652adafd0fb Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Mon, 10 Apr 2023 00:02:45 +0300 Subject: [PATCH 15/71] fix --- .github/workflows/ci-cd.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 98ea18fd..663629fa 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -24,7 +24,7 @@ jobs: - name: Build run: dotnet build -c ${{ vars.CONFIGURATION }} --no-restore - name: Test - run: dotnet test -c ${{ vars.CONFIGURATION }} + run: dotnet test -c ${{ vars.CONFIGURATION }} --no-build - name: Coveralls run: | dotnet minicover instrument @@ -32,4 +32,4 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - dotnet minicover coverallsreport --service-name "github-actions" --service-job-id $GITHUB_ACTION \ No newline at end of file + dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ env.GITHUB_ACTION }} \ No newline at end of file From 45af32891eeaabfd1239728c8eaa742053a5b482 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Mon, 10 Apr 2023 00:05:36 +0300 Subject: [PATCH 16/71] GITHUB_ACTION --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 663629fa..b3133294 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -32,4 +32,4 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ env.GITHUB_ACTION }} \ No newline at end of file + dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} \ No newline at end of file From 8edb0da4c0104735113b406d91beaa2aa3c7ab81 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Mon, 10 Apr 2023 00:11:32 +0300 Subject: [PATCH 17/71] test --- .github/workflows/ci-cd.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index b3133294..eac57b3a 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -32,4 +32,5 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} \ No newline at end of file + # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} + echo ${{ vars.GITHUB_ACTION }} \ No newline at end of file From c26c4f908770c7bfafa4ee71b9cca24816982031 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Mon, 10 Apr 2023 19:16:07 +0300 Subject: [PATCH 18/71] pack test 1 --- .github/workflows/ci-cd.yml | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index eac57b3a..24bbdb19 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -33,4 +33,19 @@ jobs: dotnet minicover uninstrument dotnet minicover report # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} - echo ${{ vars.GITHUB_ACTION }} \ No newline at end of file + - name: Pack + run: | + PR_TITLE=$(git log -1 --pretty='%f') + LAST_TAG=$(echo $(git describe --tags $(git rev-list --tags --max-count=1)) | cut -d'v' -f 2) + CURRENT_MAJOR=$(echo $LAST_TAG | cut -d. -f 1) + CURRENT_MINOR=$(echo $LAST_TAG | cut -d. -f 2) + CURRENT_PATCH=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 1) + RC=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 2) + MAJOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MAJOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo $(($CURRENT_MAJOR+1))) || echo $CURRENT_MAJOR) + MINOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MINOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo $(($CURRENT_MINOR+1))) || echo $CURRENT_MINOR) + PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) + NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) + PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} + echo v$PACKAGE_VERSION + #git tag v$PACKAGE_VERSION && git push origin v$PACKAGE_VERSION + #dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=$PACKAGE_VERSION \ No newline at end of file From 68a88ff2162fdda28e24cbba968e093a98e3fc93 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Mon, 10 Apr 2023 20:35:12 +0300 Subject: [PATCH 19/71] test create tag --- .github/workflows/ci-cd.yml | 46 ++++++++++++++++++++++--------------- 1 file changed, 28 insertions(+), 18 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 24bbdb19..1089eaef 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -15,23 +15,23 @@ jobs: steps: - name: Checkout uses: actions/checkout@v3 - - name: Setup .NET SDK ${{ matrix.dotnet-version }} - uses: actions/setup-dotnet@v3 - with: - dotnet-version: ${{ env.DOTNET_VERSION }} - - name: Restore - run: dotnet restore - - name: Build - run: dotnet build -c ${{ vars.CONFIGURATION }} --no-restore - - name: Test - run: dotnet test -c ${{ vars.CONFIGURATION }} --no-build - - name: Coveralls - run: | - dotnet minicover instrument - dotnet minicover reset - dotnet test -c ${{ vars.CONFIGURATION }} --no-build - dotnet minicover uninstrument - dotnet minicover report + #- name: Setup .NET SDK ${{ matrix.dotnet-version }} + # uses: actions/setup-dotnet@v3 + # with: + # dotnet-version: ${{ env.DOTNET_VERSION }} + #- name: Restore + # run: dotnet restore + #- name: Build + # run: dotnet build -c ${{ vars.CONFIGURATION }} --no-restore + #- name: Test + # run: dotnet test -c ${{ vars.CONFIGURATION }} --no-build + #- name: Coveralls + # run: | + # dotnet minicover instrument + # dotnet minicover reset + # dotnet test -c ${{ vars.CONFIGURATION }} --no-build + # dotnet minicover uninstrument + # dotnet minicover report # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} - name: Pack run: | @@ -46,6 +46,16 @@ jobs: PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} - echo v$PACKAGE_VERSION + echo $PR_TITLE + echo $LAST_TAG + echo $CURRENT_MAJOR + echo $CURRENT_MINOR + echo $CURRENT_PATCH + echo $RC + echo $MAJOR + echo $MINOR + echo $PATCH + echo $NEW_TAG + echo $PACKAGE_VERSION #git tag v$PACKAGE_VERSION && git push origin v$PACKAGE_VERSION #dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=$PACKAGE_VERSION \ No newline at end of file From 27b2a2ecdc1d0cf9a41bcd87c67eb0ef4d15070a Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Mon, 10 Apr 2023 20:51:50 +0300 Subject: [PATCH 20/71] test --- .github/workflows/ci-cd.yml | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 1089eaef..fc716125 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -33,19 +33,22 @@ jobs: # dotnet minicover uninstrument # dotnet minicover report # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} + - name: Refresh tags + id: tag + run: git fetch --tags --force - name: Pack run: | PR_TITLE=$(git log -1 --pretty='%f') LAST_TAG=$(echo $(git describe --tags $(git rev-list --tags --max-count=1)) | cut -d'v' -f 2) - CURRENT_MAJOR=$(echo $LAST_TAG | cut -d. -f 1) - CURRENT_MINOR=$(echo $LAST_TAG | cut -d. -f 2) - CURRENT_PATCH=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 1) - RC=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 2) - MAJOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MAJOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo $(($CURRENT_MAJOR+1))) || echo $CURRENT_MAJOR) - MINOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MINOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo $(($CURRENT_MINOR+1))) || echo $CURRENT_MINOR) - PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) - NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) - PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} + #CURRENT_MAJOR=$(echo $LAST_TAG | cut -d. -f 1) + #CURRENT_MINOR=$(echo $LAST_TAG | cut -d. -f 2) + #CURRENT_PATCH=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 1) + #RC=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 2) + #MAJOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MAJOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo $(($CURRENT_MAJOR+1))) || echo $CURRENT_MAJOR) + #MINOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MINOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo $(($CURRENT_MINOR+1))) || echo $CURRENT_MINOR) + #PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) + #NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) + #PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} echo $PR_TITLE echo $LAST_TAG echo $CURRENT_MAJOR From 2b8b9f7c7c4acc5eaf158f6f2be00b30708584b9 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Mon, 10 Apr 2023 20:53:11 +0300 Subject: [PATCH 21/71] test 1 --- .github/workflows/ci-cd.yml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index fc716125..6e0569ae 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -40,15 +40,15 @@ jobs: run: | PR_TITLE=$(git log -1 --pretty='%f') LAST_TAG=$(echo $(git describe --tags $(git rev-list --tags --max-count=1)) | cut -d'v' -f 2) - #CURRENT_MAJOR=$(echo $LAST_TAG | cut -d. -f 1) - #CURRENT_MINOR=$(echo $LAST_TAG | cut -d. -f 2) - #CURRENT_PATCH=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 1) - #RC=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 2) - #MAJOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MAJOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo $(($CURRENT_MAJOR+1))) || echo $CURRENT_MAJOR) - #MINOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MINOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo $(($CURRENT_MINOR+1))) || echo $CURRENT_MINOR) - #PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) - #NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) - #PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} + CURRENT_MAJOR=$(echo $LAST_TAG | cut -d. -f 1) + CURRENT_MINOR=$(echo $LAST_TAG | cut -d. -f 2) + CURRENT_PATCH=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 1) + RC=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 2) + MAJOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MAJOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo $(($CURRENT_MAJOR+1))) || echo $CURRENT_MAJOR) + MINOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MINOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo $(($CURRENT_MINOR+1))) || echo $CURRENT_MINOR) + PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) + NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) + PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} echo $PR_TITLE echo $LAST_TAG echo $CURRENT_MAJOR From b4152ad617779558423729dd29ebc2e106824573 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Tue, 11 Apr 2023 10:09:54 +0300 Subject: [PATCH 22/71] tests release --- .github/workflows/ci-cd.yml | 26 +++++++++++--------------- 1 file changed, 11 insertions(+), 15 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 6e0569ae..101c5f09 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -33,11 +33,9 @@ jobs: # dotnet minicover uninstrument # dotnet minicover report # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} - - name: Refresh tags - id: tag - run: git fetch --tags --force - - name: Pack + - name: Before deploy run: | + git fetch --tags --force PR_TITLE=$(git log -1 --pretty='%f') LAST_TAG=$(echo $(git describe --tags $(git rev-list --tags --max-count=1)) | cut -d'v' -f 2) CURRENT_MAJOR=$(echo $LAST_TAG | cut -d. -f 1) @@ -49,16 +47,14 @@ jobs: PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} - echo $PR_TITLE - echo $LAST_TAG - echo $CURRENT_MAJOR - echo $CURRENT_MINOR - echo $CURRENT_PATCH - echo $RC - echo $MAJOR - echo $MINOR - echo $PATCH - echo $NEW_TAG echo $PACKAGE_VERSION #git tag v$PACKAGE_VERSION && git push origin v$PACKAGE_VERSION - #dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=$PACKAGE_VERSION \ No newline at end of file + #dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=$PACKAGE_VERSION + - name: Deploy + uses: actions/create-release@v1 + with: + tag_name: ${{ github.ref }} + release_name: Release ${{ github.ref }} + body: $PR_TITLE + draft: true + prerelease: false \ No newline at end of file From cb382e58f5fbf285bbb2f35c5d9e47f34b0c013b Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Tue, 11 Apr 2023 10:11:25 +0300 Subject: [PATCH 23/71] test release 1 --- .github/workflows/ci-cd.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 101c5f09..9b538acf 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -52,6 +52,8 @@ jobs: #dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=$PACKAGE_VERSION - name: Deploy uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: tag_name: ${{ github.ref }} release_name: Release ${{ github.ref }} From 065ecb87c7bda5dcdeaee5509142c37e26e51750 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Tue, 11 Apr 2023 13:47:34 +0300 Subject: [PATCH 24/71] test release 2 --- .github/workflows/ci-cd.yml | 63 +++++++++++++++++-------------------- 1 file changed, 29 insertions(+), 34 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 9b538acf..146c44f4 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -1,6 +1,5 @@ name: OData.QueryBuilder -on: [push] - +on: push env: DOTNET_VERSION: '3.1.x' jobs: @@ -10,30 +9,31 @@ jobs: environment: ci-cd strategy: matrix: - # os: [ubuntu-latest, windows-latest, macOS-latest] + #os: [ubuntu-latest, windows-latest, macOS-latest] os: [ubuntu-latest] steps: - name: Checkout uses: actions/checkout@v3 - #- name: Setup .NET SDK ${{ matrix.dotnet-version }} - # uses: actions/setup-dotnet@v3 - # with: - # dotnet-version: ${{ env.DOTNET_VERSION }} - #- name: Restore - # run: dotnet restore - #- name: Build - # run: dotnet build -c ${{ vars.CONFIGURATION }} --no-restore - #- name: Test - # run: dotnet test -c ${{ vars.CONFIGURATION }} --no-build - #- name: Coveralls - # run: | - # dotnet minicover instrument - # dotnet minicover reset - # dotnet test -c ${{ vars.CONFIGURATION }} --no-build - # dotnet minicover uninstrument - # dotnet minicover report + - name: Setup .NET SDK ${{ matrix.dotnet-version }} + uses: actions/setup-dotnet@v3 + with: + dotnet-version: ${{ env.DOTNET_VERSION }} + - name: Restore + run: dotnet restore + - name: Build + run: dotnet build -c ${{ vars.CONFIGURATION }} --no-restore + - name: Test + run: dotnet test -c ${{ vars.CONFIGURATION }} --no-build + - name: Coveralls + run: | + dotnet minicover instrument + dotnet minicover reset + dotnet test -c ${{ vars.CONFIGURATION }} --no-build + dotnet minicover uninstrument + dotnet minicover report # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} - - name: Before deploy + - name: Create tag + id: create_tag run: | git fetch --tags --force PR_TITLE=$(git log -1 --pretty='%f') @@ -47,16 +47,11 @@ jobs: PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} - echo $PACKAGE_VERSION - #git tag v$PACKAGE_VERSION && git push origin v$PACKAGE_VERSION - #dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=$PACKAGE_VERSION - - name: Deploy - uses: actions/create-release@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - tag_name: ${{ github.ref }} - release_name: Release ${{ github.ref }} - body: $PR_TITLE - draft: true - prerelease: false \ No newline at end of file + echo "release_version=$PACKAGE_VERSION" >> "$GITHUB_OUTPUT" + - name: Pack + run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_version }} + #- name: Release + # run: | + # git tag v${{ steps.create_tag.outputs.release_version }} + # git push origin v${{ steps.create_tag.outputs.release_version }} + # dotnet nuget push */bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} \ No newline at end of file From c0f12575d897225f15efd2a67f6b59e445e63cf2 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Tue, 11 Apr 2023 13:53:04 +0300 Subject: [PATCH 25/71] test feature --- .github/workflows/ci-cd.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 146c44f4..86bd5a01 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -35,7 +35,7 @@ jobs: - name: Create tag id: create_tag run: | - git fetch --tags --force + git fetch --tags --force &> /dev/null PR_TITLE=$(git log -1 --pretty='%f') LAST_TAG=$(echo $(git describe --tags $(git rev-list --tags --max-count=1)) | cut -d'v' -f 2) CURRENT_MAJOR=$(echo $LAST_TAG | cut -d. -f 1) @@ -47,11 +47,11 @@ jobs: PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} - echo "release_version=$PACKAGE_VERSION" >> "$GITHUB_OUTPUT" + echo "release_package_version=$PACKAGE_VERSION" >> "$GITHUB_OUTPUT" - name: Pack - run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_version }} + run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} #- name: Release # run: | - # git tag v${{ steps.create_tag.outputs.release_version }} - # git push origin v${{ steps.create_tag.outputs.release_version }} - # dotnet nuget push */bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} \ No newline at end of file + # git tag v${{ steps.create_tag.outputs.release_package_version }} + # git push origin v${{ steps.create_tag.outputs.release_package_version }} + # dotnet nuget push */bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} \ No newline at end of file From 4779ac3cc1f7fe5d652085b75bd1573c3b541c63 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Tue, 11 Apr 2023 13:59:12 +0300 Subject: [PATCH 26/71] fix pack --- .github/workflows/ci-cd.yml | 1 + .../OData.QueryBuilder.Benchmark.csproj | 23 +++++++-------- .../OData.QueryBuilder.Fakes.csproj | 7 +++-- .../OData.QueryBuilder.Test.csproj | 28 +++++++++---------- 4 files changed, 31 insertions(+), 28 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 86bd5a01..d4a3cf9b 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -48,6 +48,7 @@ jobs: NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} echo "release_package_version=$PACKAGE_VERSION" >> "$GITHUB_OUTPUT" + echo $PACKAGE_VERSION - name: Pack run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} #- name: Release diff --git a/test/OData.QueryBuilder.Benchmark/OData.QueryBuilder.Benchmark.csproj b/test/OData.QueryBuilder.Benchmark/OData.QueryBuilder.Benchmark.csproj index 275f079c..9b013683 100644 --- a/test/OData.QueryBuilder.Benchmark/OData.QueryBuilder.Benchmark.csproj +++ b/test/OData.QueryBuilder.Benchmark/OData.QueryBuilder.Benchmark.csproj @@ -1,17 +1,18 @@ - - Exe - netcoreapp3.1 - + + Exe + false + netcoreapp3.1 + - - - + + + - - - - + + + + diff --git a/test/OData.QueryBuilder.Fakes/OData.QueryBuilder.Fakes.csproj b/test/OData.QueryBuilder.Fakes/OData.QueryBuilder.Fakes.csproj index 9f5c4f4a..5daedb11 100644 --- a/test/OData.QueryBuilder.Fakes/OData.QueryBuilder.Fakes.csproj +++ b/test/OData.QueryBuilder.Fakes/OData.QueryBuilder.Fakes.csproj @@ -1,7 +1,8 @@ - - netstandard2.0 - + + netstandard2.0 + false + diff --git a/test/OData.QueryBuilder.Test/OData.QueryBuilder.Test.csproj b/test/OData.QueryBuilder.Test/OData.QueryBuilder.Test.csproj index 939f71ec..465c6f0e 100644 --- a/test/OData.QueryBuilder.Test/OData.QueryBuilder.Test.csproj +++ b/test/OData.QueryBuilder.Test/OData.QueryBuilder.Test.csproj @@ -1,16 +1,16 @@  - - netcoreapp3.1 - false - - - - - - - - - - - + + netcoreapp3.1 + false + + + + + + + + + + + \ No newline at end of file From 516659223b2bb71b8c4d8185e5df912b90307bc4 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Tue, 11 Apr 2023 15:29:39 +0300 Subject: [PATCH 27/71] test deploy --- .github/workflows/ci-cd.yml | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index d4a3cf9b..48c79042 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -3,8 +3,8 @@ on: push env: DOTNET_VERSION: '3.1.x' jobs: - ci-cd: - name: build-and-test-${{matrix.os}} + ci: + name: build&test-${{matrix.os}} runs-on: ${{ matrix.os }} environment: ci-cd strategy: @@ -32,6 +32,12 @@ jobs: dotnet minicover uninstrument dotnet minicover report # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} + cd: + if: github.ref == 'refs/heads/main' + name: release + runs-on: ubuntu-latest + environment: ci-cd + steps: - name: Create tag id: create_tag run: | @@ -53,6 +59,6 @@ jobs: run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} #- name: Release # run: | + # dotnet nuget push */bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} # git tag v${{ steps.create_tag.outputs.release_package_version }} - # git push origin v${{ steps.create_tag.outputs.release_package_version }} - # dotnet nuget push */bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} \ No newline at end of file + # git push origin v${{ steps.create_tag.outputs.release_package_version }} \ No newline at end of file From 2c75c6e4683a65ce28ea9a785948a6728b6e8adc Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Tue, 11 Apr 2023 15:32:06 +0300 Subject: [PATCH 28/71] test --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 48c79042..e71bf946 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -33,7 +33,7 @@ jobs: dotnet minicover report # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} cd: - if: github.ref == 'refs/heads/main' + if: github.ref == 'refs/heads/feature/migrate-to-github-actions' name: release runs-on: ubuntu-latest environment: ci-cd From 2f0e43331d6f3b4ebc26ca31e225a9a8b9ed55eb Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Tue, 11 Apr 2023 15:43:28 +0300 Subject: [PATCH 29/71] test 1 --- .github/workflows/ci-cd.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index e71bf946..4208018b 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -33,6 +33,7 @@ jobs: dotnet minicover report # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} cd: + needs: ci if: github.ref == 'refs/heads/feature/migrate-to-github-actions' name: release runs-on: ubuntu-latest From 930dc1bb75021b8e551b8b75b3d17faac75824d7 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Tue, 11 Apr 2023 15:46:04 +0300 Subject: [PATCH 30/71] test --- .github/workflows/ci-cd.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 4208018b..0a3118ea 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -39,6 +39,8 @@ jobs: runs-on: ubuntu-latest environment: ci-cd steps: + - name: Checkout + uses: actions/checkout@v3 - name: Create tag id: create_tag run: | From b30285bba6324e120b678162fee30f6dbbc037cc Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 13:04:12 +0300 Subject: [PATCH 31/71] test publish package --- .github/workflows/ci-cd.yml | 10 +++++----- src/OData.QueryBuilder/OData.QueryBuilder.csproj | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 0a3118ea..833b3ed8 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -60,8 +60,8 @@ jobs: echo $PACKAGE_VERSION - name: Pack run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} - #- name: Release - # run: | - # dotnet nuget push */bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} - # git tag v${{ steps.create_tag.outputs.release_package_version }} - # git push origin v${{ steps.create_tag.outputs.release_package_version }} \ No newline at end of file + - name: Release + run: | + dotnet nuget push */bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} + git tag v${{ steps.create_tag.outputs.release_package_version }} + git push origin v${{ steps.create_tag.outputs.release_package_version }} \ No newline at end of file diff --git a/src/OData.QueryBuilder/OData.QueryBuilder.csproj b/src/OData.QueryBuilder/OData.QueryBuilder.csproj index 4d3d26ca..3f379831 100644 --- a/src/OData.QueryBuilder/OData.QueryBuilder.csproj +++ b/src/OData.QueryBuilder/OData.QueryBuilder.csproj @@ -5,7 +5,7 @@ true snupkg netstandard2.0 - OData.QueryBuilder + DotNetToolTest $(PackageVersion) MIT true From 72ffa7b3ec0ab638d414589e4f6ed713d6942aed Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 13:10:05 +0300 Subject: [PATCH 32/71] test release by actions --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 833b3ed8..fe01f25e 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -62,6 +62,6 @@ jobs: run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} - name: Release run: | - dotnet nuget push */bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} + dotnet nuget push ./src/OData.QueryBuilder/bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} git tag v${{ steps.create_tag.outputs.release_package_version }} git push origin v${{ steps.create_tag.outputs.release_package_version }} \ No newline at end of file From bfa115f896bfa80de005245304ababb4b87b3ae9 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 13:16:42 +0300 Subject: [PATCH 33/71] test publish 1 --- .github/workflows/ci-cd.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index fe01f25e..98843ec6 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -62,6 +62,7 @@ jobs: run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} - name: Release run: | + ls -a dotnet nuget push ./src/OData.QueryBuilder/bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} git tag v${{ steps.create_tag.outputs.release_package_version }} git push origin v${{ steps.create_tag.outputs.release_package_version }} \ No newline at end of file From 569c8a98f55d65554915f1837f61c960af21eda3 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 13:25:43 +0300 Subject: [PATCH 34/71] test release 2 --- .github/workflows/ci-cd.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 98843ec6..e38d57f4 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -18,10 +18,8 @@ jobs: uses: actions/setup-dotnet@v3 with: dotnet-version: ${{ env.DOTNET_VERSION }} - - name: Restore - run: dotnet restore - name: Build - run: dotnet build -c ${{ vars.CONFIGURATION }} --no-restore + run: dotnet build -c ${{ vars.CONFIGURATION }} - name: Test run: dotnet test -c ${{ vars.CONFIGURATION }} --no-build - name: Coveralls @@ -62,6 +60,8 @@ jobs: run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} - name: Release run: | + ls -a + cd src/OData.QueryBuilder ls -a dotnet nuget push ./src/OData.QueryBuilder/bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} git tag v${{ steps.create_tag.outputs.release_package_version }} From 6d1d0c78c6b112ac5ae9a7ae8707f0d951f43462 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 13:31:32 +0300 Subject: [PATCH 35/71] test release 3 --- .github/workflows/ci-cd.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index e38d57f4..6f4b912c 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -63,6 +63,10 @@ jobs: ls -a cd src/OData.QueryBuilder ls -a + cd bin + ls -a + cd Release + ls -a dotnet nuget push ./src/OData.QueryBuilder/bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} git tag v${{ steps.create_tag.outputs.release_package_version }} git push origin v${{ steps.create_tag.outputs.release_package_version }} \ No newline at end of file From 2a165a6740af44fe198c7aa269d5c87095b93b78 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 13:39:51 +0300 Subject: [PATCH 36/71] test release 4 --- .github/workflows/ci-cd.yml | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 6f4b912c..a7a37cb4 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -45,6 +45,7 @@ jobs: git fetch --tags --force &> /dev/null PR_TITLE=$(git log -1 --pretty='%f') LAST_TAG=$(echo $(git describe --tags $(git rev-list --tags --max-count=1)) | cut -d'v' -f 2) + echo $LAST_TAG CURRENT_MAJOR=$(echo $LAST_TAG | cut -d. -f 1) CURRENT_MINOR=$(echo $LAST_TAG | cut -d. -f 2) CURRENT_PATCH=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 1) @@ -60,13 +61,6 @@ jobs: run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} - name: Release run: | - ls -a - cd src/OData.QueryBuilder - ls -a - cd bin - ls -a - cd Release - ls -a dotnet nuget push ./src/OData.QueryBuilder/bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} git tag v${{ steps.create_tag.outputs.release_package_version }} git push origin v${{ steps.create_tag.outputs.release_package_version }} \ No newline at end of file From d9aa1288a6a61ea8cafc2877fd8ebdf47f73c5e9 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 13:47:56 +0300 Subject: [PATCH 37/71] test release 5 --- .github/workflows/ci-cd.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index a7a37cb4..fa231a6f 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -45,15 +45,16 @@ jobs: git fetch --tags --force &> /dev/null PR_TITLE=$(git log -1 --pretty='%f') LAST_TAG=$(echo $(git describe --tags $(git rev-list --tags --max-count=1)) | cut -d'v' -f 2) - echo $LAST_TAG CURRENT_MAJOR=$(echo $LAST_TAG | cut -d. -f 1) CURRENT_MINOR=$(echo $LAST_TAG | cut -d. -f 2) CURRENT_PATCH=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 1) RC=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 2) + echo $CURRENT_MAJOR $CURRENT_MINOR $CURRENT_PATCH $RC MAJOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MAJOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo $(($CURRENT_MAJOR+1))) || echo $CURRENT_MAJOR) MINOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MINOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo $(($CURRENT_MINOR+1))) || echo $CURRENT_MINOR) PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) + echo $MAJOR $MINOR $PATCH PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} echo "release_package_version=$PACKAGE_VERSION" >> "$GITHUB_OUTPUT" echo $PACKAGE_VERSION From fbeac85c52a7af4c5e401e025d57a5b4f8edd21c Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 13:52:01 +0300 Subject: [PATCH 38/71] test release 6 --- .github/workflows/ci-cd.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index fa231a6f..b6e12c73 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -6,7 +6,7 @@ jobs: ci: name: build&test-${{matrix.os}} runs-on: ${{ matrix.os }} - environment: ci-cd + environment: ci strategy: matrix: #os: [ubuntu-latest, windows-latest, macOS-latest] @@ -35,7 +35,7 @@ jobs: if: github.ref == 'refs/heads/feature/migrate-to-github-actions' name: release runs-on: ubuntu-latest - environment: ci-cd + environment: cd steps: - name: Checkout uses: actions/checkout@v3 From 1d06e8be57084de77140909d17bb9358a52e9103 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 13:58:08 +0300 Subject: [PATCH 39/71] test publish 1 --- .github/workflows/ci-cd.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index b6e12c73..a7242c45 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -49,12 +49,10 @@ jobs: CURRENT_MINOR=$(echo $LAST_TAG | cut -d. -f 2) CURRENT_PATCH=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 1) RC=$(echo $(echo $LAST_TAG | cut -d. -f 3) | cut -d- -f 2) - echo $CURRENT_MAJOR $CURRENT_MINOR $CURRENT_PATCH $RC MAJOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MAJOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo $(($CURRENT_MAJOR+1))) || echo $CURRENT_MAJOR) MINOR=$(([ "$RC" == "rc" ] && echo $CURRENT_MINOR) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo $(($CURRENT_MINOR+1))) || echo $CURRENT_MINOR) PATCH=$(([ "$RC" == "rc" ] && echo $CURRENT_PATCH) || ([ "$(echo $PR_TITLE | grep -oP 'release')" == "release" ] && echo 0) || ([ "$(echo $PR_TITLE | grep -oP 'feature')" == "feature" ] && echo 0) || echo $(($CURRENT_PATCH+1))) NEW_TAG=$(echo $MAJOR.$MINOR.$PATCH) - echo $MAJOR $MINOR $PATCH PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} echo "release_package_version=$PACKAGE_VERSION" >> "$GITHUB_OUTPUT" echo $PACKAGE_VERSION From e815bed92cd929cf001a79eb4e94be4f869f1edf Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 14:03:24 +0300 Subject: [PATCH 40/71] test publish 2 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index a7242c45..62b48bbc 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -60,6 +60,6 @@ jobs: run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} - name: Release run: | - dotnet nuget push ./src/OData.QueryBuilder/bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} + dotnet nuget push ./src/OData.QueryBuilder/bin/Release/DotNetToolTest.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} git tag v${{ steps.create_tag.outputs.release_package_version }} git push origin v${{ steps.create_tag.outputs.release_package_version }} \ No newline at end of file From 2d820886f6638255021ae7897ca9acc151e37a2f Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 14:26:11 +0300 Subject: [PATCH 41/71] test publish 3 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 62b48bbc..2d76f63b 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -60,6 +60,6 @@ jobs: run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} - name: Release run: | - dotnet nuget push ./src/OData.QueryBuilder/bin/Release/DotNetToolTest.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} + dotnet nuget push ./src/OData.QueryBuilder/bin/Release/DotNetToolTest.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} --skip-duplicate git tag v${{ steps.create_tag.outputs.release_package_version }} git push origin v${{ steps.create_tag.outputs.release_package_version }} \ No newline at end of file From ba3395c4ecfdaf28b97b77c02da4bdfea1f13e50 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 14:50:56 +0300 Subject: [PATCH 42/71] test publish 5 --- .github/workflows/ci-cd.yml | 7 ++++--- .github/workflows/release.yml | 27 +++++++++++++++++++++++++++ OData.QueryBuilder.sln | 1 + 3 files changed, 32 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 2d76f63b..17124d1d 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -1,4 +1,4 @@ -name: OData.QueryBuilder +name: OData.QueryBuilder CI\CD on: push env: DOTNET_VERSION: '3.1.x' @@ -33,7 +33,7 @@ jobs: cd: needs: ci if: github.ref == 'refs/heads/feature/migrate-to-github-actions' - name: release + name: publish runs-on: ubuntu-latest environment: cd steps: @@ -62,4 +62,5 @@ jobs: run: | dotnet nuget push ./src/OData.QueryBuilder/bin/Release/DotNetToolTest.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} --skip-duplicate git tag v${{ steps.create_tag.outputs.release_package_version }} - git push origin v${{ steps.create_tag.outputs.release_package_version }} \ No newline at end of file + git push origin v${{ steps.create_tag.outputs.release_package_version }} + gh release create -t "v${{ steps.create_tag.outputs.release_package_version }}" --generate-notes \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 00000000..fbda0fcb --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,27 @@ +name: OData.QueryBuilder Create release +on: + push: + tags: + - 'v*' +name: Create Release +jobs: + build: + name: Create Release + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v3 + - name: Create Release + id: create_release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ github.ref }} + release_name: Release ${{ github.ref }} + body: | + Changes in this Release + - First Change + - Second Change + draft: false + prerelease: false \ No newline at end of file diff --git a/OData.QueryBuilder.sln b/OData.QueryBuilder.sln index 61cab4c1..64a4c8b1 100644 --- a/OData.QueryBuilder.sln +++ b/OData.QueryBuilder.sln @@ -31,6 +31,7 @@ EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "workflows", "workflows", "{D95B88FB-7257-421E-8AA3-BD85C63ECBE6}" ProjectSection(SolutionItems) = preProject .github\workflows\ci-cd.yml = .github\workflows\ci-cd.yml + .github\workflows\release.yml = .github\workflows\release.yml EndProjectSection EndProject Global From 3e42be3dfb6ae68165954f23cee9df16f741b717 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 14:52:15 +0300 Subject: [PATCH 43/71] test publish 7 --- .github/workflows/ci-cd.yml | 2 +- .github/workflows/release.yml | 27 --------------------------- 2 files changed, 1 insertion(+), 28 deletions(-) delete mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 17124d1d..98f4c878 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -33,7 +33,7 @@ jobs: cd: needs: ci if: github.ref == 'refs/heads/feature/migrate-to-github-actions' - name: publish + name: Release runs-on: ubuntu-latest environment: cd steps: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml deleted file mode 100644 index fbda0fcb..00000000 --- a/.github/workflows/release.yml +++ /dev/null @@ -1,27 +0,0 @@ -name: OData.QueryBuilder Create release -on: - push: - tags: - - 'v*' -name: Create Release -jobs: - build: - name: Create Release - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v3 - - name: Create Release - id: create_release - uses: actions/create-release@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - tag_name: ${{ github.ref }} - release_name: Release ${{ github.ref }} - body: | - Changes in this Release - - First Change - - Second Change - draft: false - prerelease: false \ No newline at end of file From f9f693e4af33138d90749341f3fe1c9de6ed2dbb Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sat, 28 Oct 2023 14:54:34 +0300 Subject: [PATCH 44/71] publish test 1 --- .github/workflows/ci-cd.yml | 6 +++--- OData.QueryBuilder.sln | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 98f4c878..d8b5a369 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -1,10 +1,10 @@ -name: OData.QueryBuilder CI\CD +name: OData.QueryBuilder ci\cd on: push env: DOTNET_VERSION: '3.1.x' jobs: ci: - name: build&test-${{matrix.os}} + name: build-${{matrix.os}} runs-on: ${{ matrix.os }} environment: ci strategy: @@ -33,7 +33,7 @@ jobs: cd: needs: ci if: github.ref == 'refs/heads/feature/migrate-to-github-actions' - name: Release + name: release runs-on: ubuntu-latest environment: cd steps: diff --git a/OData.QueryBuilder.sln b/OData.QueryBuilder.sln index 64a4c8b1..61cab4c1 100644 --- a/OData.QueryBuilder.sln +++ b/OData.QueryBuilder.sln @@ -31,7 +31,6 @@ EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "workflows", "workflows", "{D95B88FB-7257-421E-8AA3-BD85C63ECBE6}" ProjectSection(SolutionItems) = preProject .github\workflows\ci-cd.yml = .github\workflows\ci-cd.yml - .github\workflows\release.yml = .github\workflows\release.yml EndProjectSection EndProject Global From 8b875fc1f6b35307fe148715b873206a965f0784 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 10:48:50 +0300 Subject: [PATCH 45/71] publish test 2 --- .github/workflows/ci-cd.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index d8b5a369..385fe77c 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -59,6 +59,8 @@ jobs: - name: Pack run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} - name: Release + env: + GH_TOKEN: ${{ secrets.ACCSESS_TOKEN }} run: | dotnet nuget push ./src/OData.QueryBuilder/bin/Release/DotNetToolTest.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} --skip-duplicate git tag v${{ steps.create_tag.outputs.release_package_version }} From f4d4754fd97a78bee13f89cea41df8daa6343c4a Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 10:52:21 +0300 Subject: [PATCH 46/71] publish test 3 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 385fe77c..c3060c46 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -65,4 +65,4 @@ jobs: dotnet nuget push ./src/OData.QueryBuilder/bin/Release/DotNetToolTest.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} --skip-duplicate git tag v${{ steps.create_tag.outputs.release_package_version }} git push origin v${{ steps.create_tag.outputs.release_package_version }} - gh release create -t "v${{ steps.create_tag.outputs.release_package_version }}" --generate-notes \ No newline at end of file + gh release create v${{ steps.create_tag.outputs.release_package_version }} --generate-notes \ No newline at end of file From 5af913f3bd97b72906b329c3e9b038b2443ed21b Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 11:05:08 +0300 Subject: [PATCH 47/71] publish test final --- .github/workflows/ci-cd.yml | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index c3060c46..8d30d1fe 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -4,7 +4,7 @@ env: DOTNET_VERSION: '3.1.x' jobs: ci: - name: build-${{matrix.os}} + name: build&test-${{matrix.os}} runs-on: ${{ matrix.os }} environment: ci strategy: @@ -12,17 +12,17 @@ jobs: #os: [ubuntu-latest, windows-latest, macOS-latest] os: [ubuntu-latest] steps: - - name: Checkout + - name: checkout uses: actions/checkout@v3 - - name: Setup .NET SDK ${{ matrix.dotnet-version }} + - name: setup .NET SDK ${{ matrix.dotnet-version }} uses: actions/setup-dotnet@v3 with: dotnet-version: ${{ env.DOTNET_VERSION }} - - name: Build + - name: build run: dotnet build -c ${{ vars.CONFIGURATION }} - - name: Test + - name: test run: dotnet test -c ${{ vars.CONFIGURATION }} --no-build - - name: Coveralls + - name: coveralls run: | dotnet minicover instrument dotnet minicover reset @@ -32,14 +32,14 @@ jobs: # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} cd: needs: ci - if: github.ref == 'refs/heads/feature/migrate-to-github-actions' - name: release + if: github.ref == 'refs/heads/main' + name: publish&release runs-on: ubuntu-latest environment: cd steps: - - name: Checkout + - name: checkout uses: actions/checkout@v3 - - name: Create tag + - name: create tag id: create_tag run: | git fetch --tags --force &> /dev/null @@ -56,13 +56,13 @@ jobs: PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} echo "release_package_version=$PACKAGE_VERSION" >> "$GITHUB_OUTPUT" echo $PACKAGE_VERSION - - name: Pack + - name: pack run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} - - name: Release + - name: release env: GH_TOKEN: ${{ secrets.ACCSESS_TOKEN }} run: | - dotnet nuget push ./src/OData.QueryBuilder/bin/Release/DotNetToolTest.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} --skip-duplicate + dotnet nuget push ./src/OData.QueryBuilder/bin/Release/OData.QueryBuilder.${{ steps.create_tag.outputs.release_package_version }}.nupkg -k ${{ secrets.NUGET_API_KEY }} -s ${{ vars.NUGET_SOURCE }} git tag v${{ steps.create_tag.outputs.release_package_version }} git push origin v${{ steps.create_tag.outputs.release_package_version }} gh release create v${{ steps.create_tag.outputs.release_package_version }} --generate-notes \ No newline at end of file From 7fd705246bc1952b2ecc28a40d2699526448f08a Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 11:07:54 +0300 Subject: [PATCH 48/71] test cover 1 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 8d30d1fe..f8167baa 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -29,7 +29,7 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - # dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} + dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} cd: needs: ci if: github.ref == 'refs/heads/main' From be106257dfd6e98397377999fba2d2fab39d8c4f Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 11:09:48 +0300 Subject: [PATCH 49/71] test cover 2 --- .github/workflows/ci-cd.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index f8167baa..71f010c5 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -4,7 +4,7 @@ env: DOTNET_VERSION: '3.1.x' jobs: ci: - name: build&test-${{matrix.os}} + name: build&test(${{matrix.os}}) runs-on: ${{ matrix.os }} environment: ci strategy: @@ -29,6 +29,7 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report + echo ${{ vars.GITHUB_ACTION }} dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} cd: needs: ci From 75b70605c3a9110831640da2af3aae07979e424d Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 11:16:35 +0300 Subject: [PATCH 50/71] test cover 3 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 71f010c5..f1da0abc 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -29,7 +29,7 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - echo ${{ vars.GITHUB_ACTION }} + echo ${GITHUB_RUN_ID} dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} cd: needs: ci From 5530dfd6f0edab3036c8851ac9bd3c1ab5cdfd00 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 11:27:18 +0300 Subject: [PATCH 51/71] test cover 4 --- .github/workflows/ci-cd.yml | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index f1da0abc..d31145a2 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -12,24 +12,26 @@ jobs: #os: [ubuntu-latest, windows-latest, macOS-latest] os: [ubuntu-latest] steps: - - name: checkout + - name: Checkout uses: actions/checkout@v3 - name: setup .NET SDK ${{ matrix.dotnet-version }} uses: actions/setup-dotnet@v3 with: dotnet-version: ${{ env.DOTNET_VERSION }} - - name: build + - name: Build run: dotnet build -c ${{ vars.CONFIGURATION }} - - name: test + - name: Test run: dotnet test -c ${{ vars.CONFIGURATION }} --no-build - - name: coveralls + - name: Coveralls run: | dotnet minicover instrument dotnet minicover reset dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - echo ${GITHUB_RUN_ID} + echo ${{ github.run_id }} + echo ${{ github.run_number }} + echo ${{ github.run_attempt }} dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} cd: needs: ci @@ -38,9 +40,9 @@ jobs: runs-on: ubuntu-latest environment: cd steps: - - name: checkout + - name: Checkout uses: actions/checkout@v3 - - name: create tag + - name: Create tag id: create_tag run: | git fetch --tags --force &> /dev/null @@ -57,9 +59,9 @@ jobs: PACKAGE_VERSION=${NEW_TAG:-${{ vars.DEFAULT_PACKAGE_VERSION }}} echo "release_package_version=$PACKAGE_VERSION" >> "$GITHUB_OUTPUT" echo $PACKAGE_VERSION - - name: pack + - name: Pack run: dotnet pack -c ${{ vars.CONFIGURATION }} -p:PackageVersion=${{ steps.create_tag.outputs.release_package_version }} - - name: release + - name: Release env: GH_TOKEN: ${{ secrets.ACCSESS_TOKEN }} run: | From 5553e0a5b3c0a43070ea77e7907536ca6d907a6c Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 11:29:01 +0300 Subject: [PATCH 52/71] test cover 5 --- .github/workflows/ci-cd.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index d31145a2..f3f7fa76 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -29,10 +29,7 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - echo ${{ github.run_id }} - echo ${{ github.run_number }} - echo ${{ github.run_attempt }} - dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ vars.GITHUB_ACTION }} + dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ github.run_number }} cd: needs: ci if: github.ref == 'refs/heads/main' From 2c78e5a2e061c346cb47cb1ba95924e48459e9f0 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 11:33:09 +0300 Subject: [PATCH 53/71] test cover 6 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index f3f7fa76..deb0706b 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -29,7 +29,7 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ github.run_number }} + dotnet minicover coverallsreport --service-name "OData.QueryBuilder" --service-job-id ${{ github.run_number }} cd: needs: ci if: github.ref == 'refs/heads/main' From 176f4aa0c4d86ad2222c3f20045f9c2797641340 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 12:13:42 +0300 Subject: [PATCH 54/71] test cover 7 --- .github/workflows/ci-cd.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index deb0706b..a27002b0 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -1,5 +1,7 @@ name: OData.QueryBuilder ci\cd -on: push +on: + - push + - pull_request env: DOTNET_VERSION: '3.1.x' jobs: @@ -9,7 +11,6 @@ jobs: environment: ci strategy: matrix: - #os: [ubuntu-latest, windows-latest, macOS-latest] os: [ubuntu-latest] steps: - name: Checkout @@ -28,8 +29,9 @@ jobs: dotnet minicover reset dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument + ls -a dotnet minicover report - dotnet minicover coverallsreport --service-name "OData.QueryBuilder" --service-job-id ${{ github.run_number }} + dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ github.run_id }} cd: needs: ci if: github.ref == 'refs/heads/main' From 1bd666fc44e50c5579fcb3ca39b6322f4e86af05 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 12:22:25 +0300 Subject: [PATCH 55/71] test cover 8 --- .github/workflows/ci-cd.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index a27002b0..b3ece99d 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -24,14 +24,15 @@ jobs: - name: Test run: dotnet test -c ${{ vars.CONFIGURATION }} --no-build - name: Coveralls + continue-on-error: true run: | dotnet minicover instrument dotnet minicover reset dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument - ls -a dotnet minicover report dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ github.run_id }} + ls -a cd: needs: ci if: github.ref == 'refs/heads/main' From 8f9e9f3a8391be141f6e4404cffbe59749bfc729 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 12:25:11 +0300 Subject: [PATCH 56/71] test cover 9 --- .github/workflows/ci-cd.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index b3ece99d..2190a005 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -32,6 +32,8 @@ jobs: dotnet minicover uninstrument dotnet minicover report dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ github.run_id }} + - name: Coveralls1 + run: | ls -a cd: needs: ci From e0e8af32ef3e23fe18fa24130402435c2e59f6aa Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 12:36:09 +0300 Subject: [PATCH 57/71] test cover 10 --- .github/workflows/ci-cd.yml | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 2190a005..e86d1251 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -1,7 +1,5 @@ name: OData.QueryBuilder ci\cd -on: - - push - - pull_request +on: [pull_request] env: DOTNET_VERSION: '3.1.x' jobs: @@ -24,17 +22,13 @@ jobs: - name: Test run: dotnet test -c ${{ vars.CONFIGURATION }} --no-build - name: Coveralls - continue-on-error: true run: | dotnet minicover instrument dotnet minicover reset dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - dotnet minicover coverallsreport --service-name "github-actions" --service-job-id ${{ github.run_id }} - - name: Coveralls1 - run: | - ls -a + dotnet minicover coverallsreport --service-name "github" --service-job-id ${{ github.run_id }} cd: needs: ci if: github.ref == 'refs/heads/main' From f4087dbe3057c8811832c33a52226e1c70b9de21 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 12:43:32 +0300 Subject: [PATCH 58/71] test publish 11 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index e86d1251..e44ac36a 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -28,7 +28,7 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - dotnet minicover coverallsreport --service-name "github" --service-job-id ${{ github.run_id }} + dotnet minicover coverallsreport --service-name "github" --repo_token ${{ secrets.ACCSESS_TOKEN }} cd: needs: ci if: github.ref == 'refs/heads/main' From bb4b7d5469252e17d1a9c17f23485b37baa151eb Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 12:58:44 +0300 Subject: [PATCH 59/71] test cover 12 --- .github/workflows/ci-cd.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index e44ac36a..faf61d8d 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -28,6 +28,7 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report + echo ${{ secrets.ACCSESS_TOKEN }} dotnet minicover coverallsreport --service-name "github" --repo_token ${{ secrets.ACCSESS_TOKEN }} cd: needs: ci From 73e3c0f5e04bae64cb31e9ac187d600d37c2f9cf Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:03:24 +0300 Subject: [PATCH 60/71] test cover 13 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index faf61d8d..4bfaea42 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -29,7 +29,7 @@ jobs: dotnet minicover uninstrument dotnet minicover report echo ${{ secrets.ACCSESS_TOKEN }} - dotnet minicover coverallsreport --service-name "github" --repo_token ${{ secrets.ACCSESS_TOKEN }} + dotnet minicover coverallsreport --service-name "github" --repo_token ${{ secrets.COVERALLS_REPO_TOKEN }} cd: needs: ci if: github.ref == 'refs/heads/main' From 959dfdc9a34feb6c6cd7142db9b080b405b8bc45 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:05:26 +0300 Subject: [PATCH 61/71] test cover 13 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 4bfaea42..5fb50d32 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -28,7 +28,7 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - echo ${{ secrets.ACCSESS_TOKEN }} + echo ${{ secrets.COVERALLS_REPO_TOKEN }} dotnet minicover coverallsreport --service-name "github" --repo_token ${{ secrets.COVERALLS_REPO_TOKEN }} cd: needs: ci From 737917ef02d594bef24068d25b583b94cf3cfb30 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:05:58 +0300 Subject: [PATCH 62/71] test cover 13 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 5fb50d32..3e8d82d4 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -29,7 +29,7 @@ jobs: dotnet minicover uninstrument dotnet minicover report echo ${{ secrets.COVERALLS_REPO_TOKEN }} - dotnet minicover coverallsreport --service-name "github" --repo_token ${{ secrets.COVERALLS_REPO_TOKEN }} + dotnet minicover coverallsreport --service-name "github" --repo-token ${{ secrets.COVERALLS_REPO_TOKEN }} cd: needs: ci if: github.ref == 'refs/heads/main' From d41736963c794546ecf024db655b7677267d1ec1 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:11:02 +0300 Subject: [PATCH 63/71] test cover 14 --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 3e8d82d4..e455315d 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -29,7 +29,7 @@ jobs: dotnet minicover uninstrument dotnet minicover report echo ${{ secrets.COVERALLS_REPO_TOKEN }} - dotnet minicover coverallsreport --service-name "github" --repo-token ${{ secrets.COVERALLS_REPO_TOKEN }} + dotnet minicover coverallsreport --service-name "github" --service-job-id ${{ github.run_number }} --repo-token ${{ secrets.COVERALLS_REPO_TOKEN }} cd: needs: ci if: github.ref == 'refs/heads/main' From 1931cc68dbd4a839ba0153c4d4ac4b30ae5c4606 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:26:24 +0300 Subject: [PATCH 64/71] test cover 15 --- .github/workflows/ci-cd.yml | 7 +++++-- README.md | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index e455315d..95857ba1 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -28,8 +28,11 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - echo ${{ secrets.COVERALLS_REPO_TOKEN }} - dotnet minicover coverallsreport --service-name "github" --service-job-id ${{ github.run_number }} --repo-token ${{ secrets.COVERALLS_REPO_TOKEN }} + dotnet minicover coverallsreport --service-name "github" \ + --service-job-id ${{ github.run_number }} \ + --repo-token ${{ secrets.COVERALLS_REPO_TOKEN }} \ + --branch ${{ github.ref_name }} + --commit ${{ github.sha }} cd: needs: ci if: github.ref == 'refs/heads/main' diff --git a/README.md b/README.md index 1a1e71df..bb2dd894 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ Library for creating complex OData queries (OData version 4.01) based on data models with linq syntax. [![Build Status](https://travis-ci.com/ZEXSM/OData.QueryBuilder.svg?branch=main)](https://travis-ci.com/ZEXSM/OData.QueryBuilder) -[![Coverage Status](https://coveralls.io/repos/github/ZEXSM/OData.QueryBuilder/badge.svg?branch=master)](https://coveralls.io/github/ZEXSM/OData.QueryBuilder?branch=master) +[![Coverage Status](https://coveralls.io/repos/github/ZEXSM/OData.QueryBuilder/badge.svg?branch=master)](https://coveralls.io/github/ZEXSM/OData.QueryBuilder?branch=main) [![Nuget Status](https://img.shields.io/nuget/dt/OData.QueryBuilder.svg)](https://www.nuget.org/packages/OData.QueryBuilder) ## Benefits From 73c6589920dfd33f8317ce8b8257a07baaa4db94 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:28:57 +0300 Subject: [PATCH 65/71] fix --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 95857ba1..98b9551a 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -31,7 +31,7 @@ jobs: dotnet minicover coverallsreport --service-name "github" \ --service-job-id ${{ github.run_number }} \ --repo-token ${{ secrets.COVERALLS_REPO_TOKEN }} \ - --branch ${{ github.ref_name }} + --branch ${{ github.ref_name }} \ --commit ${{ github.sha }} cd: needs: ci From cc856a84fe8afbfbcaf636bd94783951430797de Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:36:05 +0300 Subject: [PATCH 66/71] text cover 16 --- .github/workflows/ci-cd.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 98b9551a..4d8059e4 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -13,7 +13,7 @@ jobs: steps: - name: Checkout uses: actions/checkout@v3 - - name: setup .NET SDK ${{ matrix.dotnet-version }} + - name: Setup .NET SDK ${{ matrix.dotnet-version }} uses: actions/setup-dotnet@v3 with: dotnet-version: ${{ env.DOTNET_VERSION }} @@ -28,6 +28,9 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report + echo ${{ github.job }} + echo ${{ github.run_id }} + echo ${{ github.ref_name }} dotnet minicover coverallsreport --service-name "github" \ --service-job-id ${{ github.run_number }} \ --repo-token ${{ secrets.COVERALLS_REPO_TOKEN }} \ From c5656bafae32f0d0f79edd5e57ba7bc69b5b0191 Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:44:17 +0300 Subject: [PATCH 67/71] test cover 3 --- .github/workflows/ci-cd.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 4d8059e4..857a49b0 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -31,6 +31,7 @@ jobs: echo ${{ github.job }} echo ${{ github.run_id }} echo ${{ github.ref_name }} + echo ${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}} dotnet minicover coverallsreport --service-name "github" \ --service-job-id ${{ github.run_number }} \ --repo-token ${{ secrets.COVERALLS_REPO_TOKEN }} \ From 440d2a53b22f351f1daa28c7ec74fc0b8dc1ffea Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:48:11 +0300 Subject: [PATCH 68/71] test cover 3 --- .github/workflows/ci-cd.yml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 857a49b0..8310055b 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -28,14 +28,12 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - echo ${{ github.job }} + echo ${{ github.job.job_id }} echo ${{ github.run_id }} - echo ${{ github.ref_name }} - echo ${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}} dotnet minicover coverallsreport --service-name "github" \ - --service-job-id ${{ github.run_number }} \ + --service-job-id ${{ github.run_id }} \ --repo-token ${{ secrets.COVERALLS_REPO_TOKEN }} \ - --branch ${{ github.ref_name }} \ + --branch ${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}} \ --commit ${{ github.sha }} cd: needs: ci From 4ee0da74c67942f777689e92c5b93e7a22e9a99d Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:59:14 +0300 Subject: [PATCH 69/71] test cover final --- .github/workflows/ci-cd.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 8310055b..c6c7ed91 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -1,5 +1,5 @@ name: OData.QueryBuilder ci\cd -on: [pull_request] +on: pull_request env: DOTNET_VERSION: '3.1.x' jobs: @@ -28,8 +28,6 @@ jobs: dotnet test -c ${{ vars.CONFIGURATION }} --no-build dotnet minicover uninstrument dotnet minicover report - echo ${{ github.job.job_id }} - echo ${{ github.run_id }} dotnet minicover coverallsreport --service-name "github" \ --service-job-id ${{ github.run_id }} \ --repo-token ${{ secrets.COVERALLS_REPO_TOKEN }} \ From 11b232d9a8f40e74b9a854f58c928e48e7c018fc Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 13:59:51 +0300 Subject: [PATCH 70/71] fix --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index c6c7ed91..5c976021 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -4,7 +4,7 @@ env: DOTNET_VERSION: '3.1.x' jobs: ci: - name: build&test(${{matrix.os}}) + name: build&test&coverage(${{matrix.os}}) runs-on: ${{ matrix.os }} environment: ci strategy: From 4cf18afe291a332374daf25cac4a66aac4364ede Mon Sep 17 00:00:00 2001 From: ZEXSM Date: Sun, 29 Oct 2023 14:07:02 +0300 Subject: [PATCH 71/71] test --- .github/workflows/ci-cd.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 5c976021..f00ef79c 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -1,5 +1,9 @@ name: OData.QueryBuilder ci\cd -on: pull_request +on: + push: + branches: + - main + pull_request: env: DOTNET_VERSION: '3.1.x' jobs: