diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4c0ef5fe..083b93ed 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -29,18 +29,18 @@ jobs: uses: actions/setup-dotnet@v1 with: dotnet-version: 3.1.101 + - name: 'Dotnet Tool Restore' + run: dotnet tool restore + shell: pwsh - name: 'Dotnet Cake Build' - uses: ecampidoglio/cake-action@v1.1.1 - with: - target: Build + run: dotnet cake --target=Build + shell: pwsh - name: 'Dotnet Cake Test' - uses: ecampidoglio/cake-action@v1.1.1 - with: - target: Test + run: dotnet cake --target=Test + shell: pwsh - name: 'Dotnet Cake Pack' - uses: ecampidoglio/cake-action@v1.1.1 - with: - target: Pack + run: dotnet cake --target=Pack + shell: pwsh - name: 'Publish Artefacts' uses: actions/upload-artifact@v1.0.0 with: diff --git a/Schema.NET.sln b/Schema.NET.sln index a6351404..fd620fd2 100644 --- a/Schema.NET.sln +++ b/Schema.NET.sln @@ -17,6 +17,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution azure-pipelines.yml = azure-pipelines.yml build.cake = build.cake .github\workflows\build.yml = .github\workflows\build.yml + dotnet-tools.json = dotnet-tools.json Key.snk = Key.snk EndProjectSection EndProject diff --git a/appveyor.yml b/appveyor.yml index 052ea34e..454efed6 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -26,7 +26,7 @@ build_script: - sh: sudo apt update - sh: sudo apt install -y apt-transport-https dotnet-sdk-3.1 - cmd: choco install dotnetcore-sdk --no-progress --confirm --version 3.1.101 -- pwsh: dotnet tool install --global Cake.Tool +- pwsh: dotnet tool restore - pwsh: dotnet cake --target=Build - pwsh: dotnet cake --target=Test - pwsh: dotnet cake --target=Pack diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 32f76789..a65f7d73 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -40,8 +40,8 @@ stages: inputs: packageType: 'sdk' version: '3.1.101' - - script: 'dotnet tool install --global Cake.Tool' - displayName: 'Install Cake Tool' + - script: 'dotnet tool restore' + displayName: 'Dotnet Tool Restore' failOnStderr: true - script: 'dotnet cake --target=Build' displayName: 'Dotnet Cake Build' diff --git a/dotnet-tools.json b/dotnet-tools.json new file mode 100644 index 00000000..6b6101d0 --- /dev/null +++ b/dotnet-tools.json @@ -0,0 +1,12 @@ +{ + "version": 1, + "isRoot": true, + "tools": { + "cake.tool": { + "version": "0.36.0", + "commands": [ + "dotnet-cake" + ] + } + } +}