-
Notifications
You must be signed in to change notification settings - Fork 147
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c52a2e9
commit e6724d3
Showing
1 changed file
with
15 additions
and
8 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,21 +7,28 @@ on: | |
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-20.04 | ||
runs-on: ubuntu-22.04 | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install dependencies | ||
- name: Free space | ||
run: df -h && rm -rf /opt/hostedtoolcache* && df -h | ||
|
||
- name: Install dependencies (apt-get) | ||
run: |- | ||
sudo apt-get update | ||
sudo apt-get install -y libmagickwand-dev wkhtmltopdf | ||
- name: Install dependencies (pip) | ||
run: |- | ||
python -m pip install --upgrade pip | ||
pip install beautifulsoup4==4.12.2 | ||
pip install wand==0.6.11 | ||
pip install pdfkit==1.0.0 | ||
pip install pillow==9.2.0 | ||
pip install lxml==4.9.1 | ||
sudo apt-get install wkhtmltopdf | ||
sudo apt-get install libmagickwand-dev | ||
- name: Run Single-HTML-Page Documentation Generator | ||
run: python code-generators/SinglePageDocGenerator.py | ||
|
@@ -34,15 +41,15 @@ jobs: | |
aws-region: us-west-1 | ||
|
||
- name: Copy files to the S3 website content bucket | ||
run: |- | ||
aws s3 cp ./single-page s3://${{ secrets.AWS_BUCKET }} --acl bucket-owner-full-control --exclude "*" --include "*.html" --content-type "text/html" | ||
aws s3 cp ./single-page s3://${{ secrets.AWS_BUCKET }} --acl bucket-owner-full-control --exclude "*" --include "*.pdf" --content-type "application/pdf" | ||
run: aws s3 cp ./single-page s3://${{ secrets.AWS_BUCKET }} --recursive --acl bucket-owner-full-control --exclude "*" --include "*.pdf" --content-type "application/pdf" | ||
|
||
- name: Push to Branch | ||
timeout-minutes: 30 | ||
run: |- | ||
BRANCH=github-action-single-page-doc-generator | ||
git config user.name GitHub Actions | ||
git config user.email [email protected] | ||
git config http.postBuffer 524288000 | ||
git checkout -b $BRANCH | ||
git add single-page/*.pdf | ||
git commit -m "Code generated by SinglePageDocGenerator.py" | ||
|