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 -xe | |
echo "USAGE ./generate_gigapan.sh </dir/to/images> <output_prefix> <#threads>" | |
tmp=/tmp/hugin_batch_script_$RANDOM | |
mkdir -p $tmp | |
initial_pto="$tmp/$RANDOM.pto" | |
cp_pto="$tmp/$RANDOM.pto" |
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 | |
if [ $# -lt 1 ] | |
then | |
echo "USAGE: $0 <block device>" | |
exit 1 | |
fi | |
read -p "about to format $1, Are you sure?" -n 1 -r | |
echo # (optional) move to a new line | |
if [[ $REPLY =~ ^[Yy]$ ]] |
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
Command being timed: "bash -xe generate_gigapan.sh ./ test1 16" | |
User time (seconds): 1913.30 | |
System time (seconds): 1.43 | |
Percent of CPU this job got: 111% | |
Elapsed (wall clock) time (h:mm:ss or m:ss): 28:39.25 | |
Average shared text size (kbytes): 0 | |
Average unshared data size (kbytes): 0 | |
Average stack size (kbytes): 0 | |
Average total size (kbytes): 0 | |
Maximum resident set size (kbytes): 402464 |
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
WITH 16 CORES | |
Command being timed: "bash -xe generate_gigapan.sh ./ test1 16" | |
User time (seconds): 1913.30 | |
System time (seconds): 1.43 | |
Percent of CPU this job got: 111% | |
Elapsed (wall clock) time (h:mm:ss or m:ss): 28:39.25 | |
Average shared text size (kbytes): 0 | |
Average unshared data size (kbytes): 0 | |
Average stack size (kbytes): 0 |
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 | |
if [ $# -lt 1 ] | |
then | |
echo "USAGE: $0 <block device>" | |
exit 1 | |
fi | |
devs=($1*) | |
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 | |
if [ $# -lt 1 ] | |
then | |
echo "USAGE: $0 <block device> $1 <name>" | |
exit 1 | |
fi | |
tmp=/tmp/SPC-OS_rename-$RANDOM | |
mkdir -p $tmp/root |
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 | |
if [ $# -lt 1 ] | |
then | |
echo "USAGE: $0 <block device>" | |
exit 1 | |
fi | |
read -p "About to format $1, Are you sure (y/N)?" -n 1 -r | |
echo | |
if [[ $REPLY =~ ^[Yy]$ ]] | |
then |
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
# Initialisation | |
sudo rsync -avhP ./etc/init/leapd.conf /etc/ | |
# Device rules | |
sudo rsync -avhP ./lib/udev/rules.d/25-com-leapmotion-leap.rules /lib/udev/rules.d/ | |
# Daemon | |
sudo rsync -ahvP ./usr/sbin/leapd /usr/sbin | |
# Executables |
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
# extract package data | |
pattern="Leap-2.*x64.deb" | |
files=( $pattern ) | |
ar vx ${files[0]} | |
tar -xf data.tar.xz | |
# Initialisation | |
sudo rsync -avhP ./etc/init/leapd.conf /etc/ | |
# Device rules |
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
location ~* \~(.*)/(.*$) { | |
auth_basic "Restricted"; | |
auth_basic_user_file /home/$1/public_html/.htpasswd; | |
alias /home/$1/public_html/$2; | |
} |
OlderNewer