Skip to content

Update Java API for branch master #757

Update Java API for branch master

Update Java API for branch master #757

Workflow file for this run

name: Build Index
on:
push:
branches:
- 'main'
paths-ignore:
- './index.html'
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Build Index
run: |
LATEST_FOLDER=$(find . -maxdepth 1 -mindepth 1 -type d -exec basename {} \; | sort --version-sort | tail -1)
touch index.html
cat > index.html << EOF
<!DOCTYPE html>
<html lang="en">
<head>
<title>drasyl JavaDoc – You will be redirected...</title>
<meta http-equiv="refresh" content="0; URL=https://api.drasyl.org/${LATEST_FOLDER}" />
</head>
<body>
<p>If you are not redirected, <a href="https://api.drasyl.org/${LATEST_FOLDER}">click here</a>.</p>
</body>
</html>
EOF
- name: Commit Files
run: |
git config --local user.email "bot@drasyl.org"
git config --local user.name "drasyl Bot"
git add ./index.html
git commit -m "Updated index.html" || true
- name: Push Index
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}