Skip to content

Commit

Permalink
Merge branch 'develop' of https://github.com/SvenTiigi/FlyoverKit int…
Browse files Browse the repository at this point in the history
…o develop
  • Loading branch information
SvenTiigi committed Nov 29, 2022
2 parents 1e8e7ec + f7a7a08 commit 0c9b350
Showing 1 changed file with 65 additions and 0 deletions.
65 changes: 65 additions & 0 deletions .github/workflows/deploy_documentation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: Deploy Documentation

on:
workflow_dispatch:
push:
branches:
- main

permissions:
contents: read
pages: write
id-token: write

concurrency:
group: "pages"
cancel-in-progress: true

jobs:
build:
runs-on: macos-12
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Pages
uses: actions/configure-pages@v2
- name: Build Documentation
run: |
xcodebuild docbuild\
-scheme FlyoverKit\
-destination 'generic/platform=iOS'\
-derivedDataPath ../DerivedData
- name: Process Archive
run: |
mkdir _site
$(xcrun --find docc) process-archive \
transform-for-static-hosting ../DerivedData/Build/Products/Debug-iphoneos/FlyoverKit.doccarchive \
--output-path _site \
--hosting-base-path FlyoverKit
- name: Create Custom index.html
run: |
rm _site/index.html
cat > _site/index.html <<- EOM
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="refresh" content="0; url='https://sventiigi.github.io/FlyoverKit/documentation/flyoverkit/'" />
</head>
<body>
<p>Please follow <a href="https://sventiigi.github.io/FlyoverKit/documentation/flyoverkit/">this link</a>.</p>
</body>
</html>
EOM
- name: Upload Artifact
uses: actions/upload-pages-artifact@v1

deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1

0 comments on commit 0c9b350

Please sign in to comment.