Skip to content

Build

Build #21752

Workflow file for this run

name: Build
on:
push:
branches:
- main
schedule:
- cron: '0 * * * *' # Every hour
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Cache NuGet Packages
uses: actions/cache@v2
with:
path: ~/.nuget/packages
key: ${{github.sha}}
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.x
- name: Additional NuGet Sources
run: dotnet nuget add source https://www.myget.org/F/sixlabors/api/v3/index.json -n SixLabors
- name: Restore
run: dotnet restore
- name: Build
env:
GitHubToken: ${{ secrets.GITHUB_TOKEN }}
run: dotnet build -c Release && dotnet run --project src/Repo2Image/Repo2Image.csproj -c Release
- name: Publish
uses: netlify/actions/cli@master
with:
args: deploy --dir=src/Repo2Image/output --prod
env:
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}