Skip to content

Commit

Permalink
[CD] Deploy slides to GitHub Pages
Browse files Browse the repository at this point in the history
Deploy built PDF slides to GitHub Pages to make them accessible on the website
  • Loading branch information
aobolensk committed Sep 22, 2024
1 parent affa6de commit 56369f1
Show file tree
Hide file tree
Showing 17 changed files with 90 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ name: Build

on: [push, pull_request]

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

jobs:
ubuntu-build:
runs-on: ubuntu-latest
Expand All @@ -20,6 +25,10 @@ jobs:
with:
name: pdf-linux
path: '*.pdf'
- uses: actions/upload-artifact@v4
with:
name: html
path: '*.html'
macos-build:
runs-on: macos-latest
steps:
Expand All @@ -35,3 +44,27 @@ jobs:
with:
name: pdf-macos
path: '*.pdf'
deploy-to-github-pages:
needs: ubuntu-build
runs-on: ubuntu-latest
# if: github.ref == 'refs/heads/main'
steps:
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Download PDF artifact
uses: actions/download-artifact@v4
with:
name: pdf-linux
path: ./slides
- name: Download PDF artifact
uses: actions/download-artifact@v4
with:
name: html
path: ./
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: '.'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
57 changes: 57 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>ITLab slides</title>
<style>
body {
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
color: #333;
background-color: #f9f9f9;
margin: 20px;
padding: 20px;
}
h1 {
font-size: 2em;
margin-bottom: 0.5em;
color: #333;
}
ol {
list-style-type: decimal;
margin-left: 40px;
}
li {
font-size: 1.2em;
margin-bottom: 0.5em;
}
a {
color: #4183c4;
text-decoration: none;
}
a:hover {
text-decoration: underline;
}
/* Orderedlist theme-inspired header */
header {
background-color: #4183c4;
padding: 10px 0;
color: white;
text-align: center;
}
</style>
</head>
<body>
<header>
<h1>ITLab slides</h1>
</header>
<ul>
<li><a href="https://embedded-dev-research.github.io/itlab_slides/slides/00-intro.pdf" target="_blank">00: Introduction</a></li>
<li><a href="https://embedded-dev-research.github.io/itlab_slides/slides/01-git.pdf" target="_blank">01: Git</a></li>
<li><a href="https://embedded-dev-research.github.io/itlab_slides/slides/02-cmake.pdf" target="_blank">02: CMake</a></li>
<li><a href="https://embedded-dev-research.github.io/itlab_slides/slides/03-linux.pdf" target="_blank">03: Linux</a></li>
<li><a href="https://embedded-dev-research.github.io/itlab_slides/slides/04-cpp-project-structure.pdf" target="_blank">04: C++ project structure</a></li>
<li><a href="https://embedded-dev-research.github.io/itlab_slides/slides/05-embedded-arm.pdf" target="_blank">05: Embedded architectures (ARM)</a></li>
</ul>
</body>
</html>

0 comments on commit 56369f1

Please sign in to comment.