Releasing docs by @ankhralovich #110
Workflow file for this run
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
name: Release docs | |
run-name: Releasing docs by @${{ github.actor }} | |
# temporary solution to test without merging to main | |
on: | |
pull_request: | |
branches: | |
- main | |
permissions: | |
contents: read | |
pages: write | |
id-token: write | |
concurrency: | |
group: "pages" | |
cancel-in-progress: false | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout self | |
uses: actions/checkout@v4 | |
# Arcane Operator | |
- name: Checkout arcane-operator (main) | |
uses: actions/checkout@v4 | |
with: | |
repository: SneaksAndData/arcane-operator | |
path: arcane-operator-main | |
# Latest | |
- name: Checkout arcane-operator (latest release) | |
uses: actions/checkout@v4 | |
with: | |
repository: SneaksAndData/arcane-operator | |
path: arcane-operator-latest | |
fetch-depth: 0 | |
- name: Determine latest release commit for arcane-operator | |
run: | | |
cd arcane-operator-latest | |
git fetch --tags | |
LAST_TAG=$(git tag --sort=version:refname | tail -n 1 | head -1) | |
echo "Checking latest out tag: $LAST_TAG" | |
echo "$LAST_TAG" > LAST_TAG.txt | |
git checkout $LAST_TAG | |
- name: Modify toc.yml with tags for arcane-operator | |
run: | | |
cd ${{ github.workspace }} | |
TAG=$(cat arcane-operator-latest/LAST_TAG.txt) | |
echo "Checking latest out tag: $TAG" | |
sed -i "s|- name: operator 1 release|- name: $TAG|g" toc.yml | |
# 2nd Latest | |
- name: Checkout arcane-operator (2nd latest release) | |
uses: actions/checkout@v4 | |
with: | |
repository: SneaksAndData/arcane-operator | |
path: arcane-operator-2nd-latest | |
fetch-depth: 0 | |
- name: Determine 2nd latest release commit for arcane-operator | |
run: | | |
cd arcane-operator-2nd-latest | |
git fetch --tags | |
LAST_TAG=$(git tag --sort=version:refname | tail -n 2 | head -1) | |
echo "Checking latest out tag: $LAST_TAG" | |
echo "$LAST_TAG" > LAST_TAG.txt | |
git checkout $LAST_TAG | |
- name: Modify toc.yml with tags for arcane-operator | |
run: | | |
cd ${{ github.workspace }} | |
TAG=$(cat arcane-operator-2nd-latest/LAST_TAG.txt) | |
echo "Checking latest out tag: $TAG" | |
sed -i "s|- name: operator 2 release|- name: $TAG|g" toc.yml | |
# 3rd Latest | |
- name: Checkout arcane-operator (3rd latest release) | |
uses: actions/checkout@v4 | |
with: | |
repository: SneaksAndData/arcane-operator | |
path: arcane-operator-3rd-latest | |
fetch-depth: 0 | |
- name: Determine 3rd latest release commit for arcane-operator | |
run: | | |
cd arcane-operator-3rd-latest | |
git fetch --tags | |
LAST_TAG=$(git tag --sort=version:refname | tail -n 3 | head -1) | |
echo "Checking 3rd latest out tag: $LAST_TAG" | |
echo "$LAST_TAG" > LAST_TAG.txt | |
git checkout $LAST_TAG | |
- name: Modify toc.yml with tags for arcane-operator | |
run: | | |
cd ${{ github.workspace }} | |
TAG=$(cat arcane-operator-3rd-latest/LAST_TAG.txt) | |
echo "Checking 3rd latest out tag: $TAG" | |
sed -i "s|- name: operator 3 release|- name: $TAG|g" toc.yml | |
# Arcane Framework | |
- name: Checkout arcane-framework (main) | |
uses: actions/checkout@v4 | |
with: | |
repository: SneaksAndData/arcane-framework | |
path: arcane-framework-main | |
# Latest | |
- name: Checkout arcane-framework (latest release) | |
uses: actions/checkout@v4 | |
with: | |
repository: SneaksAndData/arcane-framework | |
path: arcane-framework-latest | |
fetch-depth: 0 | |
- name: Determine latest release commit for arcane-framework | |
run: | | |
cd arcane-framework-latest | |
git fetch --tags | |
LAST_TAG=$(git tag --sort=version:refname | tail -n 1 | head -1) | |
echo "Checking latest out tag: $LAST_TAG" | |
echo "$LAST_TAG" > LAST_TAG.txt | |
git checkout $LAST_TAG | |
- name: Modify toc.yml with tags for arcane-framework | |
run: | | |
cd ${{ github.workspace }} | |
TAG=$(cat arcane-framework-latest/LAST_TAG.txt) | |
echo "Checking latest out tag: $TAG" | |
sed -i "s|- name: framework 1 release|- name: $TAG|g" toc.yml | |
# 2nd Latest | |
- name: Checkout arcane-framework (2nd latest release) | |
uses: actions/checkout@v4 | |
with: | |
repository: SneaksAndData/arcane-framework | |
path: arcane-framework-2nd-latest | |
fetch-depth: 0 | |
- name: Determine 2nd latest release commit for arcane-framework | |
run: | | |
cd arcane-framework-2nd-latest | |
git fetch --tags | |
LAST_TAG=$(git tag --sort=version:refname | tail -n 2 | head -1) | |
echo "Checking 2nd latest out tag: $LAST_TAG" | |
echo "$LAST_TAG" > LAST_TAG.txt | |
git checkout $LAST_TAG | |
- name: Modify toc.yml with tags for arcane-framework | |
run: | | |
cd ${{ github.workspace }} | |
TAG=$(cat arcane-framework-2nd-latest/LAST_TAG.txt) | |
echo "Checking latest out tag: $TAG" | |
sed -i "s|- name: framework 2 release|- name: $TAG|g" toc.yml | |
# 3rd Latest | |
- name: Checkout arcane-framework (3rd latest release) | |
uses: actions/checkout@v4 | |
with: | |
repository: SneaksAndData/arcane-framework | |
path: arcane-framework-3rd-latest | |
fetch-depth: 0 | |
- name: Determine 3rd latest release commit for arcane-framework | |
run: | | |
cd arcane-framework-3rd-latest | |
git fetch --tags | |
LAST_TAG=$(git tag --sort=version:refname | tail -n 3 | head -1) | |
echo "Checking 3rd latest out tag: $LAST_TAG" | |
echo "$LAST_TAG" > LAST_TAG.txt | |
git checkout $LAST_TAG | |
- name: Modify toc.yml with tags for arcane-framework | |
run: | | |
cd ${{ github.workspace }} | |
TAG=$(cat arcane-framework-3rd-latest/LAST_TAG.txt) | |
echo "Checking 3rd latest out tag: $TAG" | |
sed -i "s|- name: framework 3 release|- name: $TAG|g" toc.yml | |
# REST API | |
- name: Checkout arcane-rest-api (main) | |
uses: actions/checkout@v4 | |
with: | |
repository: SneaksAndData/arcane-stream-rest-api | |
path: arcane-rest-api-main | |
# Latest | |
- name: Checkout arcane-rest-api (latest release) | |
uses: actions/checkout@v4 | |
with: | |
repository: SneaksAndData/arcane-stream-rest-api | |
path: arcane-rest-api-latest | |
fetch-depth: 0 | |
- name: Determine latest release commit for arcane-rest-api | |
run: | | |
cd arcane-rest-api-latest | |
git fetch --tags | |
LAST_TAG=$(git tag --sort=version:refname | tail -n 1 | head -1) | |
echo "Checking latest out tag: $LAST_TAG" | |
echo "$LAST_TAG" > LAST_TAG.txt | |
git checkout $LAST_TAG | |
- name: Modify toc.yml with tags for arcane-rest-api | |
run: | | |
cd ${{ github.workspace }} | |
TAG=$(cat arcane-rest-api-latest/LAST_TAG.txt) | |
echo "Checking latest out tag: $TAG" | |
sed -i "s|- name: rest-api 1 release|- name: $TAG|g" toc.yml | |
# Pages | |
- name: Setup Pages | |
uses: actions/configure-pages@v5 | |
- name: Setup .NET Core | |
uses: actions/[email protected] | |
- name: Setup DocFX | |
run: dotnet tool update -g docfx | |
- name: DocFX Build | |
run: docfx docfx.json | |
continue-on-error: false | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v3 | |
with: | |
# Upload entire repository | |
path: "./_site" | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v4 | |
- name: Print Page URL | |
run: echo "Github Pages URL ${{ steps.deployment.outputs.page_url }}" |