Skip to content
Merged
Show file tree
Hide file tree
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
9 changes: 7 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,12 @@
version: 2
updates:
- package-ecosystem: "nuget"
directory: "/Google.Authenticator"
directory: "/Google.Authenticator.Tests"
directories:
- "/Google.Authenticator"
- "/Google.Authenticator.Tests"
schedule:
interval: "weekly"
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
41 changes: 41 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: build
on:
push:
branches:
- "**"
pull_request:
branches:
- "master"
jobs:
build_matrix:
strategy:
matrix:
os: [windows-latest, ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup .NET 6.0
uses: actions/setup-dotnet@v5
with:
dotnet-version: 6.0.x
- name: Setup .NET 7.0
uses: actions/setup-dotnet@v5
with:
dotnet-version: 7.0.x
- name: Restore Google.Authenticator
run: dotnet restore ./Google.Authenticator/Google.Authenticator.csproj
- name: Restore Google.Authenticator.Tests
run: dotnet restore ./Google.Authenticator.Tests/Google.Authenticator.Tests.csproj
- name: Build Package
run: dotnet build ./Google.Authenticator/Google.Authenticator.csproj --configuration Release --no-restore
- name: Build Tests
run: dotnet build ./Google.Authenticator.Tests/Google.Authenticator.Tests.csproj --configuration Release --no-restore --no-dependencies
- name: Test
run: dotnet test ./Google.Authenticator.Tests/Google.Authenticator.Tests.csproj --no-build --verbosity normal --configuration Release
- name: Pack
if: ${{ runner.os == 'Windows' && github.ref == 'refs/heads/master' && github.event_name != 'pull_request' }}
run: |
dotnet pack ./Google.Authenticator/Google.Authenticator.csproj --configuration $(buildConfiguration) --no-build
dotnet nuget push **\*.nupkg --source 'https://api.nuget.org/v3/index.json' --skip-duplicate -k ${{ secrets.NUGET_KEY }}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# GoogleAuthenticator
Simple, easy to use server-side two-factor authentication library for .NET that works with Google Authenticator

[![Build Status](https://dev.azure.com/brandon-potter/GoogleAuthenticator/_apis/build/status/BrandonPotter.GoogleAuthenticator?branchName=master)](https://dev.azure.com/brandon-potter/GoogleAuthenticator/_build/latest?definitionId=1&branchName=master)
[![build](https://github.com/BrandonPotter/GoogleAuthenticator/actions/workflows/build.yml/badge.svg)](https://github.com/BrandonPotter/GoogleAuthenticator/actions/workflows/build.yml)
[![NuGet Status](https://img.shields.io/nuget/v/GoogleAuthenticator.svg)](https://www.nuget.org/packages/GoogleAuthenticator/)

[`Install-Package GoogleAuthenticator`](https://www.nuget.org/packages/GoogleAuthenticator)
Expand Down