-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
19c6f1d
commit adf5150
Showing
1 changed file
with
94 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
name: Qwack Excel Deploy | ||
|
||
on: | ||
workflow_dispatch: | ||
env: | ||
ACTIONS_ALLOW_UNSECURE_COMMANDS: true | ||
|
||
jobs: | ||
job_1: | ||
name: Build, Zip and Store | ||
runs-on: windows-latest | ||
steps: | ||
- uses: actions/checkout@main | ||
name: Checkout Code | ||
with: | ||
submodules: 'true' | ||
|
||
- name: Setup MSBuild Path | ||
uses: warrenbuckley/Setup-MSBuild@v1 | ||
|
||
- name: Setup NuGet | ||
uses: NuGet/[email protected] | ||
|
||
- name: Restore NuGet Packages | ||
run: nuget restore Qwack.sln | ||
working-directory: './' | ||
|
||
- name: Restore DotNet | ||
run: dotnet restore | ||
working-directory: './' | ||
|
||
- name: Build and Publish Excel Add-in | ||
working-directory: './' | ||
run: | | ||
$version = Get-Content ../../version.txt | ||
dotnet build Qwackl.sln /p:Configuration=Release /p:DeployOnBuild=true /p:PublishProfile=FolderProfile | ||
- name: Zip deployment | ||
uses: vimtor/action-zip@v1 | ||
with: | ||
files: ./clients/Qwack.Excel.Next/bin/Release/net6.0-windows | ||
dest: QwackExcel.zip | ||
|
||
- name: Create Artifact | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: excelArtifact | ||
path: ./QwackExcel.zip | ||
|
||
name: Retrieve and Upload to Azure | ||
runs-on: ubuntu-latest | ||
needs: job_1 | ||
steps: | ||
|
||
- name: Fetch Artifact | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: excelArtifact | ||
|
||
- name: Fetch Artifact | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: msiArtifact | ||
|
||
- name: Login To Azure | ||
uses: azure/login@v1 | ||
with: | ||
creds: ${{ secrets.AZURE_CREDENTIALS }} | ||
|
||
- name: Upload to blob storage | ||
uses: azure/CLI@v1 | ||
with: | ||
azcliversion: 2.30.0 | ||
inlineScript: | | ||
az storage blob upload-batch --account-name pltfm -d exceladdin -s . --pattern GalenaExcel.zip | ||
- name: Upload MSI to blob storage | ||
uses: azure/CLI@v1 | ||
with: | ||
azcliversion: 2.30.0 | ||
inlineScript: | | ||
az storage blob upload-batch --account-name pltfm -d exceladdin -s . --pattern ExcelAddInDeploy.zip | ||
- name: logout | ||
run: | | ||
az logout | ||
- name: Delete Artifact | ||
uses: GeekyEggo/[email protected] | ||
with: | ||
name: | | ||
excelArtifact | ||
msiArtifact | ||