adds action to convert images in PRs #9
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: Convert Images | |
on: | |
pull_request: | |
types: [opened, synchronize] | |
push: | |
branches: | |
- '*' | |
permissions: | |
actions: read | |
checks: read | |
contents: read | |
deployments: none | |
issues: read | |
packages: none | |
pull-requests: read | |
repository-projects: none | |
security-events: none | |
statuses: none | |
jobs: | |
build: | |
runs-on: 'ubuntu-latest' | |
name: Convert Images | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Dependencies | |
run: | | |
sudo apt-get update | |
sudo add-apt-repository universe | |
sudo add-apt-repository ppa:inkscape.dev/stable | |
sudo apt-get update | |
sudo apt install inkscape | |
sudo apt install build-essential libpng-dev | |
git clone --recursive https://github.com/kornelski/pngquant.git | |
cd pngquant | |
cmake . | |
make | |
sudo make install | |
cd .. | |
pngquant --version | |
sudo apt install imagemagick | |
shell: bash | |
- name: Run convert images | |
run: ./convert.sh | |
shell: bash |