Skip to content

Sanitize incoming urls everywhere. #61

Sanitize incoming urls everywhere.

Sanitize incoming urls everywhere. #61

Workflow file for this run

on:
push:
branches:
- main
- master
- 'release/**'
pull_request:
branches:
- main
- master
- 'release/**'
jobs:
build:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Setup .NET Core SDK
uses: actions/setup-dotnet@v1.7.2
with:
dotnet-version: 6.0.402
- name: Install packages
run: dotnet restore
- name: Run build
run: dotnet build
- name: Test
run: dotnet test -c Release || exit 1
- name: Deploy
if: github.repository_owner == 'Authress' && github.ref != 'refs/heads/main' && github.ref != 'refs/heads/master' && github.event_name == 'push'
env:
NUGET_KEY: ${{ secrets.NUGET_KEY }}
run: |
branchId="${GITHUB_REF/refs\/heads\/release\//}"
buildNumber="${branchId}.${GITHUB_RUN_NUMBER}"
sed "s/0.0.1/${buildNumber}/g" src/Authress.SDK/*.csproj -i
dotnet pack -c Release -o artifacts || exit 1
dotnet nuget push artifacts/Authress.SDK.${buildNumber}.nupkg -s "https://api.nuget.org/v3/index.json" -k "$NUGET_KEY"
- name: Create Github Release and Tag
if: github.repository_owner == 'Authress' && github.ref != 'refs/heads/main' && github.ref != 'refs/heads/master' && github.event_name == 'push'
run: |
git tag ${GITHUB_REF/refs\/heads\/release\//}.$GITHUB_RUN_NUMBER
git push origin ${GITHUB_REF/refs\/heads\/release\//}.$GITHUB_RUN_NUMBER