callirhoe/make_pkg
ph4ntome@gmail.com eac11c2455 Made sys.path manipulation in load_plugin a bit more pythonic.
Removed 2nd "try" inside plugin.py and made first work as George suggested.
Reverted to "resource:" to make it feel correct.


git-svn-id: https://callirhoe.googlecode.com/svn/branches/phantome@181 81c8bb96-aa45-f2e2-0eef-c4fa4a15c6df
2014-10-31 16:51:54 +00:00

38 lines
1014 B
Bash
Executable File

#!/bin/bash
# Create Callirhoe package
mkdir _callirhoe
./make_resources_list
cp -R geom holidays lang layouts lib style _callirhoe
cp callirhoe.py _callirhoe/__main__.py
mv resources.py _callirhoe/lib
cd _callirhoe
zip -q -r callirhoe.zip *
mv callirhoe.zip ../
cd ..
rm -rf _callirhoe
echo \#!/usr/bin/env python2 | cat - callirhoe.zip > callirhoe
chmod 755 callirhoe
rm callirhoe.zip
# Create Calmagick package
mkdir _calmagick
cp -R geom holidays lang layouts lib style _calmagick
cp callirhoe.py _calmagick
cp calmagick.py _calmagick/__main__.py
cd _calmagick
zip -q -r calmagick.zip *
mv calmagick.zip ../
cd ..
rm -rf _calmagick
echo \#!/usr/bin/env python2 | cat - calmagick.zip > calmagick
chmod 755 calmagick
rm calmagick.zip
# Create Makefile
echo install: > Makefile
echo install -m 0755 callirhoe "$""(prefix)"/bin >> Makefile
echo install -m 0755 calmagick "$""(prefix)"/bin >> Makefile
find holidays/ | sed 's/^/ install -m 644 /' | sed 's/$/ \$(prefix)\/share\/callirhoe/' >> Makefile