Instruction stringlengths 14 778 | input_code stringlengths 0 4.24k | output_code stringlengths 1 5.44k |
|---|---|---|
Correct order of copying "resources" files | mkdir -p ./data/$1/outputs/tex
mkdir -p ./data/$1/inputs/md
mkdir -p ./data/$1/outputs/report
cp ./data/$1/resources/fui/fui-kompendium-blue.pdf ./data/$1/outputs/report/ifi-kompendium-forside-bm.pdf
cp ./data/$1/resources/ifikompendium/ifikompendium.tex ./data/$1/outputs/report
cp ./data/$1/resources/ifikompendium/ifi... | mkdir -p ./data/$1/outputs/tex
mkdir -p ./data/$1/inputs/md
mkdir -p ./data/$1/outputs/report
if [ ! -d ./data/$1/resources ]; then
cp -r ./resources ./data/$1/resources
fi
cp ./data/$1/resources/fui/fui-kompendium-blue.pdf ./data/$1/outputs/report/ifi-kompendium-forside-bm.pdf
cp ./data/$1/resources/ifikompendium/... |
Fix permissions (transfer ownership from root to cmbuild) | #!/bin/sh
# Initialize ccache if needed
if [ ! -f /srv/ccache/CACHEDIR.TAG ]; then
CCACHE_DIR=/srv/ccache ccache -M 50G
fi
# Fix console permissions as long as https://github.com/docker/docker/issues/9806 is not fixed
usermod --groups tty --append cmbuild
chgrp tty /dev/console
chmod g+rw /dev/console
su -c "cd /ho... | #!/bin/sh
# Initialize ccache if needed
if [ ! -f /srv/ccache/CACHEDIR.TAG ]; then
CCACHE_DIR=/srv/ccache ccache -M 50G
fi
# Fix permissions. This is needed temporarily to migrate old projects which were still checked out as root.
# It can be removed at some point in the future.
# For performance reasons, only searc... |
Copy the helper scripts to the undercloud | #!/bin/bash
set -eux
set -o pipefail
if [ ! -f /.dockerenv ]; then
echo "This must be run within a docker container";
exit 0;
fi
dt="$(date "+%Y-%m-%d_%H-%M_%s")";
echo "Running quickstart";
URL=$1;
bash ~/clean.sh;
source openrc.sh;
rm -rf ~/reproduce/ && mkdir ~/reproduce;
WORKSPACE=~/reproduce/
rm -f ... | #!/bin/bash
set -eux
set -o pipefail
if [ ! -f /.dockerenv ]; then
echo "This must be run within a docker container";
exit 0;
fi
dt="$(date "+%Y-%m-%d_%H-%M_%s")";
echo "Running quickstart";
URL=$1;
bash ~/clean.sh;
source openrc.sh;
rm -rf ~/reproduce/ && mkdir ~/reproduce;
WORKSPACE=~/reproduce/
rm -f ... |
Add git fetch all prune alias | if command -v hub &>/dev/null; then
# hub
function git(){hub "$@"}
fi
# git
alias g=git
alias gst='git status -sb'
alias gp='git push'
alias gpo='gp origin master'
alias gps='gp stage'
alias gd='git diff'
alias gdc='git diff --cached'
alias ga='git add'
alias gcl='git config --list'
alias gc='git commit -v'
alias ... | if command -v hub &>/dev/null; then
# hub
function git(){hub "$@"}
fi
# git
alias g=git
alias gst='git status -sb'
alias gp='git push'
alias gpo='gp origin master'
alias gps='gp stage'
alias gd='git diff'
alias gdc='git diff --cached'
alias ga='git add'
alias gcl='git config --list'
alias gc='git commit -v'
alias ... |
Allow to pass parameters to rubocop | function rubocop_changed_in_branch() {
rubocop `git_files_changed_vs_origin_master` || return $?
}
| function rubocop_changed_in_branch() {
rubocop $@ `git_files_changed_vs_origin_master` || return $?
}
|
Move only exiftool to lib folder | #!/bin/bash
mkdir tmp
pushd tmp
wget http://www.sno.phy.queensu.ca/~phil/exiftool/Image-ExifTool-10.02.tar.gz
gzip -dc Image-ExifTool-10.02.tar.gz | tar -xf -
pushd Image-ExifTool-10.02
perl Makefile.PL
make test
make PREFIX=. install
cp exiftool ../exiftool
cp lib ../lib -r
popd
rm tmp -rf
rm Image-ExifTool-10.02* -rf... | #!/bin/bash
mkdir tmp
pushd tmp
wget http://www.sno.phy.queensu.ca/~phil/exiftool/Image-ExifTool-10.02.tar.gz
gzip -dc Image-ExifTool-10.02.tar.gz | tar -xf -
pushd Image-ExifTool-10.02
perl Makefile.PL
make test
make PREFIX=. install
cp exiftool ../lib/exiftool
# cp lib ../lib -r
popd
rm tmp -rf
rm Image-ExifTool-10.0... |
Configure OpenSSL version for Ruby compilation | #!/usr/bin/env sh
if [ -d "${HOME}/.rbenv" ] ; then
PATH="${PATH}:${HOME}/.rbenv/bin"
fi
if which rbenv &>/dev/null ; then
PATH="${PATH}:$(rbenv prefix)/bin"
eval "$(rbenv init -)"
fi
if [ -d "${HOME}/.rbenv/plugins/ruby-build" ] ; then
PATH="${PATH}:${HOME}/.rbenv/plugins/ruby-build/bin"
fi
| #!/usr/bin/env sh
if [ -d "${HOME}/.rbenv" ] ; then
PATH="${PATH}:${HOME}/.rbenv/bin"
fi
if which rbenv &>/dev/null ; then
PATH="${PATH}:$(rbenv prefix)/bin"
eval "$(rbenv init -)"
fi
if [ -d "${HOME}/.rbenv/plugins/ruby-build" ] ; then
PATH="${PATH}:${HOME}/.rbenv/plugins/ruby-build/bin"
if which brew >/... |
Test first, build docs later. Faster test feedback from hudson. | # $WORKSPACE
# $JOB_NAME
echo
echo
echo Building MarineMap docs : revision $MERCURIAL_REVISION
echo
echo
python build_docs.py -d /var/www/marinemap-docs -j /usr/local/jsdoc-toolkit-read-only/jsdoc-toolkit
echo
echo
echo Testing MarineMap : revision $MERCURIAL_REVISION
echo
echo
coverage run run_tests.py
echo
e... | # $WORKSPACE
# $JOB_NAME
echo
echo
echo Testing MarineMap : revision $MERCURIAL_REVISION
echo
echo
coverage run run_tests.py
echo
echo
echo Building MarineMap docs : revision $MERCURIAL_REVISION
echo
echo
python build_docs.py -d /var/www/marinemap-docs -j /usr/local/jsdoc-toolkit-read-only/jsdoc-toolkit
echo
e... |
Use 4-space indent in shellscript | #!/bin/bash
set -e
wrap () {
COLUMNS=$(tput cols || echo 80)
echo "$@" | fmt -w $((COLUMNS - 5))
}
cd "${0%/*}"
if [[ ! -d venv ]]; then
echo "First run; creating virtual environment..."
wrap "Using ${PYTHON_EXE:="$(which python3)"} as the Python interpreter. Set the PYTHON_EXE variable to use a different P... | #!/bin/bash
set -e
wrap () {
COLUMNS=$(tput cols || echo 80)
echo "$@" | fmt -w $((COLUMNS - 5))
}
cd "${0%/*}"
if [[ ! -d venv ]]; then
echo "First run; creating virtual environment..."
wrap "Using ${PYTHON_EXE:="$(which python3)"} as the Python interpreter. Set the PYTHON_EXE variable to use a dif... |
Fix seednode uninstallation script paths | #!/bin/sh
service bitcoin stop
service bisq stop
userdel bisq
rm -rf /root/bisq
userdel bitcoin
rm -rf /bitcoin
| #!/bin/sh
echo "[*] Uninstalling Bitcoin and Bisq, will delete all data!!"
sudo rm -rf /root/bisq
sudo systemctl stop bitcoin
sudo systemctl stop bisq
sudo systemctl disable bitcoin
sudo systemctl disable bisq
sleep 10
sudo userdel -f -r bisq
sleep 10
sudo userdel -f -r bitcoin
echo "[*] Done!"
|
Exit if result code is non zero | #! /bin/sh
project="ci-build"
echo "Attempting to build $project for Windows"
/Applications/Unity/Unity.app/Contents/MacOS/Unity \
-batchmode \
-nographics \
-silent-crashes \
-logFile $(pwd)/unity.log \
-projectPath $(pwd) \
-buildWindowsPlayer "$(pwd)/Build/windows/$project.exe" \
-quit
echo "Attempt... | #! /bin/sh
project="ci-build"
echo "Attempting to build $project for Windows"
/Applications/Unity/Unity.app/Contents/MacOS/Unity \
-batchmode \
-nographics \
-silent-crashes \
-logFile $(pwd)/unity.log \
-projectPath $(pwd) \
-buildWindowsPlayer "$(pwd)/Build/windows/$project.exe" \
-quit
rc=$?; if [[ $... |
Enable pa11ycrawler on pull requests. It will only fail the build if it totally breaks. | #!/usr/bin/env bash
set -e
###############################################################################
#
# Usage:
# To run just tests, without pa11ycrawler:
# ./scripts/accessibility-tests.sh
#
# To run tests, followed by pa11ycrawler:
# RUN_PA11YCRAWLER=1 ./scripts/accessibility-tests.sh
#
#######... | #!/usr/bin/env bash
set -e
###############################################################################
#
# Usage:
# To run just tests, without pa11ycrawler:
# ./scripts/accessibility-tests.sh
#
# To run tests, followed by pa11ycrawler:
# RUN_PA11YCRAWLER=1 ./scripts/accessibility-tests.sh
#
#######... |
Use `git config core.editor` for old version of git 1.7.1 | #!/bin/bash
if [ $# -eq 0 ]; then
echo "Usage: $0 keep_commit_count" 1>&2
exit 1
fi
# Number of commits to keep (default: 3)
keep_commits=$1
# Calculate the end commit index
old_commits=`git log --pretty=oneline | wc -l`
end=$(($old_commits - 1 - $keep_commits))
if [ $end -lt 2 ]; then
echo "No need to squash" ... | #!/bin/bash
if [ $# -eq 0 ]; then
echo "Usage: $0 keep_commit_count" 1>&2
exit 1
fi
# Number of commits to keep (default: 3)
keep_commits=$1
# Calculate the end commit index
old_commits=`git log --pretty=oneline | wc -l`
end=$(($old_commits - 1 - $keep_commits))
if [ $end -lt 2 ]; then
echo "No need to squash" ... |
Kill caffeinate at the end of script execution | if [ "$FUNCTIONS_LOADED" != 'TRUE' ]; then
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
source "${DIR}/../functions.sh"
fi
cleanup_brew() {
brew cleanup --force
rm -rf "$(brew --cache)"
}
final_message() {
clear
echo "All the automated scripts have now finished."
echo "Dotfiles ... | if [ "$FUNCTIONS_LOADED" != 'TRUE' ]; then
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
source "${DIR}/../functions.sh"
fi
cleanup_brew() {
brew cleanup --force
rm -rf "$(brew --cache)"
}
final_message() {
clear
echo "All the automated scripts have now finished."
echo "Dotfiles ... |
Upgrade to mariadb 10.3 on travis | #!/bin/sh
remove_mysql(){
service mysql stop
apt-get -qq autoremove --purge mysql-server mysql-client mysql-common
rm -rf /etc/mysql||true
rm -rf /var/lib/mysql||true
}
remove_mysql
service mysql stop
apt-get install python-software-properties
apt-key adv --recv-keys --keyserver hkp://keyserver.ubun... | #!/bin/sh
remove_mysql(){
service mysql stop
apt-get -qq autoremove --purge mysql-server mysql-client mysql-common
rm -rf /etc/mysql||true
rm -rf /var/lib/mysql||true
}
remove_mysql
service mysql stop
apt-get install software-properties-common
apt-key adv --recv-keys --keyserver hkp://keyserver.ubun... |
Fix gopath which was pointing to the Godeps folder | #!/bin/bash
set -v
# Set Environment
echo ${PATH} | grep -q "${HOME}/bin" || {
echo "Adding ${HOME}/bin to PATH"
export PATH="${PATH}:${HOME}/bin"
}
# Install Go 1.5
mkdir -p ~/bin
curl -sL -o ~/bin/gimme https://raw.githubusercontent.com/travis-ci/gimme/master/gimme
chmod +x ~/bin/gimme
eval "$(gimme 1.5)"
# p... | #!/bin/bash
set -v
# Set Environment
echo ${PATH} | grep -q "${HOME}/bin" || {
echo "Adding ${HOME}/bin to PATH"
export PATH="${PATH}:${HOME}/bin"
}
# Install Go 1.5
mkdir -p ~/bin
curl -sL -o ~/bin/gimme https://raw.githubusercontent.com/travis-ci/gimme/master/gimme
chmod +x ~/bin/gimme
eval "$(gimme 1.5)"
# p... |
Add shortcut for easier Git backpedalling |
# Global aliases
alias l='ls -alh'
alias g='git status'
alias u='pbpaste | uglifyjs --mangle 2>/dev/null | pbcopy'
alias strip-meta='exiftool $@ "-All=" -overwrite_original'
# Global function for full-screening the terminal window.
fit(){
# Make sure we're running interactively.
[[ $- == *i* ]] && {
osascript -e... |
# Global aliases
alias l='ls -alh'
alias g='git status'
alias u='pbpaste | uglifyjs --mangle 2>/dev/null | pbcopy'
alias strip-meta='exiftool $@ "-All=" -overwrite_original'
alias fuck-this-shit='git reset --hard HEAD; git clean -fd'
# Global function for full-screening the terminal window.
fit(){
# Make sure we're... |
Add a bindkey for autosuggestion | # ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=#ff00ff,bg=cyan,bold,underline"
ZSH_AUTOSUGGEST_STRATEGY=(completion history)
| # ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=#ff00ff,bg=cyan,bold,underline"
ZSH_AUTOSUGGEST_STRATEGY=(completion history)
bindkey "^Y" autosuggest-accept
#bindkey autosuggest-execute
#bindkey autosuggest-clear
#bindkey autosuggest-fetch
#bindkey autosuggest-disable
#bindkey autosuggest-enable
#bindkey autosuggest-toggle
|
Set up global git ignore file | #!/bin/bash
#set name and email
git config --global user.name "Alan Christianson"
git config --global user.email "git@c10n.net"
| #!/bin/bash
SRC_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
#set name and email
git config --global user.name "Alan Christianson"
git config --global user.email "git@c10n.net"
# set up global gitignore
ln -s $SRC_DIR/gitignore_global ~/.gitignore_global
git config --global core.excludesfile ~/.gitignore_glo... |
Revert "git push and run" | #!/bin/sh
if [ $TRAVIS_PULL_REQUEST != "false" ]; then
echo "Testing pull request"
gulp buildAndTest
elif [ $TRAVIS_BRANCH = "master" ]; then
echo "Testing and deploying to production"
# Add deploy ssh key
eval "$(ssh-agent -s)" #start the ssh agent
ssh-add .travis/id_rsa
gulp cd:pushAndRun
elif [ $TR... | #!/bin/sh
if [ $TRAVIS_PULL_REQUEST != "false" ]; then
echo "Testing pull request"
gulp buildAndTest
elif [ $TRAVIS_BRANCH = "master" ]; then
echo "Testing and deploying to production"
# Add deploy ssh key
eval "$(ssh-agent -s)" #start the ssh agent
ssh-add .travis/id_rsa
gulp cd
elif [ $TRAVIS_BRANCH... |
Remove .init hack and fix media acces right | #!/bin/bash
SCRIPT_DIR="$(dirname "$0")"
source "$SCRIPT_DIR/app_base.sh"
# django init
python $manage wait-for-db
python $manage syncdb --noinput
python $manage migrate --noinput
python $manage bower_install -- --allow-root
python $manage collectstatic --noinput
if [ ! -f .init ]; then
chown -R www-data:www-dat... | #!/bin/bash
SCRIPT_DIR="$(dirname "$0")"
source "$SCRIPT_DIR/app_base.sh"
# django init
python $manage wait-for-db
python $manage syncdb --noinput
python $manage migrate --noinput
python $manage bower_install -- --allow-root
python $manage collectstatic --noinput
# timeside setup
python $manage timeside-create-admin... |
Switch to sphinx=1.5.1 for py3.6 support | #!/bin/bash
CONDA_INSTALL="conda install -q -y"
PIP_INSTALL="pip install -q"
# Deactivate any environment
set +v
source deactivate
set -v
# Display root environment (for debugging)
conda list
# Clean up any left-over from a previous build
# (note workaround for https://github.com/conda/conda/issues/2679:
# `conda en... | #!/bin/bash
CONDA_INSTALL="conda install -q -y"
PIP_INSTALL="pip install -q"
# Deactivate any environment
set +v
source deactivate
set -v
# Display root environment (for debugging)
conda list
# Clean up any left-over from a previous build
# (note workaround for https://github.com/conda/conda/issues/2679:
# `conda en... |
Remove -only-exposed from docker-gen statement so that it will pick up containers on internal networks | #!/bin/bash
# SIGTERM-handler
term_handler() {
[[ -n "$docker_gen_pid" ]] && kill $docker_gen_pid
[[ -n "$letsencrypt_service_pid" ]] && kill $letsencrypt_service_pid
source /app/functions.sh
remove_all_location_configurations
exit 143; # 128 + 15 -- SIGTERM
}
trap 'term_handler' INT QUIT KILL T... | #!/bin/bash
# SIGTERM-handler
term_handler() {
[[ -n "$docker_gen_pid" ]] && kill $docker_gen_pid
[[ -n "$letsencrypt_service_pid" ]] && kill $letsencrypt_service_pid
source /app/functions.sh
remove_all_location_configurations
exit 143; # 128 + 15 -- SIGTERM
}
trap 'term_handler' INT QUIT KILL T... |
Add check if user is root | #!/bin/bash
usage()
{
cat << EOF
usage: $0 options
This script creates and sets up VM.
OPTIONS:
-h Show this message
-i IP for server
-n hostName for server
EOF
}
HOSTNAME=
IP=
while getopts “hn:i:” OPTION
do
case $OPTION in
h)
usage
exit 1
... | #!/bin/bash
if [ "$(id -u)" == "0" ]; then
echo "This script must be run as user" 1>&2
exit 1
fi
sudo
usage()
{
cat << EOF
usage: $0 options
This script creates and sets up VM.
OPTIONS:
-h Show this message
-i IP for server
-n hostName for server
EOF
}
HOSTNAME=
IP=
while getopts ... |
Add some debugging to the sass compilation script. | #!/bin/bash
LIBSASS_VERSION="3.3.4"
SASSC_VERSION="3.3.4"
SASS_LIBSASS_PATH="$(pwd)/libsass"
git clone git@github.com:sass/libsass.git
cd libsass
git checkout ${LIBSASS_VERSION}
cd ../
git clone https://github.com/sass/sassc.git
cd sassc
git checkout ${SASSC_VERSION}
make && make install
| #!/bin/bash
set -ex
LIBSASS_VERSION="3.3.4"
SASSC_VERSION="3.3.4"
SASS_LIBSASS_PATH="$(pwd)/libsass"
git clone git@github.com:sass/libsass.git
cd libsass
git checkout ${LIBSASS_VERSION}
cd ../
git clone https://github.com/sass/sassc.git
cd sassc
git checkout ${SASSC_VERSION}
make && make install
|
Initialize the submodules instead of update them. | function die()
{
echo "${@}"
exit 1
}
# Add <strong>.old</strong> to any existing Vim file in the home directory
for i in $HOME/.vim $HOME/.vimrc $HOME/.gvimrc; do
if [[ ( -e $i ) || ( -h $i ) ]]; then
echo "${i} has been renamed to ${i}.old"
mv "${i}" "${i}.old" || die "Could not move ${i} to ${i}.o... | function die()
{
echo "${@}"
exit 1
}
# Add <strong>.old</strong> to any existing Vim file in the home directory
for i in $HOME/.vim $HOME/.vimrc $HOME/.gvimrc; do
if [[ ( -e $i ) || ( -h $i ) ]]; then
echo "${i} has been renamed to ${i}.old"
mv "${i}" "${i}.old" || die "Could not move ${i} to ${i}.o... |
Remove extraneous ';' on closing 'extern "C"' | #!/bin/sh
objroot=$1
cat <<EOF
#ifndef JEMALLOC_H_
#define JEMALLOC_H_
#ifdef __cplusplus
extern "C" {
#endif
EOF
for hdr in jemalloc_defs.h jemalloc_rename.h jemalloc_macros.h \
jemalloc_protos.h jemalloc_typedefs.h jemalloc_mangle.h ; do
cat "${objroot}include/jemalloc/${hdr}" \
| grep -v 'Gene... | #!/bin/sh
objroot=$1
cat <<EOF
#ifndef JEMALLOC_H_
#define JEMALLOC_H_
#ifdef __cplusplus
extern "C" {
#endif
EOF
for hdr in jemalloc_defs.h jemalloc_rename.h jemalloc_macros.h \
jemalloc_protos.h jemalloc_typedefs.h jemalloc_mangle.h ; do
cat "${objroot}include/jemalloc/${hdr}" \
| grep -v 'Gene... |
Upgrade Java 11 version in CI image | #!/bin/bash
set -e
case "$1" in
java8)
echo "https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u322-b06/OpenJDK8U-jdk_x64_linux_hotspot_8u322b06.tar.gz"
;;
java11)
echo "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.14%2B9/OpenJDK11U-jdk_x64_linux_hotspot_11.0.14_... | #!/bin/bash
set -e
case "$1" in
java8)
echo "https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u322-b06/OpenJDK8U-jdk_x64_linux_hotspot_8u322b06.tar.gz"
;;
java11)
echo "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.14.1%2B1/OpenJDK11U-jdk_x64_linux_hotspot_11.0.1... |
Fix docker config custom env copy | #!/bin/sh
set -e
# Populate config directory
if [ -z "$(ls -A /config)" ]; then
cp /app/support/docker/production/config/* /config
fi
# Always copy default and custom env configuration file, in cases where new keys were added
cp /app/config/default.yaml /config
cp /app/config/custom-environment-variables.yaml /co... | #!/bin/sh
set -e
# Populate config directory
if [ -z "$(ls -A /config)" ]; then
cp /app/support/docker/production/config/* /config
fi
# Always copy default and custom env configuration file, in cases where new keys were added
cp /app/config/default.yaml /config
cp /app/support/docker/production/config/custom-envi... |
Switch to use boost 1.80.0 | mkdir third_party_sources ||:
cd third_party_sources
git clone --branch v1.2.9 https://github.com/madler/zlib.git
wget https://boostorg.jfrog.io/artifactory/main/release/1.76.0/source/boost_1_76_0.tar.gz
tar zxvf boost_1_76_0.tar.gz
mv boost_1_76_0 boost
rm boost_1_76_0.tar.gz
wget https://github.com/postgres/postgre... | mkdir third_party_sources ||:
cd third_party_sources
git clone --branch v1.2.9 https://github.com/madler/zlib.git
wget https://boostorg.jfrog.io/artifactory/main/release/1.80.0/source/boost_1_80_0.tar.gz
tar zxvf boost_1_80_0.tar.gz
mv boost_1_80_0 boost
rm boost_1_80_0.tar.gz
wget https://github.com/postgres/postgre... |
Set bash as default shell to get tab autocompletion working at SSH login | #!/bin/sh
# Create user with given user name and add it the group of sudoers.
# The password of the new user is disabled.
#
# Parameters:
# $1 - string, user name of the new user
# $2 - optional, string, name of the group of sudoers, defaults to 'sudo'
#
# Note:
# If the user exists already, it is left unchanged.
u... | #!/bin/sh
# Create user with given user name and add it the group of sudoers.
# The password of the new user is disabled.
#
# Parameters:
# $1 - string, user name of the new user
# $2 - optional, string, name of the group of sudoers, defaults to 'sudo'
#
# Note:
# If the user exists already, it is left unchanged.
u... |
Make cron job not fail because broken links | #!/bin/bash
cd "$(dirname "${BASH_SOURCE[0]}")/.." \
|| exit 1
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
./.travis/is-master.sh \
|| exit 0
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
gem install awesome_bot \
&& find . -name "*.md" \
... | #!/bin/bash
cd "$(dirname "${BASH_SOURCE[0]}")/.." \
|| exit 1
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
./.travis/is-master.sh \
|| exit 0
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
gem install awesome_bot \
&& find . -name "*.md" \
... |
Fix error on CentOS 7 | yum -y erase gtk2 libX11 hicolor-icon-theme freetype bitstream-vera-fonts
yum -y clean all
# Remove traces of mac address from network configuration
sed -i /HWADDR/d /etc/sysconfig/network-scripts/ifcfg-eth0
rm -f /etc/udev/rules.d/70-persistent-net.rules
| yum -y erase gtk2 libX11 hicolor-icon-theme freetype bitstream-vera-fonts
yum -y clean all
# Remove traces of mac address from network configuration
sed -i /HWADDR/d /etc/sysconfig/network-scripts/ifcfg-eth0
rm -f /etc/udev/rules.d/70-persistent-net.rules
# Since there is no MAC address anymore, we need to identify t... |
Fix Powerline font installer script | #!/bin/sh
if [[ -f $HOME/.env/powerline ]]; then
echo "Looks like Powerline fonts have already been installed. Bye."
exit 0
fi
echo "Installing Powerline fonts..."
if [[ ! -d $HOME/fonts ]]; then
git clone https://github.com/powerline/fonts.git --depth=1
# Run the installer:
cd fonts; ./install.sh
# Touch a... | #!/bin/sh
if [[ -f $HOME/.env/powerline ]]; then
echo "Looks like Powerline fonts have already been installed. Bye."
exit 0
fi
echo "Installing Powerline fonts..."
if [[ ! -d $HOME/fonts ]]; then
cd $HOME
git clone https://github.com/powerline/fonts.git --depth=1
# Run the installer:
cd fonts; ./install.sh;... |
Make sure errors get propogated. | #! /bin/sh
#
# Drive HTML generation for a Python manual.
#
# This is probably *not* useful outside of the standard Python documentation.
#
# The first arg is required and is the designation for which manual to build;
# api, ext, lib, ref, or tut. All other args are passed on to latex2html.
WORKDIR=`pwd`
cd `dirname ... | #! /bin/sh
#
# Drive HTML generation for a Python manual.
#
# This is probably *not* useful outside of the standard Python documentation,
# but suggestions are welcome and should be sent to <python-docs@python.org>.
#
# The first arg is required and is the designation for which manual to build;
# api, ext, lib, ref, or... |
Use usleep for waiting 10sec | #!/bin/bash
sleep --help
sleep 10s
if curl http://localhost:3000 | grep -q '<app-root></app-root>'; then
echo -e "\e[32mSmoke test passed!\e[0m"
exit 0
else
echo -e "\e[31mSmoke test failed!\e[0m"
exit 1
fi | #!/bin/bash
usleep 10000
if curl http://localhost:3000 | grep -q '<app-root></app-root>'; then
echo -e "\e[32mSmoke test passed!\e[0m"
exit 0
else
echo -e "\e[31mSmoke test failed!\e[0m"
exit 1
fi |
Allow passing arguments to tox. | #!/bin/sh
THIS_PATH=$0
if [ `expr $0 : '\/'` = 0 ]; then THIS_PATH="`pwd`/$THIS_PATH"; fi
THIS_DIR="`dirname $THIS_PATH`"
cd $THIS_DIR
PYTHONPATH=$THIS_DIR
export PYTHONPATH
tox
| #!/bin/sh
THIS_PATH=$0
if [ `expr $0 : '\/'` = 0 ]; then THIS_PATH="`pwd`/$THIS_PATH"; fi
THIS_DIR="`dirname $THIS_PATH`"
cd $THIS_DIR
PYTHONPATH=$THIS_DIR
export PYTHONPATH
exec tox ${1+"${@}"}
|
Install pip in galaxy virtualenv environment | cd /usr/local/galaxy/work/galaxy_in_docker_custom_bit_wf/setup_scripts
python bit-workflow_install_docker.py
| cd /usr/local/galaxy/work/galaxy_in_docker_custom_bit_wf/setup_scripts
source /usr/local/galaxy/galaxy-dist/.venv/bin/activate; pip install python-dateutil bioblend pandas grequests GitPython pip-tools
python bit-workflow_install_docker.py
|
Use build instead of install | #/bin/bash
# Set the GOPATH if it is not set or if is different when running as another user (sudo)
# export GOPATH=""
# Linux
export GOOS="linux"
export GOARCH="amd64"
echo "Compiling... (OS: $GOOS, ARCH: $GOARCH)"
go install
export GOARCH="386"
echo "Compiling... (OS: $GOOS, ARCH: $GOARCH)"
go install
# Windows... | #/bin/bash
# Set the GOPATH if it is not set or if is different when running as another user (sudo)
# export GOPATH=""
PATH_SCRIPT="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
PATH_BUILD="$GOPATH/bin/dbf_release"
mkdir -p $PATH_BUILD
# Linux
export GOOS="linux"
export GOARCH="amd64"
echo "Compiling... (OS:... |
Add PYTHONPATH to travis test script | #!/usr/bin/env bash
set -eux
python_version=$(python --version 2>&1 | cut -d ' ' -f2)
db_file=geoip_${python_version}.mmdb
python maxmindupdater/__main__.py $db_file $LICENSE_KEY GeoIP2-Country
# Ensure all python versions produce the same result (and that they actually produced a result)
for other_db_file in geoip_... | #!/usr/bin/env bash
set -eux
python_version=$(python --version 2>&1 | cut -d ' ' -f2)
db_file=geoip_${python_version}.mmdb
PYTHONPATH=`pwd`
python maxmindupdater/__main__.py $db_file $LICENSE_KEY GeoIP2-Country
# Ensure all python versions produce the same result (and that they actually produced a result)
for other_... |
Hide Jenkins's 8080 port. Expose Jenkins's 50000 port. | #!/bin/bash
set -e
JENKINS_NAME=${JENKINS_NAME:-jenkins-master}
GERRIT_NAME=${GERRIT_NAME:-gerrit}
JENKINS_IMAGE_NAME=${JENKINS_IMAGE_NAME:-openfrontier/jenkins}
LOCAL_VOLUME=~/jenkins_volume${SUFFIX}
JENKINS_OPTS=${JENKINS_OPTS:---prefix=/jenkins}
mkdir -p "${LOCAL_VOLUME}"
docker run --name ${JENKINS_NAME} --link ${... | #!/bin/bash
set -e
JENKINS_NAME=${JENKINS_NAME:-jenkins-master}
GERRIT_NAME=${GERRIT_NAME:-gerrit}
JENKINS_IMAGE_NAME=${JENKINS_IMAGE_NAME:-openfrontier/jenkins}
LOCAL_VOLUME=~/jenkins_volume${SUFFIX}
JENKINS_OPTS=${JENKINS_OPTS:---prefix=/jenkins}
mkdir -p "${LOCAL_VOLUME}"
docker run --name ${JENKINS_NAME} --link ${... |
Use minimal config for generating the help file | #!/bin/bash
# Copyright (c) Facebook, Inc. and its affiliates.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
sledge=$PWD/cli/sledge_cli.exe
line=$(\
$sledge help -recursive -expand \
| grep -n "== subcommands ===" \
| cut -d : ... | #!/bin/bash
# Copyright (c) Facebook, Inc. and its affiliates.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
sledge=$PWD/cli/sledge_cli.exe
export SLEDGE_CONFIG=$PWD/../../test/config
line=$(\
$sledge help -recursive -expand \
| g... |
Update PHP version and modules to install | #!/usr/bin/env bash
function setup_test_requirements() {
readonly LOG_FILE="/opt/easyengine/logs/install.log"
# Adding software-properties-common for add-apt-repository.
apt-get install -y software-properties-common
# Adding ondrej/php repository for installing php, this works for all ubuntu flavours.
... | #!/usr/bin/env bash
function setup_test_requirements() {
readonly LOG_FILE="/opt/easyengine/logs/install.log"
# Adding software-properties-common for add-apt-repository.
apt-get install -y software-properties-common
# Adding ondrej/php repository for installing php, this works for all ubuntu flavours.
... |
Exit 1 not Exit 0 | #!/bin/bash
# These tests will bring up a single-node Kubernetes cluster and test against examples
# WARNING: This will actively create Docker containers on your machine as well as remove them
# do not run this on a production cluster / machine.
# Check requirements!
if ! hash go 2>/dev/null; then
echo "ERROR: go ... | #!/bin/bash
# These tests will bring up a single-node Kubernetes cluster and test against examples
# WARNING: This will actively create Docker containers on your machine as well as remove them
# do not run this on a production cluster / machine.
# Check requirements!
if ! hash go 2>/dev/null; then
echo "ERROR: go ... |
Write keys from env to .s3cfg. | #!/bin/sh
cd `dirname $0`
node update.js
node liquor.js
node render.js
./node_modules/s3-cli/cli.js sync -P --region 'us-west-2' --default-mime-type 'text/html' out/ s3://www.belltowncrime.com/
./node_modules/s3-cli/cli.js put -P --region 'us-west-2' --default-mime-type 'text/css' main.css s3://www.belltowncrime.com/ma... | #!/bin/sh
cd `dirname $0`
node update.js
node liquor.js
node render.js
cat > ~/.s3cfg << EOF
[default]
access_key = $AWS_KEY_ID
secret_key = $AWS_SECRET_ACCESS_KEY
EOF
./node_modules/s3-cli/cli.js sync -P --region 'us-west-2' --default-mime-type 'text/html' out/ s3://www.belltowncrime.com/
./node_modules/s3-cli/cli.js ... |
Add chown to make sure permissions are ok | #!/bin/bash
sed -i \
-e 's/ErrorLog.*/ErrorLog \/dev\/stderr/' \
-e 's/CustomLog.*/CustomLog \/dev\/stdout combined/' \
/etc/apache2/sites-available/000-default.conf
sed -i \
-e 's/AllowOverride None/AllowOverride All/' \
/etc/apache2/apache2.conf
sed -i \
-e 's/log_errors = On/log_errors = ... | #!/bin/bash
sed -i \
-e 's/ErrorLog.*/ErrorLog \/dev\/stderr/' \
-e 's/CustomLog.*/CustomLog \/dev\/stdout combined/' \
/etc/apache2/sites-available/000-default.conf
sed -i \
-e 's/AllowOverride None/AllowOverride All/' \
/etc/apache2/apache2.conf
sed -i \
-e 's/log_errors = On/log_errors = ... |
Make container exit after generating new configuration, as noted in README | #! /bin/sh
rm -rf /var/run/*
rm -f "/config/Library/Application Support/Plex Media Server/plexmediaserver.pid"
mkdir -p /var/run/dbus
chown messagebus:messagebus /var/run/dbus
dbus-uuidgen --ensure
dbus-daemon --system --fork
sleep 1
avahi-daemon -D
sleep 1
HOME=/config start_pms &
sleep 5
tail -f /config/Library/... | #! /bin/sh
rm -rf /var/run/*
rm -f "/config/Library/Application Support/Plex Media Server/plexmediaserver.pid"
mkdir -p /var/run/dbus
chown messagebus:messagebus /var/run/dbus
dbus-uuidgen --ensure
dbus-daemon --system --fork
sleep 1
avahi-daemon -D
sleep 1
if [ -f /config/Library/Application\ Support/Plex\ Media\ ... |
Remove extra empty line after "Build YouCompleteMe" | #!/bin/bash
DOTVIM="${DOTFILES_CURRENT_SOURCE_DIR}/.vim"
BUNDLE="${DOTVIM}/bundle"
# Create .vim folder if needed
[ -d "$DOTVIM" ] && mkdir -p $DOTVIM
# Install vim vundle
dotfiles_install_remote_component GITHUB VundleVim/Vundle.vim ".vim/bundle/Vundle.vim"
# Install vim plugins
vim +PluginInstall +qall
# Install... | #!/bin/bash
DOTVIM="${DOTFILES_CURRENT_SOURCE_DIR}/.vim"
BUNDLE="${DOTVIM}/bundle"
# Create .vim folder if needed
[ -d "$DOTVIM" ] && mkdir -p $DOTVIM
# Install vim vundle
dotfiles_install_remote_component GITHUB VundleVim/Vundle.vim ".vim/bundle/Vundle.vim"
# Install vim plugins
vim +PluginInstall +qall
# Install... |
Add alias to install common node globals | alias npr="npm -s run"
alias ntr="npm -s run test --"
alias ntw="npm -s run test -- --watch"
alias lnm="find . -name "node_modules" -type d -prune"
alias nnm="find . -name "node_modules" -type d -prune -exec rm -rf '{}' +"
alias nnmi="nnm && npm i"
alias npv="node -p \"require('./package.json').version\""
alias babel-n... | alias npr="npm -s run"
alias ntr="npm -s run test --"
alias ntw="npm -s run test -- --watch"
alias lnm="find . -name "node_modules" -type d -prune"
alias nnm="find . -name "node_modules" -type d -prune -exec rm -rf '{}' +"
alias nnmi="nnm && npm i"
alias npv="node -p \"require('./package.json').version\""
alias babel-n... |
Add missing `usr` to CDT path | #!/bin/bash
mkdir -p ${PREFIX}/x86_64-conda_cos6-linux-gnu/sysroot
pushd ${PREFIX}/x86_64-conda_cos6-linux-gnu/sysroot > /dev/null 2>&1
cp -Rf "${SRC_DIR}"/binary/* .
| #!/bin/bash
mkdir -p ${PREFIX}/x86_64-conda_cos6-linux-gnu/sysroot/usr
pushd ${PREFIX}/x86_64-conda_cos6-linux-gnu/sysroot/usr > /dev/null 2>&1
cp -Rf "${SRC_DIR}"/binary/* .
|
Reduce memory limit to 50 percent | #!/bin/bash
/opt/envsubst < /envsubst_template.json > /conf/runtime.json
exec java -XX:+UseContainerSupport -XX:MaxRAMPercentage=75.0 -jar /git-bridge.jar /conf/runtime.json
| #!/bin/bash
/opt/envsubst < /envsubst_template.json > /conf/runtime.json
exec java -XX:+UseContainerSupport -XX:MaxRAMPercentage=50.0 -jar /git-bridge.jar /conf/runtime.json
|
Include a column for Raspberry Pi revision | #!/usr/bin/env bash
set -o errexit
set -o pipefail
set -o nounset
script_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
. $script_dir/config.sh
mkdir -p $output_dir
echo Sending output to $output_file
# Write headers to output file, if it does not yet exist
if [[ ! -f $output_file ]] ; then
echo Creat... | #!/usr/bin/env bash
set -o errexit
set -o pipefail
set -o nounset
script_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
. $script_dir/config.sh
mkdir -p $output_dir
echo Sending output to $output_file
# Write headers to output file, if it does not yet exist
if [[ ! -f $output_file ]] ; then
echo Creat... |
Update device ips in tmux-scripts | #!/bin/zsh
tmux new-session -s devices -n "devices" -d
tmux split-window -h -p 50
tmux send-keys "ping 10.0.0.13" Enter
tmux split-window -v -p 80
tmux send-keys "ping 10.0.0.30" Enter
tmux split-window -v -p 80
tmux send-keys "ping 10.0.0.31" Enter
tmux split-window -v -p 80
tmux send-keys "ping 10.0.0.33" Enter
tmux... | #!/bin/zsh
tmux new-session -s devices -n "devices" -d
tmux split-window -h -p 50
tmux send-keys "ping 10.0.0.40" Enter
tmux split-window -v -p 80
tmux send-keys "ping 10.0.0.41" Enter
tmux split-window -v -p 80
tmux send-keys "ping 10.0.0.42" Enter
tmux split-window -v -p 80
tmux send-keys "ping 10.0.0.43" Enter
tmux... |
Add "cabal update" to the script | #!/usr/bin/env bash
set -e
cabal sandbox init
git clone https://github.com/elm-lang/elm-compiler.git
cd elm-compiler
git checkout tags/0.15.1 --quiet
cabal sandbox init --sandbox ..
cabal install -j
cd ..
git clone https://github.com/elm-lang/elm-package.git
cd elm-package
git checkout tags/0.5.1 --quiet
cabal san... | #!/usr/bin/env bash
set -e
cabal update
cabal sandbox init
git clone https://github.com/elm-lang/elm-compiler.git
cd elm-compiler
git checkout tags/0.15.1 --quiet
cabal sandbox init --sandbox ..
cabal install -j
cd ..
git clone https://github.com/elm-lang/elm-package.git
cd elm-package
git checkout tags/0.5.1 --q... |
Add exit if variables not set | #!/bin/sh
EXECUTORS=${EXECUTORS:-1}
NAME=${NAME:-client-$(hostname)}
mkdir -p /var/jenkins
java -jar swarm-client.jar -fsroot /var/jenkins -executors ${EXECUTORS} -labels ${LABELS} -name ${NAME} -master ${MASTER} -username ${USER_NAME} -password ${USER_PASSWORD}
| #!/bin/sh
if [[ -z "${LABELS}" ]]; then
echo "LABELS must be set."
exit 1
fi
if [[ -z "${MASTER}" ]]; then
echo "MASTER must be set."
exit 1
fi
if [[ -z "${USER_NAME}" ]]; then
echo "USER_NAME must be set."
exit 1
fi
if [[ -z "${USER_PASSWORD}" ]]; then
echo "USER_PASSWORD must be set."
exit 1
fi
E... |
Add TODO note for format | #!/bin/sh -e
# Format output of alias print dump into more readable format
cat ${HOME}/.zshrc | grep -e '^alias' | awk -F'=' 'BEGIN {
print "ALIAS | COMMAND";
print "---------------------------------------";
}
{
baselen = 10;
fieldlen = length($1);
... | #!/bin/sh -e
# Format output of alias print dump into more readable format
cat ${HOME}/.zshrc | grep -e '^alias' | awk -F'=' 'BEGIN {
print "ALIAS | COMMAND";
print "---------------------------------------";
}
{
# TODO
# Specify length for both columns ... |
Fix some corner cases in test script | #!/bin/bash
if [ -z "$MAMBO_PATH" ]; then
MAMBO_PATH=/opt/ibm/systemsim-p8/
fi
if [ -z "$MAMBO_BINARY" ]; then
MAMBO_BINARY="/run/pegasus/power8"
fi
if [ ! -x "$MAMBO_PATH/$MAMBO_BINARY" ]; then
echo 'Could not find executable MAMBO_BINARY. Skipping hello_world test';
exit 0;
fi
if [ ! -x `which ex... | #!/bin/bash
if [ -z "$MAMBO_PATH" ]; then
MAMBO_PATH=/opt/ibm/systemsim-p8/
fi
if [ -z "$MAMBO_BINARY" ]; then
MAMBO_BINARY="/run/pegasus/power8"
fi
if [ ! -x "$MAMBO_PATH/$MAMBO_BINARY" ]; then
echo 'Could not find executable MAMBO_BINARY. Skipping hello_world test';
exit 0;
fi
if [ -n "$KERNEL" ]... |
Use `latest` docker images instead of `sdk` tag | #!/bin/bash
if [[ $DOCKER_IMAGE == *"i386"* ]]
then
ENTRYPOINT=linux32
COMMAND=bin/bash
else
ENTRYPOINT=bin/bash
COMMAND=
fi
if [[ $DOCKER_IMAGE == *"rpm"* ]]
then
docker run -e INTEGRATIONS_REPO=$INTEGRATIONS_REPO -e INTEGRATION=$INTEGRATION -e VERSION=$VERSION -e BUILD_ITERATION=$BUILD_ITERATION ... | #!/bin/bash
if [[ $DOCKER_IMAGE == *"i386"* ]]
then
ENTRYPOINT=linux32
COMMAND=bin/bash
else
ENTRYPOINT=bin/bash
COMMAND=
fi
if [[ $DOCKER_IMAGE == *"rpm"* ]]
then
docker run -e INTEGRATIONS_REPO=$INTEGRATIONS_REPO -e INTEGRATION=$INTEGRATION -e VERSION=$VERSION -e BUILD_ITERATION=$BUILD_ITERATION ... |
Add flow to test script | #!/usr/bin/env bash
LINT_FAIL=
TEST_FAIL=
BUILD_FAIL=
function command_exists {
local result
result="$(node -p "'$1' in require('./package.json').scripts")"
if [[ "$result" == "true" ]]; then
return 0
fi
return 1
}
function run_script_in_packages {
for pkg in packages/*; do
if [[ ! -f "$pkg/pack... | #!/usr/bin/env bash
LINT_FAIL=
TEST_FAIL=
BUILD_FAIL=
function command_exists {
local result
result="$(node -p "'$1' in require('./package.json').scripts")"
if [[ "$result" == "true" ]]; then
return 0
fi
return 1
}
function run_script_in_packages {
for pkg in packages/*; do
if [[ ! -f "$pkg/pack... |
Use 'mainline' docker for armv6 and the cached package for armv7. Strange thing. | # Args: "$@" == the minimum packages to install, e.g. docker, git
os_install(){
# Update the system and use pacman to install all the packages
# The two commands may be combined, but I leave it as is for now.
os_upgrade
# pacman -S $@ --noconfirm --needed
# Install this manually, docker v1.7.1
pacman -S bridge-... | # Args: "$@" == the minimum packages to install, e.g. docker, git
os_install(){
# Update the system and use pacman to install all the packages
# The two commands may be combined, but I leave it as is for now.
os_upgrade
# pacman -S $@ --noconfirm --needed
if [[ $MACHINE == "rpi" ]]; then
pacman -S $@ --noconfi... |
Use Service Account Key during in destroy_bosh script | #!/bin/sh -e
[ -z "$DEBUG" ] || set -x
. "$(dirname "$0")/lib/environment.sh"
set -x
export BOSH_LOG_LEVEL=debug
export BOSH_LOG_PATH="${KUBO_DEPLOYMENT_DIR}/bosh.log"
bosh-cli int kubo-lock/metadata --path=/gcp_service_account > "$PWD/key.json"
cp "kubo-lock/metadata" "${KUBO_ENVIRONMENT_DIR}/director.yml"
cp "$P... | #!/bin/sh -e
[ -z "$DEBUG" ] || set -x
. "$(dirname "$0")/lib/environment.sh"
set -x
export BOSH_LOG_LEVEL=debug
export BOSH_LOG_PATH="${KUBO_DEPLOYMENT_DIR}/bosh.log"
bosh-cli int kubo-lock/metadata --path=/gcp_service_account > "$PWD/key.json"
cp "kubo-lock/metadata" "${KUBO_ENVIRONMENT_DIR}/director.yml"
cp "$P... |
Make the build fail if a sub-component fails to build | #!/usr/bin/env bash
declare -a repositories=("zipkin4net" "zipkin4net-aspnetcore")
for i in "${repositories[@]}"; do
if [ -d $i ]; then
pushd $i
./buildAndTest.sh
popd
else
echo "Can't build $i"
exit 4
fi
done
| #!/usr/bin/env bash
declare -a repositories=("zipkin4net" "zipkin4net-aspnetcore")
for i in "${repositories[@]}"; do
if [ -d $i ]; then
pushd $i
./buildAndTest.sh
if [ $? -ne 0 ]; then
echo "Compilation of $i failed, exiting"
exit 1
fi
popd
else
echo "Can't build $i"
e... |
Change order of application of cumulus repository | echo "yes" | sudo add-apt-repository ppa:avsm/ocaml41+opam12
sudo apt-get update -qq
sudo apt-get install -qq ocaml ocaml-native-compilers camlp4-extra opam
sudo apt-get install libpcre3-dev libssl-dev
export OPAMYES=1
opam init
eval `opam config env`
case $OCSIGENSERVER3 in
true)
opam repository add cumulu... | echo "yes" | sudo add-apt-repository ppa:avsm/ocaml41+opam12
sudo apt-get update -qq
sudo apt-get install -qq ocaml ocaml-native-compilers camlp4-extra opam
sudo apt-get install libpcre3-dev libssl-dev
export OPAMYES=1
opam init
eval `opam config env`
case $OCSIGENSERVER3 in
true)
opam repository add cumulu... |
Remove some compile options for PPC | #!/bin/sh
basepath="$(cd "$(dirname "$0")" && pwd)"
builddir="$basepath/../build"
mkdir -p "$builddir"
cd "$builddir"
cmake .. -G "Unix Makefiles" -DCMAKE_CXX_FLAGS:STRING="-march=native -m64 -Ofast -flto" "$@"
| #!/bin/sh
basepath="$(cd "$(dirname "$0")" && pwd)"
builddir="$basepath/../build"
mkdir -p "$builddir"
cd "$builddir"
cmake .. -G "Unix Makefiles" -DCMAKE_CXX_FLAGS:STRING="-Ofast" "$@"
|
Add location to script call | #!/bin/sh
# Only forward if the pause file doesn't exist
if [ ! -f ./pause ]; then
python forwardNotif.py
fi
| #!/bin/bash
# Only forward if the pause file doesn't exist
if [ ! -f ${BASH_SOURCE[0]%/*}/pause ]; then
python ${BASH_SOURCE[0]%/*}/forwardNotif.py
fi
|
Add iptables rules, ntpdate setup | set -ex
apt-get install ruby rubygems ||
yum install -y ruby rubygems ||
pkgin install ruby rubygems ||
false
gem update --system
gem install facter
gem install puppet
mkdir -p /etc/puppet /var/lib /var/log /var/run
cat >/etc/puppet/puppet.conf <<EOF
[main]
logdir = /var/log/puppet
rundir = /var/run/puppet
ssl... | set -ex
# Get ruby, rubygems, and npdtae
apt-get install ruby rubygems ntpdate ||
yum install -y ruby rubygems nptdate ||
false
# Run ntpdate to ensure the system date is correct
ntpdate pool.ntpd.org
# Update rubygems, and pull down facter and then puppet
gem update --system
gem install facter
gem install puppet
m... |
Fix wd terminal prompt getting bash mixed up when doing: Up, Ctrl + A | #!/bin/bash
wd() {
./auto/with-deploytools bash -c "echo -e \"$( (cat ~/.dotfiles/kubernetes/aliases.zsh; printf 'PS1="\\n\\e[36;1m$PS1\\e[0m"') | base64)\" | base64 -d >> ~/.bashrc && bash"
}
| #!/bin/bash
wd() {
./auto/with-deploytools bash -c "echo -e \"$( (cat ~/.dotfiles/kubernetes/aliases.zsh; printf 'PS1="\\[\\n\\e[36;1m\\]$PS1\\[\\e[0m\\]"') | base64)\" | base64 -d >> ~/.bashrc && bash"
}
|
Correct path to yml settings | #!/bin/sh
java -jar target/dropwizard-example-1.0.0-SNAPSHOT.jar db migrate example.yml &
sleep 5
java -jar target/dropwizard-example-1.0.0-SNAPSHOT.jar server example.yml
wait
| #!/bin/sh
java -jar /target/dropwizard-example-1.0.0-SNAPSHOT.jar db migrate /target/example.yml &
sleep 5
java -jar /target/dropwizard-example-1.0.0-SNAPSHOT.jar server /target/example.yml
wait
|
Make the installation of linters verbose | #!/usr/bin/env bash
set -o errexit
set -o nounset
set -o pipefail
if [ ! $(command -v gometalinter) ]
then
go get github.com/alecthomas/gometalinter
gometalinter --install --vendor
fi
gometalinter \
--exclude='error return value not checked.*(Close|Log|Print).*\(errcheck\)$' \
--exclude='.*_test\.go:.*error retu... | #!/usr/bin/env bash
set -o errexit
set -o nounset
set -o pipefail
if [ ! $(command -v gometalinter) ]
then
go get github.com/alecthomas/gometalinter
gometalinter --install --vendor --debug
fi
gometalinter \
--exclude='error return value not checked.*(Close|Log|Print).*\(errcheck\)$' \
--exclude='.*_test\.go:.*er... |
Exit 1 if PID/process isn't found | # ------------------------------------------------------------------------------
# ~zozo/.config/bash/functions/pid.bash
# ------------------------------------------------------------------------------
case $OSTYPE in
cygwin) flags_pid='-asW' ;;
*) flags_pid='-cx -o pid,command' ;;
esac
pidof()
{ # r... | # ------------------------------------------------------------------------------
# ~zozo/.config/bash/functions/pid.bash
# ------------------------------------------------------------------------------
case $OSTYPE in
cygwin) flags_pid='-asW' ;;
*) flags_pid='-cx -o pid,command' ;;
esac
pidof()
{ # r... |
Implement test for not detecting play2.2 | #!/bin/sh
. ${BUILDPACK_TEST_RUNNER_HOME}/lib/test_utils.sh
testDetectWithConfFileDetectsPlayApp() {
mkdir -p ${BUILD_DIR}/play-app/conf
touch ${BUILD_DIR}/play-app/conf/application.conf
detect
assertAppDetected "Play!"
}
testDetectWithConfFileDetectsPlayApp() {
mkdir -p ${BUILD_DIR}/play-app/conf/appli... | #!/bin/sh
. ${BUILDPACK_TEST_RUNNER_HOME}/lib/test_utils.sh
testDetectWithConfFileDetectsPlayApp() {
mkdir -p ${BUILD_DIR}/play-app/conf
touch ${BUILD_DIR}/play-app/conf/application.conf
detect
assertAppDetected "Play!"
}
testDetectWithConfFileDetectsPlayApp() {
mkdir -p ${BUILD_DIR}/play-app/conf/appli... |
Copy XDebug settings to correct PHP folder | cp /vagrant/config/xdebug.ini /etc/php/7.0/mods-available/xdebug.ini
| cp /vagrant/config/xdebug.ini /etc/php/7.1/mods-available/xdebug.ini
|
Remove the `-c` xcpretty option | #!/bin/bash
set -o pipefail
: ${SCHEME:="XCDYouTubeKit iOS Static Library"}
: ${CONFIGURATION:="Release"}
: ${DESTINATION:="platform=iOS Simulator,name=iPhone 5s"}
COMMAND="env NSUnbufferedIO=YES xcodebuild clean test -project XCDYouTubeKit.xcodeproj -scheme '${SCHEME}' -configuration '${CONFIGURATION}' -destination... | #!/bin/bash
set -o pipefail
: ${SCHEME:="XCDYouTubeKit iOS Static Library"}
: ${CONFIGURATION:="Release"}
: ${DESTINATION:="platform=iOS Simulator,name=iPhone 5s"}
COMMAND="env NSUnbufferedIO=YES xcodebuild clean test -project XCDYouTubeKit.xcodeproj -scheme '${SCHEME}' -configuration '${CONFIGURATION}' -destination... |
Check that git is clean before deploying the site | #!/bin/sh
CURRENT_BRANCH=`git symbolic-ref -q HEAD | sed -e 's|^refs/heads/||'`
npm run generate-site
git fetch origin gh-pages
git checkout -B gh-pages origin/gh-pages
rm `git ls-files | grep -v '^\.gitignore$'`
if [ ! -f ".gitignore" ]; then
echo "node_modules" > .gitignore
fi
cp -r site-build/* .
if [ "`git stat... | #!/bin/sh
if [ -n "$(git describe --always --dirty | grep -- -dirty)" ]
then
echo "Working tree is dirty, please commit or stash your changes, then try again"
exit 1
fi
CURRENT_BRANCH=`git symbolic-ref -q HEAD | sed -e 's|^refs/heads/||'`
npm run generate-site
git fetch origin gh-pages
git checkout -B gh-pages ... |
Add ZSH git alias to g | alias reload!='source ~/.zshrc; rehash'
alias cls='clear'
alias less='less --quiet'
alias df='df -h'
alias du='du -hs'
alias history='fc -il 1'
alias hg='history | grep'
# Fast directory change
alias -g ..='cd ..'
alias -g ...='cd ../..'
alias -g ....='cd ../../..'
alias -g .....='cd ../../../..'
alias -g ......='cd .... | alias reload!='source ~/.zshrc; rehash'
alias cls='clear'
alias less='less --quiet'
alias df='df -h'
alias du='du -hs'
alias history='fc -il 1'
alias hg='history | grep'
alias g='git'
# Fast directory change
alias -g ..='cd ..'
alias -g ...='cd ../..'
alias -g ....='cd ../../..'
alias -g .....='cd ../../../..'
alias -... |
Add a static file serving the build's git revision | #!/bin/bash
if [ "$(tr '[:upper:]' '[:lower:]' <<<"$NODE_ENV")" = "production" ]; then
npm run build:prod
fi
exec "$@"
| #!/bin/bash
if [ "$(tr '[:upper:]' '[:lower:]' <<<"$NODE_ENV")" = "production" ]; then
npm run build:prod
git rev-parse HEAD >.build/revision
fi
exec "$@"
|
Change tmux session name to 0 | #!/bin/bash
SESSION=x
DEV_ROOT=~/dev
WORK_REPOSITORY=actano/rplan
function tmux-select {
tmux select-window -t $SESSION:$1
tmux select-pane -t $2
}
function cd_to_work {
tmux send-keys "cd $WORK_REPOSITORY" C-m
}
cd $DEV_ROOT
tmux -2 new-session -d -s $SESSION
tmux rename-window -t $SESSION:0 'rplan'
tm... | #!/bin/bash
SESSION=0
DEV_ROOT=~/dev
WORK_REPOSITORY=actano/rplan
function tmux-select {
tmux select-window -t $SESSION:$1
tmux select-pane -t $2
}
function cd_to_work {
tmux send-keys "cd $WORK_REPOSITORY" C-m
}
cd $DEV_ROOT
tmux -2 new-session -d -s $SESSION
tmux rename-window -t $SESSION:0 'rplan'
tm... |
Fix private config on OSX. | #!/bin/bash
#
cd "$(dirname "$0")"
git pull
git submodule update --init --recursive --quiet
function doIt() {
rsync --exclude ".DS_Store" -av ./public/ ~
echo
for file in $(find private/ -type f -exec ls {} \; 2> /dev/null | sed 's/private\///'); do
if [[ $file != '.gitignore' ]]; then
... | #!/bin/bash
cd "$(dirname "$0")"
git pull
git submodule update --init --recursive --quiet
function doIt() {
rsync --exclude ".DS_Store" -av ./public/ ~
echo
for file in $(find private -type f -exec ls {} \; 2> /dev/null | sed 's/private\///'); do
if [[ $file != '.gitignore' ]]; then
... |
Set bash instead of sh | #!/bin/sh
#
# init IndexData ubuntu deb repository
sources_list_d=/etc/apt/sources.list.d
indexdata_list=indexdata.list
apt_key=http://ftp.indexdata.dk/debian/indexdata.asc
deb_url=http://ftp.indexdata.dk
set -e
init_apt() {
if [[ "$OSTYPE" == "linux-gnu" ]]; then
file="$sources_list_d/$indexdata_list"
... | #!/bin/bash
#
# init IndexData ubuntu deb repository
sources_list_d=/etc/apt/sources.list.d
indexdata_list=indexdata.list
apt_key=http://ftp.indexdata.dk/debian/indexdata.asc
deb_url=http://ftp.indexdata.dk
set -e
init_apt() {
if [[ "$OSTYPE" == "linux-gnu" ]]; then
file="$sources_list_d/$indexdata_list"... |
Fix TextEdit's plain text related config | #!/bin/bash
cd "$(dirname "${BASH_SOURCE[0]}")" \
&& . "../../utils.sh"
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
print_in_purple "\n TextEdit\n\n"
execute "defaults write com.apple.TextEdit PlainTextEncoding -int 4 && \
defaults write com.apple.TextEdit PlainTextEncodin... | #!/bin/bash
cd "$(dirname "${BASH_SOURCE[0]}")" \
&& . "../../utils.sh"
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
print_in_purple "\n TextEdit\n\n"
execute "defaults write com.apple.TextEdit PlainTextEncoding -int 4 && \
defaults write com.apple.TextEdit PlainTextEncodin... |
Make sure crond is running in the background | #!/bin/sh
set -e
if [ -n "$SSH_PRIVATE_KEY" ]; then
mkdir -p ~/.ssh
rm -f ~/.ssh/id_rsa
echo "-----BEGIN RSA PRIVATE KEY-----" > ~/.ssh/id_rsa
echo "$SSH_PRIVATE_KEY" | fold -w 64 >> ~/.ssh/id_rsa
echo "-----END RSA PRIVATE KEY-----" >> ~/.ssh/id_rsa
chmod 0400 ~/.ssh/id_rsa
fi
if [ -n "$SSH_KNOWN_HOSTS" ]... | #!/bin/sh
set -e
if [ -n "$SSH_PRIVATE_KEY" ]; then
mkdir -p ~/.ssh
rm -f ~/.ssh/id_rsa
echo "-----BEGIN RSA PRIVATE KEY-----" > ~/.ssh/id_rsa
echo "$SSH_PRIVATE_KEY" | fold -w 64 >> ~/.ssh/id_rsa
echo "-----END RSA PRIVATE KEY-----" >> ~/.ssh/id_rsa
chmod 0400 ~/.ssh/id_rsa
fi
if [ -n "$SSH_KNOWN_HOSTS" ]... |
Add intermediate step of capitalization before converting string | source Base/BaseUtil.sh
source String/StringUtil.sh
MessageBuilderUtil(){
local time=$(BaseUtil timestamp)
buildMessage(){
echo "${time} [$(StringUtil toUpperCase ${1})] $(StringUtil replace $2 - space)"
}
$@
} | source Base/BaseUtil.sh
source String/StringUtil.sh
MessageBuilderUtil(){
local time=$(BaseUtil timestamp)
buildMessage(){
_message=$(StringUtil capitalize $2)
echo "${time} [$(StringUtil toUpperCase ${1})] $(StringUtil replace $_message - space)"
}
$@
} |
Use ffmpeg for codec copy of foscam mkvs | #!/bin/bash -e
folder=$1
camName=$2
basePath=$3
#http://stackoverflow.com/q/11448885
threshold=`date -d "5 minutes ago" +%Y%m%d%H%M%S`
#http://unix.stackexchange.com/a/84859/50868
shopt -s nullglob
for path in $basePath/raw/$folder/record/*.mkv ; do
file=$(basename $path)
#http://stackoverflow.com/a/5257398/3161... | #!/bin/bash -e
folder=$1
camName=$2
basePath=$3
#http://stackoverflow.com/q/11448885
threshold=`date -d "5 minutes ago" +%Y%m%d%H%M%S`
#http://unix.stackexchange.com/a/84859/50868
shopt -s nullglob
for path in $basePath/raw/$folder/record/*.mkv ; do
file=$(basename $path)
#http://stackoverflow.com/a/5257398/3161... |
Use yarn in test script | #!/bin/bash
export POSTGRES_PASSWORD="uleash"
echo "starting postgres in docker "
HASH=`docker run -P --name unleash-postgres -e POSTGRES_PASSWORD=$POSTGRES_PASSWORD -d postgres:9.3`
export PGPORT=`docker ps| grep unleash-post| awk '{print $(NF-1)}'| awk -F "->" '{print $1}'| awk -F \: '{print $2}'`
echo "PGPORT: $PG... | #!/bin/bash
export POSTGRES_PASSWORD="uleash"
echo "starting postgres in docker "
HASH=`docker run -P --name unleash-postgres -e POSTGRES_PASSWORD=$POSTGRES_PASSWORD -d postgres:9.3`
export PGPORT=`docker ps| grep unleash-post| awk '{print $(NF-1)}'| awk -F "->" '{print $1}'| awk -F \: '{print $2}'`
echo "PGPORT: $PG... |
Fix path to om tool | #!/bin/bash -eu
function main() {
local cwd
cwd="${1}"
chmod +x tool-om/om-linux
local om
om="tool-om/om-linux"
printf 'Waiting for opsman to come up'
until $(curl --output /dev/null --silent --head --fail -k ${OPSMAN_URI}); do
printf '.'
sleep 5
done
om --target "${OPSMAN_URI}" \
--s... | #!/bin/bash -eu
function main() {
local cwd
cwd="${1}"
chmod +x tool-om/om-linux
local om="tool-om/om-linux"
printf "Waiting for %s to come up" "$OPSMAN_URI"
until $(curl --output /dev/null --silent --head --fail -k ${OPSMAN_URI}); do
printf '.'
sleep 5
done
printf '\n'
$om --target "${OPS... |
Move files from vagrant home, if we are using virtualbox | mv ~/sources.list /etc/apt/sources.list
mv ~/sshd /etc/pam.d/sshd
echo GEM_HOME="$HOME/.gem" >> /etc/environment
echo PATH="$HOME/.gem/ruby/2.2.0/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games" >> /etc/environment
echo "Stopping puppet and chef"
service puppet stop
servic... | if grep 'vagrant' /etc/passwd
then
user_home=/home/vagrant
else
user_home=$HOME
fi
mv $user_home/sources.list /etc/apt/sources.list
mv $user_home/sshd /etc/pam.d/sshd
echo GEM_HOME="$user_home/.gem" >> /etc/environment
echo PATH="$user_home/.gem/ruby/2.2.0/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin... |
Provision global installation of jasmine | if ! [ -e ~/.nvm/nvm.sh ]; then
curl https://raw.githubusercontent.com/creationix/nvm/v0.17.2/install.sh | bash
fi
source ~/.nvm/nvm.sh
nvm list 0.10 || nvm install 0.10
nvm exec 0.10 which grunt || nvm exec 0.10 npm install -g grunt-cli
nvm list 0.11 || nvm install 0.11
nvm exec 0.11 which grunt || nvm exec 0.11 n... | if ! [ -e ~/.nvm/nvm.sh ]; then
curl https://raw.githubusercontent.com/creationix/nvm/v0.17.2/install.sh | bash
fi
source ~/.nvm/nvm.sh
nvm list 0.10 || nvm install 0.10
nvm exec 0.10 which grunt || nvm exec 0.10 npm install -g grunt-cli jasmine
nvm list 0.11 || nvm install 0.11
nvm exec 0.11 which grunt || nvm exe... |
Fix pip install that fails to download. | #!/bin/bash
set -o errexit
set -o xtrace
# Prepare environment
if [ -z "${USER}" ]; then
USER="docker"
fi
export USER
# Setup compiler
if [ -z "${CC}" ]; then
CC="gcc"
fi
export CC
if [ "${CC}" = "clang" ]; then
if [ -z "${CXX}" ]; then
CXX="clang++"
fi
COMPILER_PACKAGES="clang-3.4" # Ubu... | #!/bin/bash
set -o errexit
set -o xtrace
# Prepare environment
if [ -z "${USER}" ]; then
USER="docker"
fi
export USER
# Setup compiler
if [ -z "${CC}" ]; then
CC="gcc"
fi
export CC
if [ "${CC}" = "clang" ]; then
if [ -z "${CXX}" ]; then
CXX="clang++"
fi
COMPILER_PACKAGES="clang-3.4" # Ubu... |
Make sure we install the latest package in case of multiple rebuilds of same name | apt-get install -y php-pear php5-dbg gdb
apt-get install -y libssl-dev libsasl2-dev libpcre3-dev pkg-config
ls -1 /phongo/mongodb*.tgz | sort -n -r | xargs sudo pecl install
php -m | grep -q mongodb || echo "extension=mongodb.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
pecl run-tests -q -p m... | apt-get install -y php-pear php5-dbg gdb
apt-get install -y libssl-dev libsasl2-dev libpcre3-dev pkg-config
ls -1 /phongo/mongodb*.tgz | sort -n -r | xargs sudo pecl install -f
php -m | grep -q mongodb || echo "extension=mongodb.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
pecl run-tests -q -... |
Remove the use of timeout | set -e
DICTIONARY_FILE=${1}
PATTERN_FILE=${2}
PATOUT_FILE=${3}
TRANSLATE_FILE=${4}
LEFT_HYPHEN_MIN=${5}
LEFT_HYPHEN_MAX=${6}
HYPH_LEVEL=${7}
PAT_START=${8}
PAT_FINISH=${9}
GOOD_WEIGHT=${10}
BAD_WEIGHT=${11}
THRESHOLD=${12}
FIFO=tmp
rm -f $FIFO
mkfifo $FIFO
if which gtimeout >/dev/null; then
TIMEOUT=gtimeout;
else
... | set -e
DICTIONARY_FILE=${1}
PATTERN_FILE=${2}
PATOUT_FILE=${3}
TRANSLATE_FILE=${4}
LEFT_HYPHEN_MIN=${5}
LEFT_HYPHEN_MAX=${6}
HYPH_LEVEL=${7}
PAT_START=${8}
PAT_FINISH=${9}
GOOD_WEIGHT=${10}
BAD_WEIGHT=${11}
THRESHOLD=${12}
FIFO=tmp
rm -f $FIFO
mkfifo $FIFO
patgen $DICTIONARY_FILE $PATTERN_FILE $PATOUT_FILE $TRANSLATE_F... |
Add a comment about printing environment info | #!/bin/bash
pwd
git branch
git pull
npm run build
echo "Restarting legislation-explorer service..."
sudo systemctl restart legislation-explorer.service | #!/bin/bash
# Print some environment info useful when reading CircleCI logs.
pwd
git branch
git pull
npm run build
echo "Restarting legislation-explorer service..."
sudo systemctl restart legislation-explorer.service
|
Install system dependency - libmariadb-dev | #!/bin/bash
set -e
# Check for merge conflicts before proceeding
python -m compileall -f "${GITHUB_WORKSPACE}"
if grep -lr --exclude-dir=node_modules "^<<<<<<< " "${GITHUB_WORKSPACE}"
then echo "Found merge conflicts"
exit 1
fi
# install wkhtmltopdf
wget -O /tmp/wkhtmltox.tar.xz https://github.com/frappe/wk... | #!/bin/bash
set -e
# Check for merge conflicts before proceeding
python -m compileall -f "${GITHUB_WORKSPACE}"
if grep -lr --exclude-dir=node_modules "^<<<<<<< " "${GITHUB_WORKSPACE}"
then echo "Found merge conflicts"
exit 1
fi
# install wkhtmltopdf
wget -O /tmp/wkhtmltox.tar.xz https://github.com/frappe/wk... |
Fix "docker --name" command line option. | #!/bin/sh
cd $(dirname $0)
SOURCE=$(pwd)/android
CONTAINER=cyanogenmod
REPOSITORY=stucki/cyanogenmod
# Create a shared folder which will be used as working directory.
test -d $SOURCE || mkdir $SOURCE
# Try to start an existing/stopped container with the given name $CONTAINER. Otherwise, run a new one.
docker start ... | #!/bin/sh
cd $(dirname $0)
SOURCE=$(pwd)/android
CONTAINER=cyanogenmod
REPOSITORY=stucki/cyanogenmod
# Create a shared folder which will be used as working directory.
test -d $SOURCE || mkdir $SOURCE
# Try to start an existing/stopped container with the given name $CONTAINER. Otherwise, run a new one.
docker start ... |
Disable JIT on CI Postgres to make wheel tests predictable | #!/bin/bash
set -e -x
if [ -z "${PGVERSION}" ]; then
echo "Missing PGVERSION environment variable."
exit 1
fi
if [[ "${TRAVIS_OS_NAME}" == "linux" && "${BUILD}" == *wheels* ]]; then
sudo service postgresql stop ${PGVERSION}
echo "port = 5432" | \
sudo tee --append /etc/postgresql/${PGVERSION... | #!/bin/bash
set -e -x
if [ -z "${PGVERSION}" ]; then
echo "Missing PGVERSION environment variable."
exit 1
fi
if [[ "${TRAVIS_OS_NAME}" == "linux" && "${BUILD}" == *wheels* ]]; then
sudo service postgresql stop ${PGVERSION}
echo "port = 5432" | \
sudo tee --append /etc/postgresql/${PGVERSION... |
Add --yes flag to elm-make | #! /usr/bin/env bash
elm-test
if [ $? -ne 0 ]; then exit 1; fi;
elm-make --warn src/Main.elm
| #! /usr/bin/env bash
elm-test
if [ $? -ne 0 ]; then exit 1; fi;
elm-make --yes --warn src/Main.elm
|
Remove origin/ and replace '/' in branch names in tar file | #sass sass:static/css -r templates/sass/bourbon/lib/bourbon.rb --style :compressed
if [ -z "${GIT_COMMIT}" ]; then
GIT_COMMIT=$(git rev-parse HEAD)
fi
if [ -z "${GIT_BRANCH}" ]; then
GIT_BRANCH=$(git symbolic-ref -q HEAD)
GIT_BRANCH=${GIT_BRANCH##refs/heads/}
GIT_BRANCH=${GIT_BRANCH:-HEAD}
fi
if [ -z... | #sass sass:static/css -r templates/sass/bourbon/lib/bourbon.rb --style :compressed
if [ -z "${GIT_COMMIT}" ]; then
GIT_COMMIT=$(git rev-parse HEAD)
fi
if [ -z "${GIT_BRANCH}" ]; then
GIT_BRANCH=$(git symbolic-ref -q HEAD)
GIT_BRANCH=${GIT_BRANCH##refs/heads/}
GIT_BRANCH=${GIT_BRANCH:-HEAD}
fi
GIT_BRAN... |
Use 1998 ISO C++ standard | mkdir _build && cd _build
cmake .. -DCMAKE_INSTALL_PREFIX=$PREFIX -DCMAKE_BUILD_TYPE=Release
make all -j4
make install
| export CXXFLAGS="-std=c++98"
mkdir _build && cd _build
cmake .. -DCMAKE_INSTALL_PREFIX=$PREFIX -DCMAKE_BUILD_TYPE=Release
make all -j4
make install
|
Revert "Whoops, forgot to include this dummy precmd implementation." | export PAGER=less
export LC_CTYPE=en_US.UTF-8
# speed stuff.
#setopt no_beep
setopt auto_cd
setopt multios
setopt cdablevarS
if [[ x$WINDOW != x ]]
then
SCREEN_NO="%B$WINDOW%b "
else
SCREEN_NO=""
fi
PS1="%n@%m:%~%# "
# Setup the prompt with pretty colors
setopt prompt_subst
export LSCOLORS="Gxfxcxdxbxeged... | export PAGER=less
export LC_CTYPE=en_US.UTF-8
# speed stuff.
#setopt no_beep
setopt auto_cd
setopt multios
setopt cdablevarS
if [[ x$WINDOW != x ]]
then
SCREEN_NO="%B$WINDOW%b "
else
SCREEN_NO=""
fi
PS1="%n@%m:%~%# "
# Setup the prompt with pretty colors
setopt prompt_subst
export LSCOLORS="Gxfxcxdxbxeged... |
Copy syslog into the workspace | #!/usr/bin/env bash
FILENAME=${1}
#pull all images
/usr/local/bin/docker-compose -f docker-compose.yml -f ${FILENAME} pull
#run docker file
/usr/local/bin/docker-compose -f docker-compose.yml -f ${FILENAME} run contract_tests
#cleaning after tests
contract_test_result=$?
echo "========== Logging output from contai... | #!/usr/bin/env bash
FILENAME=${1}
#pull all images
/usr/local/bin/docker-compose -f docker-compose.yml -f ${FILENAME} pull
#run docker file
/usr/local/bin/docker-compose -f docker-compose.yml -f ${FILENAME} run contract_tests
#cleaning after tests
contract_test_result=$?
echo "========== Logging output from contai... |
Use id_rsa.pub for the pubkey alias | # Pipe my public key to clipboard
alias pubkey="more ~/.ssh/id_dsa.public | pbcopy | echo '=> Public key copied!'" | # Pipe my public key to clipboard
alias pubkey="more ~/.ssh/id_rsa.pub | pbcopy | echo '=> Public key copied!'" |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.