Voltage packet #21
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: Build LaTeX document | |
on: | |
pull_request: | |
types: | |
- closed | |
branches: | |
- main | |
jobs: | |
build_latex: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Set up Git repository | |
uses: actions/checkout@v3 | |
- name: Compile LaTeX document | |
uses: xu-cheng/latex-action@v3 | |
with: | |
work_in_root_file_dir: true | |
root_file: | | |
data-logging-format/data_logging_format.tex | |
radio-packet-format/radio_packet_format.tex | |
- name: Upload documents | |
uses: actions/upload-artifact@v3 | |
with: | |
name: Telemetry Specifications | |
path: | | |
radio-packet-format/radio_packet_format.pdf | |
data-logging-format/data_logging_format.pdf | |
- name: Generate PDF page | |
run: | | |
mkdir pdfs | |
cp radio-packet-format/radio_packet_format.pdf pdfs/ | |
cp data-logging-format/data_logging_format.pdf pdfs/ | |
cat > pdfs/index.html <<EOL | |
<!doctype html> | |
<html> | |
<head> | |
<title>File Browser</title> | |
</head> | |
<body> | |
<h1>Radio Packet Format</h1> | |
<object data="https://github.com/CarletonURocketry/telemetry-format/blob/gh-pages/data_logging_format.pdf" type="application/pdf" width="100%" height="500px"/> | |
<h1>Data Logging Format</h1> | |
<object data="https://github.com/CarletonURocketry/telemetry-format/blob/gh-pages/radio_packet_format.pdf" type="application/pdf" width="100%" height="500px"/> | |
</body> | |
</html> | |
EOL | |
- name: Deploy to GitHub Pages | |
uses: crazy-max/ghaction-github-pages@v4 | |
with: | |
target_branch: gh-pages | |
build_dir: pdfs | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |