-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from MareMare/dev
各ワークフローを追加します。
Showing
6 changed files
with
163 additions
and
12 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 @@ | ||
* @MareMare |
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,25 @@ | ||
# To get started with Dependabot version updates, you'll need to specify which | ||
# package ecosystems to update and where the package manifests are located. | ||
# Please see the documentation for all configuration options: | ||
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates | ||
|
||
version: 2 | ||
updates: | ||
# nuget の依存関係を維持します。 | ||
- package-ecosystem: "nuget" # See documentation for possible values | ||
directory: "/" # Location of package manifests | ||
schedule: | ||
interval: "daily" | ||
# 日本標準時 (UTC +09:00) に nuget の更新をチェックします。 | ||
time: "04:00" | ||
timezone: "Asia/Tokyo" | ||
# レビュー担当者を追加します。 | ||
reviewers: | ||
- "MareMare" | ||
# nuget プルリクエストのラベルを指定します。 | ||
labels: | ||
- "dependencies" | ||
# バージョン更新のプルリクエストを発行します。 | ||
target-branch: "main" | ||
# Allow up to 10 open pull requests for dependencies | ||
open-pull-requests-limit: 10 |
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,45 @@ | ||
name: .NET Build & UnitTests | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: [ main ] | ||
paths: | ||
- "src/**" | ||
pull_request: | ||
branches: [ main ] | ||
paths: | ||
- "src/**" | ||
|
||
jobs: | ||
build-and-test: | ||
|
||
strategy: | ||
matrix: | ||
configuration: [ Release ] | ||
include: | ||
- os: windows-latest | ||
osName: Windows | ||
|
||
name: 🚀 [${{ matrix.configuration }}] Build and Test on ${{ matrix.osName }} | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: 🛒 Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: ✨ Set up .NET 6.0 | ||
uses: actions/setup-dotnet@v2 | ||
with: | ||
dotnet-version: 6.0.x | ||
|
||
- name: 🚚 Restore dependencies | ||
working-directory: src | ||
run: dotnet restore | ||
|
||
- name: 🛠️ Build | ||
working-directory: src | ||
run: dotnet build --configuration $env:Configuration --no-restore | ||
env: | ||
Configuration: ${{ matrix.configuration }} |
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,80 @@ | ||
name: Create Release and Upload Asset | ||
|
||
# https://github.com/actions/upload-release-asset | ||
|
||
on: | ||
push: | ||
# Sequence of patterns matched against refs/tags | ||
tags: | ||
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10 | ||
|
||
jobs: | ||
build: | ||
name: Upload Release Asset | ||
runs-on: windows-latest | ||
|
||
steps: | ||
- name: 🛒 Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: ✨ Set up .NET 6.0 | ||
uses: actions/setup-dotnet@v2 | ||
with: | ||
dotnet-version: 6.0.x | ||
|
||
- name: 🚚 Restore dependencies | ||
working-directory: src | ||
run: dotnet restore | ||
|
||
- name: 🛠️ Build | ||
working-directory: src | ||
run: dotnet build --configuration Release --no-restore | ||
|
||
- name: 🚀 Publish BackupSqlDatabase | ||
shell: pwsh | ||
run: | | ||
dotnet publish .\src\BackupSqlDatabase\BackupSqlDatabase.csproj --configuration Release --output out\BackupSqlDatabase --runtime win-x64 --self-contained true | ||
rm out\BackupSqlDatabase\*.pdb | ||
Compress-Archive -Path "out\BackupSqlDatabase\*.*" -DestinationPath "out\BackupSqlDatabase-win-x64.zip" | ||
- name: 🚀 Publish RestoreSqlDatabase | ||
shell: pwsh | ||
run: | | ||
dotnet publish .\src\RestoreSqlDatabase\RestoreSqlDatabase.csproj --configuration Release --output out\RestoreSqlDatabase --runtime win-x64 --self-contained true | ||
rm out\RestoreSqlDatabase\*.pdb | ||
Compress-Archive -Path "out\RestoreSqlDatabase\*.*" -DestinationPath "out\RestoreSqlDatabase-win-x64.zip" | ||
- name: 📝 Create Release | ||
id: create_release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
tag_name: ${{ github.ref }} | ||
release_name: Release ${{ github.ref }} | ||
body: | | ||
TBD | ||
draft: true | ||
prerelease: true | ||
|
||
- name: 🚢 Upload BackupSqlDatabase Release Asset | ||
uses: actions/upload-release-asset@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps | ||
asset_path: out\BackupSqlDatabase-win-x64.zip | ||
asset_name: BackupSqlDatabase-win-x64.zip | ||
asset_content_type: application/zip | ||
|
||
- name: 🚢 Upload RestoreSqlDatabase Release Asset | ||
uses: actions/upload-release-asset@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps | ||
asset_path: out\RestoreSqlDatabase-win-x64.zip | ||
asset_name: RestoreSqlDatabase-win-x64.zip | ||
asset_content_type: application/zip |
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
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