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
# TexPublish - Preparing LaTeX Projects for Publication with Ease | |
# URL: https://gist.github.com/samuelsaari/07cfff92e157fad84cd9d1988e108d95 | |
# Author: Miika Mäki https://github.com/samuelsaari | |
# - creates a new directory for publishable files | |
# - copies files matching user defined regular expressions to the new directory | |
# - copies all desired files that are used by the main tex document (like figures and tables) | |
# - creates a parsed bibliography that includes only entries used by the main tex file | |
# - flattens the tex file (inserts \input and \include commands and custom preambles in the main tex file) | |
# - pastes the parsed bibliography to the flattened tex file if desired |
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
#!/bin/bash | |
## I used cfxr to create a coin sound. afplay is an OS X command line sound playback tool. | |
DING='afplay -v .01 /mixed\ media/music/cfxr\ coin.wav' | |
## Silence the ding. | |
# DING='' | |
## Simple continuous ding with draft mode followed by a batch mode run which actually generates the PDF. | |
## Copies the PDF with the suffix -copy.pdf, so that live-updating PDF viewers don't choke trying to load the PDF while it is still being written. | |
### We can't distinguish between the first time latexmk launches the viewer regardless of changes and later launches of the viewer with changes. |
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
param ( | |
[string]$NewWorkDir = $( Read-Host 'New work dir' ), | |
[string]$Branch = $( Read-Host 'Branch' ) | |
) | |
$gitDir = git rev-parse --git-dir | |
if (!$gitDir) { | |
exit 128 | |
} |
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
#!/bin/bash | |
# store the current dir | |
CUR_DIR=$(pwd) | |
# Let the person running the script know what's going on. | |
echo "\n\033[1mPulling in latest changes for all repositories...\033[0m\n" | |
# Find all git repositories and update it to the master latest revision | |
for i in $(find . -name ".git" | cut -c 3-); do |