-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update resharper inspections and github workflows.
- Loading branch information
Showing
4 changed files
with
140 additions
and
48 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 |
---|---|---|
|
@@ -18,48 +18,59 @@ jobs: | |
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
|
||
- uses: actions/setup-dotnet@v2 | ||
with: | ||
dotnet-version: | | ||
6.0.x | ||
7.0.x | ||
8.0.x | ||
- name: Build | ||
run: | | ||
dotnet restore | ||
dotnet build -c Release --no-restore | ||
- name: Test | ||
run: dotnet test -c Release --no-restore --no-build --verbosity minimal | ||
|
||
- name: Package | ||
if: github.ref == 'refs/heads/main' && github.event_name == 'push' | ||
run: dotnet pack -c Release --no-restore --no-build --version-suffix "github$GITHUB_RUN_ID" | ||
|
||
- uses: actions/upload-artifact@v3 | ||
if: github.ref == 'refs/heads/main' && github.event_name == 'push' | ||
with: | ||
name: nupkg | ||
path: nuget/* | ||
|
||
- name: Build Docs | ||
if: github.event_name == 'push' | ||
run: | | ||
dotnet tool restore | ||
cd ./docfx | ||
sed -i -E "s/%APP_VERSION%/${GITHUB_REF_NAME}/" docfx_project/docfx.json | ||
dotnet docfx docfx_project/docfx.json | ||
- uses: actions/upload-artifact@v3 | ||
if: github.event_name == 'push' | ||
with: | ||
name: docfx-site | ||
path: docfx/docfx_project/_site/ | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: recursive | ||
|
||
- uses: actions/setup-dotnet@v4 | ||
with: | ||
dotnet-version: | | ||
6.0.x | ||
7.0.x | ||
8.0.x | ||
- name: Build | ||
run: | | ||
dotnet restore | ||
dotnet build -c Release --no-restore | ||
- name: Test | ||
run: dotnet test -c Release --no-restore --no-build --verbosity minimal | ||
|
||
- name: Inspect | ||
uses: JetBrains/[email protected] | ||
with: | ||
tool-version: 2023.3.4 | ||
solution: Remora.Discord.sln | ||
build: false | ||
no-build: true | ||
telemetry-optout: true | ||
|
||
- name: Package | ||
if: github.ref == 'refs/heads/main' && github.event_name == 'push' | ||
run: dotnet pack -c Release --no-restore --no-build --version-suffix "github$GITHUB_RUN_ID" | ||
|
||
- uses: actions/upload-artifact@v4 | ||
with: | ||
name: nupkg | ||
path: nuget/* | ||
|
||
- name: Build Docs | ||
if: github.event_name == 'push' | ||
run: | | ||
dotnet tool restore | ||
cd ./docfx | ||
sed -i -E "s/%APP_VERSION%/${GITHUB_REF_NAME}/" docfx_project/docfx.json | ||
dotnet docfx docfx_project/docfx.json | ||
- uses: actions/upload-artifact@v4 | ||
if: github.event_name == 'push' | ||
with: | ||
name: docfx-site | ||
path: docfx/docfx_project/_site/ | ||
|
||
permissions: | ||
security-events: write | ||
|
||
publish_docs: | ||
name: Publish Documentation | ||
|
@@ -72,12 +83,12 @@ jobs: | |
|
||
steps: | ||
- name: Checkout triggering branch | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
with: | ||
path: base | ||
|
||
- name: Checkout gh-pages | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: gh-pages | ||
path: site | ||
|
@@ -86,7 +97,7 @@ jobs: | |
run: bash base/docfx/scripts/prepare.sh | ||
|
||
- name: Download documentation artifacts | ||
uses: actions/download-artifact@v3 | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: docfx-site | ||
path: site/${{ github.ref_name }} | ||
|
@@ -108,15 +119,17 @@ jobs: | |
|
||
steps: | ||
- name: Download package artifacts | ||
uses: actions/download-artifact@v3 | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: nupkg | ||
path: nuget | ||
|
||
# To ensure that the current version being pushed does not get pruned we prune first. | ||
- name: Prune packages older than 4 versions (new version is the 5th) | ||
uses: smartsquaregmbh/delete-old-packages@v0.6.0 | ||
uses: smartsquaregmbh/delete-old-packages@v0.8.0 | ||
with: | ||
organization: Remora | ||
type: nuget | ||
keep: 4 | ||
names: | | ||
Remora.Discord | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
14 changes: 14 additions & 0 deletions
14
.idea/.idea.Remora.Discord/.idea/inspectionProfiles/Project_Default.xml
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.