Handling of themes without buttons or backgrounds to theme_upload_dlg.
[irreco.git] / script / telnet-deb-creator.sh
blob65754a26c60c9ad866c27a106408829ea3402ed9
1 #!/bin/bash
3 # Go to folder where this file lies.
4 cd `dirname "$0"`
6 main()
8 case "$1" in
9 --deb|-deb|deb|.deb|debaa|debbaa|debioi)
10 make_deb;;
12 info_print;
13 exit 1;;
14 esac
17 info_print()
19 echo ""
20 echo " Usage: telnet-deb-creator.sh COMMAND"
21 echo ""
22 echo " Commands:"
23 echo " --deb | -deb | deb"
24 echo " This creates telnet backend .deb into ../debs/"
25 echo " Packaging requires that you have packaged and"
26 echo " installed Irreco dev package into Scratchbox."
27 echo ""
30 make_deb()
33 # Check we are in scratchbox
34 if [[ "$_SBOX_DIR" == "" ||
35 "$_SBOX_RESTART_FILE" == "" ||
36 "$_SBOX_SHELL_PID" == "" ||
37 "$_SBOX_USER_GROUPNAME" == "" ]]; then
38 echo "Error: Need scratchbox."
39 exit 1
42 # Go to telnet backend directory, clean stuff and build package
43 cd ../backend/telnet/trunk/
44 echo " Run autoclean"
45 ./autoclean.sh
46 echo " Run dpkg-buildpackage"
47 dpkg-buildpackage -rfakeroot -i
49 # Check there is place to ditch deb
50 if [ ! -e "../../../debs/" ]; then
51 mkdir -v ../../../debs/
54 # Ditch .deb to correct directory
55 #mv -fv ../irreco-backend-telnet* ../../../debs/
57 # Do cleaning
58 echo " Do clean"
59 #./autoclean.sh
60 echo " Done clean"
64 main "$@"