Created
September 8, 2017 16:55
-
-
Save adujardin/d9d86e3fd5aaf6a02b2751b8f25cf7ad to your computer and use it in GitHub Desktop.
Bitbucket pipeline file for latex document (including bibtex and upload to dropbox)
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
# SETTING UP : | |
# Generate an application token for your dropbox account and set it as environment variable named "DROPBOX_TOKEN" | |
# - https://blogs.dropbox.com/developers/2014/05/generate-an-access-token-for-your-own-account/ | |
# - https://confluence.atlassian.com/bitbucket/environment-variables-794502608.html | |
# Edit TEX_FILE (see below) according to the main tex file name | |
image: fermiumlabs/latex-docker:latest | |
pipelines: | |
custom: # Manually only | |
compile: # And upload artefact | |
- step: | |
script: | |
- curl "https://raw.githubusercontent.com/andreafabrizi/Dropbox-Uploader/master/dropbox_uploader.sh" -o dropbox_uploader.sh | |
- chmod +x dropbox_uploader.sh ; echo "OAUTH_ACCESS_TOKEN=$DROPBOX_TOKEN" > .dropbox_uploader | |
- TEX_FILE=Main | |
- pdflatex "$TEX_FILE.tex" && bibtex "$TEX_FILE" && pdflatex "$TEX_FILE.tex" && pdflatex "$TEX_FILE.tex" | |
- ./dropbox_uploader.sh -f .dropbox_uploader upload "$TEX_FILE.pdf" . |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment