blob_id stringlengths 40 40 | length_bytes int64 7 488k | source stringlengths 7 488k |
|---|---|---|
65c6a5692ac13f5e633a20c6e95880f1ea989050 | 605 | #!/usr/bin/env bash
action=$(echo -e "suspend\nlock\nlogout\nshutdown\nreboot" | wofi -d -p "power:" -L 7)
if [[ "$action" == "lock" ]]
then
swaylock-fancy --font "JetBrains-Mono-Light"
fi
if [[ "$action" == "suspend" ]]
then
{% if ansible_distribution_release == "void" %}
swaylock-fancy --font "JetBrains-Mo... |
b8f6361f1e32ebb6fe529bdef4561996b5bb945d | 327 | d=$4
h2s=$3
i=$2
genvar=$1
dir=d_$d/genVar_$genvar/h2s_$h2s/sim_$i
mkdir -p $dir
make threshold d=3000 n=1200 h2s=0.5 dc=10 genvar=0.5 chr=22 i=1 method=p outdir=/home/shussain/FADS/experiments/genvar/test name="30092021"
#make move dir=$dir h2s=$1
#
# --nonlinear exp \
# --expbase $(base) \
# --proportionNonli... |
997d21168f0af33f373d2a33f5009f1073604d23 | 105 | #!/bin/bash
xrandr --output "HDMI-1" --off --output "eDP-1" --auto
feh --bg-scale $HOME/Pictures/bg.png
|
cc9a2e5dacdff03a7c8d935bda16b0a439851883 | 2,567 | # -*- mode: sh -*-
# vim: set ft=sh:
function zsh-learn-Searchle(){
local arg argdollar searchCmd
if test -z "$1"; then
if [[ "$ZPWR_COLORS" = true ]]; then
echo "select learning,category from $ZPWR_SCHEMA_NAME.$ZPWR_TABLE_NAME order by dateAdded" |
${=ZPWR_LEARN_COMMAND} 2>> ... |
9dab56a151095a98a821c02be755e8ad9b53722a | 1,973 | #!/bin/bash
# This file was written bu dualznz © 2020
# You can freely distribute this file and its contents but there is no liability
# if anything goes wrong when using this file.
# start
# colors
# forground colors
fgBlack=$(tput setaf 0)
fgRed=$(tput setaf 1)
fgGreen=$(tput setaf 2)
fgYellow=$(tput setaf 3)
fgBl... |
88303ffbd16fe47173296d13a0df178ebf0712f7 | 584 | #!/usr/bin/env bash
CFG="$HOME/.config/eww/arin/sidebar"
EWW=`which eww`
close_eww() {
${EWW} --config "$CFG" close resources logout suspend lock reboot shutdown quotes
}
if [[ $1 = "--logout" ]]; then
close_eww
$HOME/.local/bin/logout
elif [[ $1 = "--suspend" ]]; then
close_eww
systemctl suspend
elif [[ $1... |
61a03bb04d2b9fba84a363c92703e68b851659fc | 133 | #!/bin/bash
# Take the Ethernet iface down and then give it static IP
sudo ifconfig enp8s0 down
sudo ifconfig enp8s0 192.168.100.80
|
174e2032be763d57138e0c8e0572a16b804f138e | 584 | #!/bin/ksh
ResName=$1
shift
DS=$1
VCSHOME="${VCS_HOME:-/opt/VRTSvcs}"
. $VCSHOME/bin/ag_i18n_inc.sh
VCSAG_SET_ENVS $ResName
if [[ -x /usr/sbin/metastat ]]
then
metastat=/usr/sbin/metastat
elif [[ -x /usr/opt/SUNWmd/sbin/metastat ]]
then
metastat=/usr/opt/SUNWmd/sbin/metastat
else
metastat=metastat
fi
if [[ -x /... |
bcd4d9d173e7578f7d4169ba30524f7e9cedf920 | 127 | #! /bin/bash
curl http://${ORION_EP}/v2/entities/ColdRoom?type=Room -s -S \
--header 'Accept: application/json' | json_pp
|
cc5c0192340f4c561626461f267500be612768a5 | 579 | #!/bin/sh
while true;do
checkupdates
exit_code=$?
if [ $exit_code -ne 2 ];then
act=$(dunstify -a Updates -A "update,up" "Updates are available" | bc)
if [ $act -eq 0 ];then
mapunmap_updates.sh
fi
else
echo no_updates
fi
sleep 3600
done
# ! [[ -z $act ]] && termite --hold --title="archlinux_updates_... |
3638b86513ac73ac74f96598ac3de2c3ba23b86b | 110 | #!/bin/sh
docker network create --driver overlay --subnet 10.1.0.0/16 --attachable fc_crawl_webrender_network
|
0d756ae3f9caa9b5d4a340371704966c60eb1e92 | 167 | #!/bin/bash
set -e
set -x
# disable cloud-init
touch /etc/cloud/cloud-init.disabled
# hack - wait until all the packages are updated
sleep 120
sudo apt-get clean
|
c586498ce26da15ad18218c35cd045b49924ec40 | 281 | #!/bin/bash
applyoption="-slb"
[[ $LEARN_TOOLKIT == 'SciKit' ]] && applyoption="-sl"
$DATA_CORPUS_SCRIPT |
$PREPROCESS_SCRIPT |
$SEQUENCE_SCRIPT |
$MXS_BIN/applyRules.py $applyoption $CORPUS_MODEL/patterns.txt |
$CORPUS_MERGE_SCRIPT |
$CORPUS_OUTPUT_SCRIPT |
$CORPUS_DATA_SCRIPT
|
920924ee02889d169b895a60ada5e32924ce56af | 2,050 | echo -e "========================开始安装mysql5.7.25========================"
yum install -C -y mysql-community-server
systemctl start mysqld
systemctl enable mysqld
systemctl daemon-reload
grep 'temporary password' /var/log/mysqld.log
echo && read -e -p "请输入mysql初始化的随机密码(在root@localhost:后为初始密码):" mysql_... |
b0690c8f4df55088cd10561199e32d77cf9c6320 | 1,588 | #!/bin/bash
#Very Useful Template File for Shell Scripts
#Usage Statement
usage()
{
echo "
USAGE:
Required Arguments:
-
Optional Arguments:
-u displays this usage statement
-h displays this usage statement
Examples Uses:
here
"
exit 1 #Must be adjusted in a sourced script
}
#Generates Nice Error Messag... |
1744a2c95d9d6fc98bba66e6d244ed11e078749a | 862 | #!/bin/bash
# We need to install dependencies only for Docker
[[ ! -e /.dockerenv ]] && exit 0
set -xe
# Install git (the php image doesn't have it) which is required by composer
apt-get update -yqq
apt-get install git wget unzip -yqq
# Install phpunit, the tool that we will use for testing
curl --location --output... |
638f42f6c53cadcb20ecf13d2c28980cf9d9395b | 755 | #!/usr/bin/env bash
set -o nounset
# shellcheck source=/dev/null
source "${stdenv}/setup"
mkdir -p "${out}/share/keen4"
unzip -j "$dist" -d "${out}/share/keen4"
mkdir -p "${out}/bin"
cat > "${out}/bin/keen4" <<EOF
#! $SHELL -e
if test -z "\$HOME"; then
echo "HOME directory not set"
exit 1
fi
# Game wants t... |
1a88a438d46d12c7c48c205576e064a0671e9465 | 1,060 | #!/usr/bin/env bash
# NOTE api exapmle from website
# curl -H 'Accept: application/xml' -H 'Content-Type: application/xml' -u 05843cba04869e814b758270cc28ccefca09ea9d:X 'https://annosum.basecamphq.com/todo_lists.xml?responsible_party=6606027' | grep -G content
# basic HTTP authentication no password
API_token="-u 058... |
aa2ff14e578882432318adca4bf0db9031109785 | 584 | #!/bin/bash
# Derek Johnson dej3tc
# 10/31/19
# We will first prompt the user for a number
# between 1 and 9 that will be used for the
# timer program
read -e -p "Input a number between 1 and 9: " number
quit="quit"
if [ $number == $quit ]
then
exit
fi
clang++ counter.cpp
i=1
RUNNING_TIME=0
while [ $i -lt 6 ];... |
7ac2576d6f8421fb4b519da30e20b9866d91c7d5 | 110 | #!/bin/bash
export FLASK_APP=hello.py
export FLASK_DEBUG=1
#python -m flask initdb
flask run --host=0.0.0.0
|
b95392637efe223dbf9f07b4f683d99087659950 | 86 | #!/bin/sh
docker-compose -p zchain -f docker.aws/build.miner/docker-compose.yml stop
|
54f6b42d3942d0b6ec4d520506c850d5a22ba599 | 25 | brew cask install itools
|
7fcc2aeba63f3977d5cc6f3b5f7ab50904e13501 | 605 | #!/bin/bash
skyforge_replace_symlink_with_copy()
{
link="$1"
if [ ! -L "$abstarget" ]; then
return
fi
dir=$(dirname "$link")
reltarget=$(readlink "$link")
if [[ $reltarget == /* ]]; then
abstarget=.$reltarget
else
abstarget=$dir/$reltarget
fi
rm -f "$link"
if [ -L "$abstarget" ]... |
4a126db828c8d24ab4b5c207efdd5a209b7e7fc7 | 2,041 | cat lemmalist.txt | while read lemma
do
echo $lemma;
python3 formatfile.py "../corpus_data/OANC_spoken_all/spoken_"$lemma"_all.txt" OANC_spoken $lemma gpt "../corpus_data/formatted/OANC_spoken_"$lemma".tsv";
python3 formatfile.py "../corpus_data/OANC_written_all/written_1_"$lemma"_all.txt" OANC_written $lemma gpt "... |
965d4a06b0d212f01968ec2b313ac2ef06d44061 | 298 | #!/bin/bash
# Set activity monitoring error
set -e
# Take needs directory
cd /tabletennis
rm -rf tmp/pids/server.pid
bundle install
# Drop old db
./bin/rails db:drop
# Create new db
./bin/rails db:create
# Migrate models tables to new db
./bin/rails db:migrate
./bin/rails server -b 0.0.0.0
|
9c9e928a6eb1ba492bef5d52a9b7830966ebd295 | 80 | #!/bin/bash
sudo mysql -uroot -e "CREATE DATABASE answer_db CHARACTER SET utf8"
|
cd1e2374b1313f92d4a48a66378b4ec718bff6e9 | 1,161 | #!/bin/bash
yum -y update && yum clean all;
yum -y install wget
yum -y install tar
yum -y install gcc
yum -y install zlib-devel
yum -y install sudo
yum -y install git
yum -y install perl-CPAN
curl -L http://cpanmin.us | perl - App::cpanminus
wget https://dev.mysql.com/get/mysql80-community-release-el7-3.noarch.rpm
r... |
af190ae672abd42801681a42d43d302f13ec5e81 | 739 | local _path_ant="$PATH"
# configuracion local
[[ -f ~/.zshenv.local ]] && source ~/.zshenv.local
if [[ $PATH != $_path_ant ]]; then
# `colors` no se ha inicialiado, definir algunos manualmente
typeset -AHg fg fg_bold
if [ -t 2 ]; then
fg[red]=$'\e[31m'
fg_bold[white]=$'\e[1;37m'
reset_color=$'\e[m'
... |
bc8c5fe6aa673a994351b9763dfd332c5ee0a58c | 1,088 | #!/bin/bash
# NAME: Cindi Dong
# EMAIL: cindidong@gmail.com
# ID: 405126747
threads=(1 2 4 8 12 16 24)
sync=(m s)
lists=(1 4 8 16)
# testing list-none-sync for pic 1 and 2
for t in ${threads[@]}; do
for i in ${sync[@]}; do
./lab2_list --iterations=1000 --threads=$t --sync=$i >> lab2b_list.csv
done
done
iteration... |
a6e90f48d25a76c89e1fec60ccc0c795008f7179 | 690 | # $Id$
# Maintainer: Brian De Wolf <arch@bldewolf.com>
pkgname=kpass-tools
pkgver=6
pkgrel=1
pkgdesc="kpass-tools is a set of experimental tools for using KeePass 1.x databases."
url="https://github.com/bldewolf/kpass-tools"
arch=('i686' 'x86_64')
license=('GPL')
depends=('libkpass' 'util-linux')
makedepends=('pkgconfi... |
fe4475e54e8e3e65566b261aff1aa2220c52785d | 1,885 | #!/usr/bin/env bash
set -euo pipefail
# This script is loosely adapting the TLS setup described in
# https://kubernetes.io/blog/2019/03/21/a-guide-to-kubernetes-admission-controllers/#tls-certificates
# for local development
# Require: a private ip reachable from your cluster.
# If using k3d to test locally, then pro... |
d74788f8de3c062a4da1712ff7e9963ad8f5545d | 170 | #!/bin/sh
set -e -x
if [ "$#" -ne 1 ]; then
echo "Please provide location to place build output."
exit 1;
fi
./gradlew build
cp build/libs/spring-music.war $1
|
f8d588fb88245233724588110c4c07af0e6c3cc7 | 409 | #!/bin/bash
set -euo pipefail
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
"$DIR/build-lambda"
echo "Built new lambda binary"
set -x
cd target/x86_64-unknown-linux-musl/release
zip aws_lambda.zip kirby-s3
cd -
aws lambda update-function-code \
--function-name "kirby-s3" \
--zip-file "fileb://target/x8... |
3b3fd95d9449684d1b7d10fa49584650f0435b83 | 149 | if ! mkdir -p $1/a/b/c/d/e/f; then
exit 1
fi
if ! mkdir -p $1/g/h/i/j/k/l; then
exit 1
fi
if ! mkdir -p $1/m/n/o/p/q/r; then
exit 1
fi
|
9cbbda22e9f30a2a538371603b45307d8f16c2d5 | 795 | #!/bin/bash
. config
cd translation_$VERSION
if [ -d "source/com" ]
then
echo "Delete translation_4.1/source/com first"
exit
fi
deeptouch ()
{
dir="$2/$(dirname "$1")"
[ -d "$dir" ] || mkdir -p "$dir"
touch "$2/$1"
}
sqlite3 -list -separator '^' ../kindle_loc.sqlite "select src,tran,file from ... |
4233ed371d790317b7d421e7b5d6e40f248f8fbe | 380 | #! /bin/bash
echo
echo please choose one of the options below
echo 'a=to print the server name'
echo 'b=to print the load average and uptime'
echo 'c=to check who are loggedin the server'
echo 'd=to print the current directory'
read choice
case $choice in
a)
hostname
;;
b)
uptime
;;
c)
who
;;
d)
... |
022fa7feec806f2a2a569e0de233ab8bf2954ce0 | 743 | #!/bin/sh
ip link add usnetadv type dummy
ip link set usnetadv up
ip link add link usnetadv usnetadvr type macvlan mode bridge
ip link set usnetadvr up
ip addr add 10.30.1.1/29 dev usnetadvr
ip link add link usnetadv usnetadvl1 type macvlan mode bridge
ip link set usnetadvl1 up
ip link add link usnetadv usnetadvl2 ... |
5ef9a1b82d2b6c10e2606e87c41af34686101dba | 66 | REACT_APP_BACKEND_API=https://mamduh-weds360-backend.herokuapp.com |
9654382416804cc38312e5a2702fb80434c3ca6a | 141 | #!/usr/bin/env bash
export LC_ALL=en_US.UTF-8
DIR=`dirname "$0"`
echo "shutdown..."
${DIR}/shutdown.sh
echo "startup..."
${DIR}/startup.sh
|
84b58097fa2c3a6609cee0cd67b178581cb4643e | 9,506 | #!/bin/bash
bold=$(tput bold)
normal=$(tput sgr0)
####################################
## input nfd name and manage network
####################################
echo ""
read -p "${bold}Set the ICN + DTN VNF function. Do you want to proceed?(n or y[default]) :${normal}" is_process
if [ -z $is_process ]; then
is_pr... |
f7d1cd5ab2d444f26802deec125aa48a7439b6d4 | 784 | alias ll='ls -ltr'
alias lal='ls -al'
alias lf='ls -F'
alias lh='ls -1hrt'
alias la='ls -a'
alias l.='ls -d .*'
alias lsd='ls -d */'
alias mkdir='mkdir -pv'
alias rmr='rm -fR'
alias ..='cd ..'
alias ...='cd ../..'
alias ....='cd ../../..'
alias .....='cd ../../../..'
alias cl='clear'
alias cla='clear;la'
alias cll='c... |
13cd9022244f15bf52063f3439145ee56b4b5636 | 104 | MONGOLAB_URI=mongodb://syrotenko:brocoders0@ds249503.mlab.com:49503/syrotenko_req-trap
DEFAULT_PORT=3000 |
90ae5bb88d8c48b6480cd265b1c608b55f4a270d | 784 | #!/bin/bash
# DEPS
# createrepo
REPO_FOLDER=$1
DISTRO=$2
SIG_NAME=$3
# bash tools/repo-create-rpm.sh /srv/kaji-repo/ RHEL7 "Kaji Project"
DISTRO_FOLDER="${REPO_FOLDER}/${DISTRO}"
CREATEREPO=`which createrepo`
# Check reprepro
if [ "$CREATEREPO" = "" ]
then
echo "createrepo is missing"
exit 2
fi
# Check ... |
cf18d2f578ff5ba900ed28fa2390732341a4daf2 | 262 | #!/bin/bash
ps_out=`ps -ef | grep 'shanghai_minutes' | grep -v 'grep' | grep -v $0`
result=$(echo $ps_out | grep "guangzhou_minutes")
if [[ "$result" != "" ]];then
echo "Running"
else
paths=`pwd`
echo $paths
python3 $paths/guangzhou_minutes.py
fi |
5bd30afaff63450d09dc991378169928499ca6de | 1,729 | #!/usr/bin/zsh
alias cp='/bin/cp --verbose'
alias mv='/bin/mv --verbose'
alias rm='/bin/rm --verbose --interactive=once'
alias mkdir='/bin/mkdir --verbose --parents'
alias rmdir='/bin/rmdir --verbose --parents'
alias ls='/bin/ls --group-directories-first --time-style=+"%d.%m.%y %H:%M" --color=auto --indicator-style=c... |
7ab2a65823e1020dcf847bbe910f7d3e16e9a904 | 1,162 | #!/usr/bin/env bash
pushd ~htpc/temperature > /dev/null
. time.sh
# Log Data
declare -r LOGFILE=temperature.log
temp=$(sensors -u | grep -A 1 'Package id 0:' | grep _input | cut -s -d\ -f 4)
time=$(getTime)
if [ ! -r $LOGFILE ]; then
echo "Couldn't find temperature log, creating it..."
echo "Time, Temperature... |
fcd3c6a5209d7956e14d0cc3fe4b3b25683806c1 | 91 | #!/bin/bash -e
ctx logger info "Unnstalling Apache web server..."
sudo yum -y remove httpd |
efe4fd9f9ae4d9b6441d8d1a3f5cab4f65af591a | 180 | #!/bin/sh
# Check clock_nanosleep, clock_gettime, and setitimer syscalls decoding.
. "${srcdir=.}/init.sh"
run_strace_match_diff -e trace=clock_nanosleep,clock_gettime,setitimer
|
ad655e02fb5e3224767785390a8dc6f344ed3b7b | 4,310 | #!/bin/bash
###############################################################################
## Init enviroiment source
dir_path=$(dirname $0)
source $dir_path/config.cfg
source $dir_path/lib/functions.sh
###############################################################################
## Khai bao duong dan
path_chrony... |
a2fcdaa29c27381d32701e69f7391033702bc4ec | 806 | # .bashrc
# Source global definitions
if [ -f /etc/bashrc ]; then
. /etc/bashrc
fi
# Uncomment the following line if you don't like systemctl's auto-paging feature:
# export SYSTEMD_PAGER=
# User specific aliases and functions
# export PATH=/opt/bin:$PATH
# User specific aliases and functions
alias ls='ls --colo... |
c4f8eb51d7675911e047d6b738ad2ea5ecdd93b8 | 516 | #!/bin/bash
function dbum() {
if [[ -e "$1" ]]; then
mv "$1" "$1.$(date +%y%m%d%H%M%S)"
fi
}
sudo apt-get -y install ctags silversearcher-ag
git clone --depth 1 https://github.com/junegunn/fzf.git ~/.fzf
~/.fzf/install
dbum ~/.vimrc
git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vu... |
2eb9c0985a9fe6f7af26ee8bc44d354857e87d68 | 1,658 | data_dir=./data/depth-5
lr=1e-5
ep=50
output_dir=./output/d5
# model=roberta_rr # PRover
model=roberta_probr # PRobr
num_gpus=8
distribute_on=" -m torch.distributed.launch --nproc_per_node=$num_gpus"
distribute_off=""
distribute=$distribute_off
python3 $distribute ./run_experiment_probr.py \
... |
3c19528b811594e1e5d8d6e74efedafd340e6e72 | 150 | # JWT
SECRET_KEY=secretkeysecretkeysecretkey
# APP
APP_URL=https://staging.codetrain.xyz
# AMQP LIB
AMQP_URL=amqp://localhost
AMQP_QUEUE=codetrainer |
8d4cf757eac303f0538ff244144bb4298e4737e7 | 55 | #!/bin/bash
source ~/.bashrc
th -f dice.th -- 100 3 6
|
d3d82649551f1edf0b0087d59cf68764b2320ba9 | 158 | #!/bin/bash
CAMINHO_IMAGENS=~/Documentos/SH
convert $CAMINHO_IMAGENS/$1.jpg $CAMINHO_IMAGENS/$1.png
convert $CAMINHO_IMAGENS/$2.jpg $CAMINHO_IMAGENS/$2.png
|
8b0515b943a883ed0de96edb1cb64c588e42fd58 | 158 | #!/bin/sh
if test -f ~/.sbtconfig; then
. ~/.sbtconfig
fi
exec java -Xmx2048M -XX:+CMSClassUnloadingEnabled ${SBT_OPTS} -jar ~/bin/sbt-launch-0.13.jar "$@"
|
96fde8854112a256c6ea96cd8eec8497f0d55ef6 | 730 | #!/bin/bash
set -o errexit
pushd "$(cd "$(dirname "$0")" ; pwd -P )/.." > /dev/null
if [[ -f .env ]]; then
# shellcheck disable=SC1091
source .env
fi
for DIR in $DENV_LATEST_IMAGES; do
IFS='/' read -ra ARR <<< "$DIR"
IMAGE=${ARR[0]:-base}
TAG=${ARR[1]:-latest}
docker tag "denv/$IMAGE:$TAG" "docker.pkg.gi... |
70d293cc91e4b173937cd5c86e3936c22e1793a7 | 120 | #!/usr/bin/env bash
if [ $# -gt 1 ] && isnum "$1"; then
num=$1
shift
tail -n $num -f "$@"
else
tail -f "$@"
fi
|
ceb49be2dff6b676d05362942b2f2e8eb94d30a1 | 264 | # CONFIG
PORT=3000
CORS=*
# MONGO
DB_USER=
DB_PASSWORD=
DB_HOST=
DB_NAME=
# USERS
DEFAULT_ADMIN_PASSWORD=
DEFAULT_USER_PASSWORD=
# AUTH
AUTH_JWT_SECRET=FC6xnhTSEKlt0mNHjw4fucpzqg2e5M9B
# API KEY
PUBLIC_API_KEY_TOKEN=
ADMIN_API_KEY_TOKEN=
|
0e64c26cf1d7c8a4faccf192ea7e30f955673ae5 | 159 | set -e
autoflake --remove-all-unused-imports --recursive --remove-unused-variables --in-place src tests --exclude=__init__.py
black src tests
isort src tests
|
1893e81da1fee9382b9a83f572a88e4893cdcdee | 1,683 | #!/bin/bash
chmod +x teacher/*.sh
. teacher/teacher_new_student.sh
. teacher/teacher_delete_student.sh
. teacher/teacher_edit_student.sh
. teacher/teacher_list_student.sh
. teacher/teacher_add_student_course.sh
. teacher/teacher_search_student.sh
. teacher/teacher_view_course_student.sh
. teacher/teacher_assign_ass... |
06ea862e6c2524f17c5c55cbf3b876911c4a9710 | 288 | #!/usr/bin/zsh
set -o shwordsplit
procs=$(ls /proc | grep -oP "[0-9]*")
for pid in $procs; do
if [[ -d "/proc/$pid/" ]]; then
cmdline=$(cat /proc/$pid/cmdline)
if [[ -n "$cmdline" ]]; then
cmdline=$(echo $cmdline | cut -d' ' -f1)
echo ${cmdline##*/}| tr -d ' :'
fi
fi
done
|
09707d7d0d65f2d04843911339a40475147e8db5 | 1,049 | #!/bin/bash
# Arguments:
# 1: [install/uninstall]
# 2: module name
# 3: port
# 4: IP
# Check action
if [ -z "$1" ]; then
echo "Missing valid action" >&2
fi
ACTION="$1"
if [ "$ACTION" == "install" ]; then
# Default values
IP="127.0.0.1"
PORT="8080"
MODULE=""
if [ -z "$2" ]; then
echo "Missing valid .... |
63b144f5d8cdeb464bf9ea220867da466d510cee | 163 |
# Script to convert .mp4, .avi video to .gif format, which is then embedded to GitHub page
ffmpeg -i input_video.mp4 -t duration_time_to_convert output_video.gif
|
cc230718f40f3cd3d440e4f7e822f99c1fa4ccfc | 2,604 | export EDITOR=vim
# Oh my zsh
export DEFAULT_USER=`whoami`
#Add my custom script
export PATH=$PATH:$HOME/.dotfiles/bin
# Homebrew
export PATH=/opt/homebrew/bin/opt/homebrew/opt/openjdk/bin:/usr/local/sbin:$PATH
# Coverity tools
export PATH=~/tools/cov-analysis-macosx-7.7.0.4/bin:$PATH
# Go
export GOPATH=~/dev/go
#expor... |
8be91ab4a38e8ff2d190a3dd06a317c69ac5d0cf | 107 | DATABASE=mongodb+srv://rigelselmain:Amerika123@cluster0.yifhq.mongodb.net/nail?retryWrites=true&w=majority
|
f6aafa0268e11f66e477db6e580b76e26eb4b6f4 | 174 | Finding file with regexes
Practical `du` command
Extracting `tar` files to a specific directory
Working with `.gz` files
Find the unknown process preventing deleting of files |
9d009de935e109832ff9fcfa4cd149121a34e73f | 337 | #!/usr/bin/zsh
i3-msg "workspace 3; append_layout ~/.config/i3/layout/layout_screeps_server.json";
urxvt -name screeps-server -e zsh -c "cd /srv/screeps; npx screeps start" &;
sleep 1;
urxvt -name screeps-cli -e zsh -c "cd /srv/screeps; npx screeps cli" &;
urxvt -name screeps-multimeter -e zsh -c "cd /srv/screeps... |
bdecd8837ff1b4ec90b4158e8f3aa6c3fce4c495 | 8,127 | # Completion {{{
zstyle ':completion:*' completer _expand _complete _ignored
zstyle ':completion:*' expand prefix suffix
zstyle ':completion:*' file-sort name
zstyle ':completion:*' format '%BCompleting %d%b'
zstyle ':completion:*' glob 1
zstyle ':completion:*' group-name ''
zstyle ':completion:*' ignore-parents parent... |
460412bfdd16fdf7890850befd4be1afe299c973 | 42 | #!/usr/bin/env bash
#
python3 app/main.py |
b6d9669dc8813ddc0131f82ee4d174bd88171b46 | 1,306 | #!/bin/bash
#SBATCH -A shchowdhury@hbku.edu.qa
#SBATCH -J VADtest
#SBATCH -o vad_out.txt
#SBATCH -e vad_err.txt
#SBATCH -p gpu-all
#SBATCH --gres gpu:0
#SBATCH -c 40 #number of CPUs needed
module load cuda10.1/toolkit gcc6 slurm cmake
source ~/anaconda3/bin/activate ~/anaconda3/envs/vad
#pip install -r ./requirement... |
f9be5f1f31a67215d2ffac1467f2107b2f40a73a | 3,142 | #! /bin/bash
S=$(dirname $0)
D=/var/www/html
R=root@saans.ca
function help() {
cat <<EOF
usage: $(basename $0) <cmd>
<none> do the following steps:
tx transfer $S --> $R:$D
venv update remote's virtualenv dependencies
migrate migrate remote's database
restart restart the webserver
EOF
}
i... |
f7c6a2ab727dcead144b05095525fe41ae4bdf9e | 269 | #!/bin/bash
sudo ovs-vsctl -- --id=@br0 get Bridge br0 -- --id=@cs create \
Flow_Sample_Collector_Set id=2 bridge=@br0 ipfix=@i -- --id=@i create IPFIX \
targets=\"127.0.0.1:4739\" obs_domain_id=2 obs_point_id=3 \
cache_active_timeout=5 cache_max_flows=13
|
e889a1abd3c7a96ed6d6a950090023862aac591c | 391 | #!/bin/bash
source /opt/zimbra/bin/zmshutil || exit 1
zmsetvars zmconfigd_listen_port
NC=`which nc 2>/dev/null`; NC=${NC:-`which netcat 2>/dev/null`}
echo REWRITE $@ | $NC -w 120 localhost ${zmconfigd_listen_port} > /dev/null 2>&1
rc=$?
# If nc fails to connect, run zmconfigd directly
if [ $rc -ne 0 ]; then
/opt/z... |
c25cd777f9849fd93f30d16481e615e3a1761c0f | 570 | #!/bin/bash
BINARY=$1
TESTS_DIR=$2
RESULT="PASS"
if [[ $# -lt 2 ]]; then
echo "Usage: $0 prog_binary tests_dir"
exit 1
fi
echo "-> Run positive tests"
for f in `ls $TESTS_DIR/YES`; do
if ! $BINARY $TESTS_DIR/YES/$f; then
echo " Test $f failed!"
RESULT="FAIL... |
db6e0d832138b3d74e7a9379c0100a9464825f0d | 1,889 | #!/bin/bash
### BEGIN INIT INFO
# Provides: pleco
# Required-Start: $network $remote_fs $syslog
# Required-Stop: $network $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 1
# Short-Description: Start Pleco Remote Controllable Vehicle
### END INIT INFO
PATH=/sbin:/bin:/usr/sbin:/usr/bin
. /l... |
373c4a73d682d56be5891cc5f41e52b7bb39e95f | 459 | #!/usr/bin/env bash
#Install the kube-controller-manager binary in the master nodes
#create necessary directories, copy certs and
#create systemd service files and start the daemons
. distribute-kube-controller-manager-binary.sh
. distribute-kube-controller-manager-certs.sh
. gen-kube-controller-manager-config.sh
. di... |
531b1ea3b2c35c308d669ed5d4e1c9f3775c03ae | 1,061 | #!/bin/bash
# wipe any stale screens
#sudo -u minecraft screen -wipe
# First, check if the server is even running. If not, then do nothing and exit.
if screen -ls minecraft/ | grep 'Private\|Attached\|Detached'; then
echo server active, backing up
# save the world
sudo -u minecraft screen -X stuff "say Preparing fo... |
e1a583e2f083c6f44c3b4d8188b73a0c24a985ac | 143 | #!/bin/bash
echo 将当前目录下所有后缀为.sh的文件添加到压缩包
for i in `find . -name "*.sh"`
do
`tar -czf all.taz $i`
done
|
652e7488256cd2c651eb52d164b97501083ceee6 | 597 | #!/bin/bash -ex
sudo /var/vcap/bosh/bin/monit
sleep 5
for process in \
postgres \
nats
do
sudo /var/vcap/bosh/bin/monit start $process
sleep 30
done;
sudo /var/vcap/bosh/bin/monit start all
echo "Waiting for all processes to start"
for ((i=0; i < 120; i++)); do
if ! (sudo /var/vcap/bosh/bin/mon... |
631f087b737d4d3caa6f8470c2a6eb446ac76ed4 | 359 | #!/bin/bash -x
read -p "Enter a number:" Number
case $Number in
0)
printf "Zero"
;;
1)
printf "One"
;;
2)
printf "Two"
;;
3)
printf "Three"
;;
4)
printf "Four"
;;
5)
printf "Five"
;;
6)
printf "Six"
;;
7)
printf "Seven"
;;
8)
printf "Eight"
;;
9)
printf "Nine"
;;
10) ... |
d320dfa5a55bd460f45565f46b5127dc90c67441 | 183 | #!/bin/bash
echo -ne "LED"
echo -ne "\x01"
echo -ne "\xff\x0f\x00\x00"
echo -ne "\x3c"
echo -ne "\x00\x01\x00\x00"
for ((i = 0; i < 256; ++ i)); do
./genled.sh $i $i $i 12
done
|
e04f603323a3e7e8e8a347bb1ec7362f7331eeb3 | 820 | #!/bin/bash
exec scala "$0" "$@"
!#
import scala.io.Source
object LongLines {
def processFile(filename :String, width:Int){
val source = Source.fromFile(filename)
for(line <- source.getLines()){
processLine(filename, width, line)
}
}
def processLine(filename: String, width : Int, line:String)... |
582542e9e3e2446a662812dece939f3b629654cb | 189 | #!/bin/bash
set -e
export TERM=xterm
useradd -M -N -g "$(grep -e "^staff:" /etc/group | cut -d':' -f 3)" -s /bin/bash tsutsu
mv /tmp/skel /home/tsutsu
chown -R tsutsu:staff /home/tsutsu
|
1c6135341897995a5203833237b6f1da8bf7d14f | 667 | #!/usr/bin/env bash
# *******************************************************************
# * Author : cuiyunpeng
# * Email : @163.com
# * Create time : 2020-08-02 13:22
# * Last modified : 2020-08-02 13:22
# * Filename : login_mysql.sh
# * Description :
#启动
docker run --name mysql -p 3306:330... |
f750465c09172311a80bb830d48c50ced67b08fb | 7,070 | curl -o /tmp/install_salt.sh -L https://bootstrap.saltstack.com && sh /tmp/install_salt.sh -Z -M git v2015.5.3
# reuse ssh key pair found in the repo
export PUBLIC_KEY=`cat ~/.ssh/id_rsa.pub | cut -d ' ' -f 2`
cat > /etc/salt/roster <<EOF
node1:
host: 158.85.79.185
priv: /root/.ssh/id_rsa
node2:
host: 158.85.79.... |
d3d572932a237473171939df363e16e026e478b4 | 428 | APP=dev
PORT=3000
DB_DIALECT=mysql
DB_HOST=localhost
DB_PORT=3306
DB_NAME=dbNameChange
DB_USER=rootChange
DB_PASSWORD=passwordChange
JWT_ENCRYPTION=PleaseChange
JWT_EXPIRATION=10000
BACKEND_URL=http://localhost:3000
FRONTEND_URL=http://localhost:4200
ACCESS_ALLOW_ORIGIN=http://localhost:4200
SMTP_PORT=4650
MAIL_C... |
390172699111830921a81c4b1ed7dda956f69a04 | 34 | #!/bin/bash
iptables -t nat -vnL
|
f3970d491acd9e65a223340d715ebf898bc62cfb | 39 | #!/bin/sh
python ./example_auction.py
|
ddf75fa706a91b4bfaeaf2e6ee1f46a7b5fee5b7 | 91 | MAILBLUSTER_API_KEY=redacted
SOURCE_FILE=export.customers.2020.11.26.02.43.43-e5ae7e0a.csv
|
e0263a846a76196f0ee70f3d93149f024282fa24 | 62 | JWT_TOKEN = HNXN_"+rS6882[KEct_Rz9L!{3gkge9VHwR2E>Uz8;!Vpv7Bvb |
5eb049c4448d3966aba5526180336c25855deba9 | 122 | NODE_ENV=development
CONTENTFUL_SPACE_ID=heiwjzet8gfx
CONTENTFUL_API_KEY=xyz
MEETUP_API_KEY=xyz
POSTMARK_SERVER_TOKEN=xyz
|
21ebcaf369e57ca5ada37cb00daad2d2ea40690e | 96 | #!/bin/sh
wget http://simh.trailing-edge.com/kits/ibm1130software.zip
unzip ibm1130software.zip
|
ffcabb0f094af7fd36784b1bbe294d0e6ed9c9c0 | 499 | #/usr/bin/env bash
pushd sandbox
git merge feature-1
git merge feature-2
# Resolving conflict; should be done using editor
echo This should be line 1 > file.txt
echo This should be line 3 >> file.txt
git add file.txt
git commit --no-edit
git merge feature-3
echo This should be line 1 > file.txt
echo This should ... |
231d21db7d146469ef10fab36d338ca5de5b2b02 | 3,169 | #!/usr/bin/env bash
set -e
HELP=
BOOTSTRAP=
PLAYBOOK=
PASS=
DEBUG=
SUCCESS=
SUDOERS_DEVSTRAP="/etc/sudoers.d/devstrap"
trap cleanup EXIT
function cleanup() {
set +e
if [ -f "$SUDOERS_DEVSTRAP" ]; then
sudo rm -f $SUDOERS_DEVSTRAP
fi
sudo -k
if [ -z "$SUCCESS" ]; then
echo_error "devstrap failed"... |
6840a55aefd6775f9d6b159b2ab24e4aafc99935 | 70 | curl -v -X DELETE http://xxx:8083/connectors/cyder-elk-sink-connector
|
1a88b4b67fb8b69e602ddcfa95b5e040c4f31d59 | 1,373 | #!/bin/bash
source /etc/config/cert-renew
# fwd logs to docker log collector
ln -sf /dev/stdout /var/log/cert-renew.log
# soft link /etc/letsencrypt locally from $LETSENCRYPT_DIR volume mount
while [ ! -d "$LETSENCRYPT_DIR" ]
do
sleep 2
done
ls -alh $LETSENCRYPT_DIR
rm -rf /etc/letsencrypt
ln -s "$LETSENCRYPT_DIR"... |
4f38da04d87a45afec131813aefd546251d1a27b | 353 | #!/bin/bash
while [[ $headcount -ne 11 && $tailcount -ne 11 ]]
do
coinflipped=$(( $RANDOM%2 ))
if [[ $coinflipped -eq 1 ]]
then
echo Heads
headcount=$(( $headcount+1 ))
else
echo Tails
tailcount=$(( $tailcount+1 ))
fi
done
echo headcount: $headcount and tailcount $tailcount
if [[ headcount -ge 11 ]]
then
echo he... |
503aa0cf5dbc897bfd516ddeaf8c259ef04e3b2d | 1,741 | #! /bin/bash
function peval { echo -e ">>> $@"; eval "$@"; }
echo -e "Starting job at ..." `date`
DATE_START=`date +%s`
[ -z "$1" ] && echo ">>> FED is not given as input!" && exit 1
run=$RUN
fed=$1
ext='dmp'
rundir=$RUNDIR
indir=$INDIR
outdir=$OUTDIR
workdir="$TMPDIR/job_GainCalib_${run}_${fed}"
logdir="${rundir}/jo... |
eb9b30f997c91fb741f6cb4a8d4a55225873261a | 1,161 | #!/bin/bash
CXX_STD=CXX11
ITKDIR=`${R_HOME}/bin/Rscript -e 'a<-ITKR:::itkDir(); cat(a)'`
# get a version of cmake
CMAKE_BUILD_TYPE=Release
# get / set up ANTs code
gh=https://github.com/pyushkevich/greedy
git clone $gh greedydir
mkdir -p src
cd ./src
echo "execs = c('greedy', 'lddmm', 'libgreedyapi.a', 'test_accum')... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.