Update ReadMe.md #31
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: Full Build | |
on: | |
push: | |
branches: | |
- master | |
workflow_dispatch: | |
jobs: | |
buildtex: | |
runs-on: ubuntu-latest | |
container: | |
image: docker://grandfleet/dolwarp:v0.70 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: | | |
apt-get update && apt-get install xpdf imagemagick git -y | |
- name: Compile TeX | |
run: | | |
chmod +x ./compile_tex.sh && ./compile_tex.sh | |
./compile_tex.sh -p 2 -l 1 -r 1 -o Reference.md | |
- name: Persist Tex Artifacts | |
uses: actions/upload-artifact@v1 | |
with: | |
path: . | |
name: latex | |
buildfiles: | |
needs: buildtex | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Download Latex Artifacts | |
uses: actions/download-artifact@v1 | |
with: | |
name: latex | |
path: . | |
# reason files are committed here, is because of the other docker image not having git | |
- name: Commit files | |
run: > | |
mkdir ~/.git | |
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
git config --local user.name "github-actions[bot]" | |
git add *.png || true | |
git commit -m "Update images" || true | |
- name: Push changes | |
uses: ad-m/github-push-action@master | |
- name: Compile Saber docs | |
run: chmod +x ./CompileNextra.sh && ./CompileNextra.sh | |
- name: Setup Node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 19.6 | |
- name: Checkout latex-diagrams-docs | |
uses: actions/checkout@v2 | |
with: | |
repository: FriendlyUser/latex-diagrams-docs | |
path: latex-diagrams-docs | |
- name: Move saber folder | |
run: | | |
cp -R saber/pages/* latex-diagrams-docs/pages/ | |
rm -rf saber/pages || true | |
ls saber/public/software || true | |
mv saber/public latex-diagrams-docs || true | |
mv saber latex-diagrams-docs || true | |
- name: Persist artifacts | |
uses: actions/upload-artifact@v1 | |
with: | |
path: latex-diagrams-docs | |
name: nextra | |
- name: setup node | |
run: | | |
cd latex-diagrams-docs | |
ls | |
npm install | |
npm install sharp | |
- name: build app | |
run: | | |
rm -rf .git | |
cd latex-diagrams-docs | |
npm run export | |
echo "grandfleet.eu.org" >> out/CNAME || true | |
echo "google.com, pub-2479144310234386, DIRECT, f08c47fec0942fa0" >> out/ads.txt || true | |
echo "" >> .nojekyll || true | |
rm -rf .git | |
mv .nojekyll out || true | |
ls || true | |
cd ../ || true | |
ls latex-diagrams-docs/out | |
# add google adsense to all html pages? | |
- name: Persist artifacts | |
uses: actions/upload-artifact@v1 | |
with: | |
path: latex-diagrams-docs | |
name: output | |
- uses: crazy-max/ghaction-github-pages@v3 | |
with: | |
target_branch: gh-pages | |
build_dir: latex-diagrams-docs/out | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |