unipdf/.travis/build_examples.sh
Adrian-George Bostan 7406957200 Add Travis CI integration (#162)
* Add Travis integration
* Improve Travis build_examples script
* Use local unipdf package when building examples
2019-09-03 08:46:25 +00:00

14 lines
374 B
Bash
Executable File

#!/usr/bin/env bash
repo_path="$HOME/projects/unipdf-examples"
git clone https://github.com/unidoc/unipdf-examples.git $repo_path
cd $repo_path
branch_name="v3"
if [[ `git ls-remote origin "$TRAVIS_BRANCH"` ]]; then
branch_name="$TRAVIS_BRANCH"
fi
git checkout $branch_name
echo "replace github.com/unidoc/unipdf/v3 => $TRAVIS_BUILD_DIR" >> go.mod
./build_examples.sh