-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathmk_snipsawin.sh
executable file
·67 lines (54 loc) · 1.75 KB
/
mk_snipsawin.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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
#!/bin/sh
set -e
#
# Win install:
# https://www.kannon.link/free/2019/06/24/distribution-using-a-python-embeddable-zip-file/
# - python.exe get-pip.py
# - python37._pth
# - python.exe -m pip install bs4
# - tkinter
#
#python embed and pre-installed tk/other libs as a corresponding zip is needed in the folder
SNIPSAWIN_DIR=snipsawin
PYTHON_EMBED=python-3.8.5-embed-amd64-preinstalled
echo Preparing Snipsa Windows package...
rm -rf $SNIPSAWIN_DIR/ || true
rm snipsawin.zip || true
mkdir $SNIPSAWIN_DIR
#python
echo Installing python environment ...
mkdir $SNIPSAWIN_DIR/$PYTHON_EMBED
unzip -q $PYTHON_EMBED.zip -d $SNIPSAWIN_DIR
echo python38.zip > temp._pth
echo . >> temp._pth
echo .\\Lib >> temp._pth
echo .\\DLLs >> temp._pth
echo ..\\snipsa >> temp._pth
echo import site >> temp._pth
mv temp._pth $SNIPSAWIN_DIR/$PYTHON_EMBED/python38._pth
#snipsa
echo Installing snipsa ...
mkdir $SNIPSAWIN_DIR/snipsa
cp \
haplomt.py haplomt_find.py haplomt_db_import.py \
haploy.py haploy_find.py haploy_db_import.py \
haploy_anno_import.py \
snpload.py \
bamload.py \
snipsa-gui.py \
$SNIPSAWIN_DIR/snipsa/
#DB licenses included in implementation
#TODO: FTDNA
cp haplomt_map.txt haploy_map2j.txt haploy_annodb_example.txt haploy_annodb_yfull.txt haploy_annodb_ancientdna.txt $SNIPSAWIN_DIR/snipsa/
# Ybrowse (CC BY-NC-SA 3.0)
# https://isogg.org/wiki/ISOGG_Wiki:Terms_of_Use
#cp str_hg19.gff3 str_hg38.gff3 snps_hg38.gff3 $SNIPSAWIN_DIR/snipsa/
cp str_hg19.gff3 str_hg38.gff3 $SNIPSAWIN_DIR/snipsa/
#http://May2021.archive.ensembl.org/info/about/legal/disclaimer.html free use license
cp -a crossmap $SNIPSAWIN_DIR/snipsa/
#starter
cp snipsa.bat $SNIPSAWIN_DIR/
echo Zipping Snipsa Windows package...
zip -q -r snipsawin.zip $SNIPSAWIN_DIR/
rm -rf $SNIPSAWIN_DIR/
echo Done!