forked from jlmcgraw/aviationCharts
-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.sh
executable file
·35 lines (28 loc) · 841 Bytes
/
setup.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/bash
set -eu # Always put this in Bourne shell scripts
IFS=$(printf '\n\t') # Always put this in Bourne shell scripts
#Install various utilities
sudo \
apt-get install \
pngquant \
graphicsmagick \
python-gdal \
unzip \
imagemagick \
cpanminus \
python-imaging \
perltidy \
carton \
gdal-bin
carton install
#Get some utilities
git clone https://github.com/jlmcgraw/parallelGdal2tiles.git
git clone https://github.com/mapbox/mbutil.git
git clone https://github.com/jlmcgraw/tilers_tools.git
#Setup hooks to run perltidy on git commit
cat > .git/hooks/pre-commit << 'EOF'
#!/bin/bash
find . -maxdepth 1 -type f -name '*.pl' -or -name '*.pm' | \
xargs -I{} -P0 sh -c 'perltidy -b -noll {}'
EOF
chmod +x .git/hooks/pre-commit