Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build Actions #1

Merged
merged 2 commits into from
Mar 2, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 62 additions & 0 deletions .github/workflows/ui-examples.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Builds a library, and packages it up.
#
# Works on a release/version tag
# e.g release/1.0.2 will build v1.0.2
#

name: Pack UI Examples

env:
OUTPUT: ./Output

on:
push:
tags:
- "release/*"

jobs:
build:
runs-on: windows-latest

steps:
- name: Get Version
id: get_version
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\/release\//}
shell: bash

- name: checkout
uses: actions/checkout@v2

- name: Setup NuGet.exe for use with actions
uses: NuGet/setup-nuget@v1
with:
nuget-version: ${{ matrix.nuget }}

- name: Setup .net core
uses: actions/setup-dotnet@v1.4.0

- name: Setup UmbPack
run: dotnet tool install Umbraco.Tools.Packages --global

- name: Setup MSBuild
uses: microsoft/setup-msbuild@v1

- name: Restore Packages
run: dotnet restore

- name: Build Project
run: msbuild -p:Configuration=Release

# path to your package.xml file should go here.
- name: Create Umbraco package file
run: UmbPack pack ./package.xml -o ${{ env.OUTPUT }} -v ${{ steps.get_version.outputs.VERSION }}

# # For the push step to work you will need to create an api key on Our, and save it as a secret on Github with the name "UMBRACO_DEPLOY_KEY"
- name: Push package to Our
run: umbpack push ${{ env.OUTPUT }}/UiExamples_${{ steps.get_version.outputs.VERSION }}.zip -k ${{ secrets.UMBRACO_DEPLOY_KEY }}

- name: upload-artifacts
uses: actions/upload-artifact@v2
with:
name: Build-Results-${{ steps.get_version.outputs.VERSION }}
path: ${{ env.OUTPUT }}/**/*