Skip to content

Commit

Permalink
Merge pull request #24 from oschwartz10612/new-dlls
Browse files Browse the repository at this point in the history
Add new dlls for 21.08.0 and add test package workflow
  • Loading branch information
Owen Schwartz authored Aug 27, 2021
2 parents 7118e0b + 367e1e8 commit bd7c67d
Show file tree
Hide file tree
Showing 4 changed files with 69 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@ name: Package For Windows

on:
push:
branches:
- master
tags:
- 'v*'

jobs:
package:
name: Package
name: Package Release
runs-on: windows-latest
steps:
- name: Checkout Repo
Expand Down
55 changes: 55 additions & 0 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Package Test

on:
pull_request:
types: [ synchronize ]

jobs:
package:
name: Test
runs-on: windows-latest
steps:
- name: Checkout Repo
uses: actions/checkout@master
- name: Setup Miniconda
uses: conda-incubator/setup-miniconda@v2
- name: Install Poppler
shell: bash -l {0}
run: conda install -c conda-forge poppler -y
- name: Run Package Script
shell: bash -l {0}
run: ./package.sh
env:
PKGS_PATH_DIR: /c/Users/runneradmin/conda_pkgs_dir

- name: Test pdfattach
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdfattach.exe D:\a\poppler-windows\poppler-windows\sample.pdf D:\a\poppler-windows\poppler-windows\sample.pdf test.pdf
- name: Test pdfdetach
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdfdetach.exe -list D:\a\poppler-windows\poppler-windows\sample.pdf
- name: Test pdffonts
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdffonts.exe -v
- name: Test pdfimages
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdfimages.exe -v
- name: Test pdfinfo
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdfinfo.exe -v
- name: Test pdftocairo
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdftocairo.exe -v
- name: Test pdftohtml
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdftohtml.exe -v
- name: Test pdftoppm
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdftoppm.exe -v
- name: Test pdftops
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdftops.exe -v
- name: Test pdftotext
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdftotext.exe -v
- name: Test pdfunite
run: D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }}\Library\bin\pdfunite.exe -v

- name: Zip Release
run: Compress-Archive D:\a\poppler-windows\poppler-windows\poppler-${{ env.POPPLER_VERSION }} Release-${{ env.POPPLER_VERSION }}.zip
shell: pwsh
- name: Upload Artifact
uses: actions/upload-artifact@v2
with:
name: Poppler-${{ env.POPPLER_VERSION }}
path: D:\a\poppler-windows\poppler-windows\Release-${{ env.POPPLER_VERSION }}.zip
11 changes: 11 additions & 0 deletions package.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
POPPLER_VERSION=21.08.0
POPPLER_DATA_URL="https://poppler.freedesktop.org/poppler-data-0.4.10.tar.gz"

set -e
set -o pipefail

mkdir "poppler-$POPPLER_VERSION"
cd "poppler-$POPPLER_VERSION" || exit

Expand All @@ -17,6 +20,14 @@ cp "$PKGS_PATH_DIR"/openssl*/Library/bin/libcrypto-1_1-x64.dll ./Library/bin/
cp "$PKGS_PATH_DIR"/openjpeg*/Library/bin/openjp2.dll ./Library/bin/
cp "$PKGS_PATH_DIR"/xz*/Library/bin/liblzma.dll ./Library/bin/
cp "$PKGS_PATH_DIR"/cairo*/Library/bin/cairo.dll ./Library/bin/
cp "$PKGS_PATH_DIR"/libdeflate*/Library/bin/libdeflate.dll ./Library/bin/
cp "$PKGS_PATH_DIR"/lerc*/Library/bin/Lerc.dll ./Library/bin/
cp "$PKGS_PATH_DIR"/jbig*/Library/bin/jbig.dll ./Library/bin/
cp "$PKGS_PATH_DIR"/lcms2*/Library/bin/lcms2.dll ./Library/bin/
cp "$PKGS_PATH_DIR"/libxml2*/Library/bin/libxml2.dll ./Library/bin/
cp -a "$PKGS_PATH_DIR"/libiconv*/Library/bin/. ./Library/bin/

rm -rf "$PKGS_PATH_DIR"

mkdir -p share/poppler
cd share || exit
Expand Down
Binary file added sample.pdf
Binary file not shown.

0 comments on commit bd7c67d

Please sign in to comment.