Skip to content

Test from PR 5 #1313

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Sep 17, 2023
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
34 changes: 11 additions & 23 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,6 @@ jobs:
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:

- name: Get merged pull request
uses: actions-ecosystem/action-get-merged-pull-request@v1
id: get_merged_pull_request
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
- name: Print merged pull request
run: echo 'PR number = ${{steps.get_merged_pull_request.outputs.number}}'

- name: Setup PostgreSQL
uses: ikalnytskyi/action-setup-postgres@v4
with:
Expand Down Expand Up @@ -77,19 +68,6 @@ jobs:
Write-Host "$(pwsh --version) is installed at $PSHOME"
psql --version
Write-Host "Using .NET SDK: $(dotnet --version)"
- name: Print messages
shell: pwsh
env:
MY_MSG: "Auto-generated documentation from ${{ github.event.pull_request.merged == true && github.event.pull_request.url || github.sha }}"
run: |
Write-Host "Message = $env:MY_MSG"
- name: Dump event object
shell: pwsh
env:
MY_JSON: "${{toJSON(github.event)}}"
run: |
Write-Host "Message = $env:MY_JSON"
#
- name: Git checkout
uses: actions/checkout@v3
- name: Restore tools
Expand Down Expand Up @@ -281,6 +259,16 @@ jobs:
run: |
dotnet nuget add source --username 'json-api-dotnet' --password "$env:GITHUB_TOKEN" --store-password-in-clear-text --name 'github' 'https://nuget.pkg.github.com/json-api-dotnet/index.json'
dotnet nuget push "$env:GITHUB_WORKSPACE/packages/*.nupkg" --api-key "$env:GITHUB_TOKEN" --source 'github'
- name: Find merged pull request
uses: actions-ecosystem/action-get-merged-pull-request@v1
id: find_merged_pull_request
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
# TODO: Remove test
- name: Print merged pull request
run: |
echo 'PR number = ${{ steps.find_merged_pull_request.outputs.number }}'
echo 'SHA = ${{ github.sha }}'
- name: Publish documentation
#if: github.event_name == 'push' && github.ref == 'refs/heads/master'
uses: peaceiris/actions-gh-pages@v3
Expand All @@ -291,7 +279,7 @@ jobs:
#publish_branch: gh-pages
publish_dir: ./documentation
#commit_message: 'Auto-generated documentation from: ${{ github.event.head_commit.message }}'
full_commit_message: "Auto-generated documentation from ${{ github.event.pull_request.merged == true && github.event.pull_request.url || github.sha }}"
full_commit_message: "Auto-generated documentation from ${{ steps.find_merged_pull_request.outputs.number && format('#{0}', steps.find_merged_pull_request.outputs.number) || github.sha }}"

- name: Publish to NuGet
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
Expand Down
2 changes: 1 addition & 1 deletion docs/home/index.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
Expand Down