Update of /cvsroot/gtkpod/gtkpod/scripts
In directory sc8-pr-cvs2.sourceforge.net:/tmp/cvs-serv30956/scripts

Modified Files:
        sync-webcalendar.sh 
Log Message:
        * scripts/sync-webcalendar.sh: applied patch from Giray Devlet
          for support of differently named calendars.



Index: sync-webcalendar.sh
===================================================================
RCS file: /cvsroot/gtkpod/gtkpod/scripts/sync-webcalendar.sh,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- sync-webcalendar.sh 15 Jun 2005 14:02:34 -0000      1.1
+++ sync-webcalendar.sh 4 Feb 2007 12:56:20 -0000       1.2
@@ -3,15 +3,19 @@
 # sync ipod with webcalendar
 
 # Usage:
-# 
-# sync-webcalendar.sh [-i <ipod mountpoint>] [-d <webcalendar uri>]
 #
-# with the following defaults: 
-
-IPOD_MOUNT='/mnt/ipod'                         # mount point of ipod
-DATAFILE='https://native.intern.net/projekte/webcalendar/publish.php/daniel.ics'
       # uri for webcalendar
+# sync-webcalendar.sh [-i <ipod mountpoint>] [-d <webcalendar uri>] [-c 
<calendar name>]
+#
+# with the following defaults:
 
-WGET_OPTIONS='--no-check-certificate'                                          
        # special options for wget
+# mount point of ipod
+IPOD_MOUNT='/mnt/ipod'
+# uri for webcalendar
+DATAFILE=' 
https://native.intern.net/projekte/webcalendar/publish.php/daniel.ics'
+# calendar name
+CALENDAR='webcalendar'
+# special options for wget
+WGET_OPTIONS='--no-check-certificate'
 
 # About the encoding used by the iPod (by Jorg Schuler):
 #
@@ -31,21 +35,26 @@
 # Japanese           SHIFT-JIS
 
 # Changelog
+#
+# 2007/02/01 (Giray Devlet <[EMAIL PROTECTED]>): Multi Calendar Support
+#
 # 2005/06/15 (Jorg Schuler <jcsjcs at users dot sourceforge dot net>):
 # Received original script from Daniel Kercher and added command line
 # options
+#
 # FIXME: some way to convert the character set
 
 # overwrite default settings with optional command line arguments
-while getopts i:d: option; do
+while getopts i:d:c: option; do
     case $option in
         i) IPOD_MOUNT=$OPTARG;;
         d) DATAFILE=$OPTARG;;
-        \?) echo "Usage: `basename $0` [-i <ipod mountpoint>] [-d <webcalendar 
uri>]"
-           exit 1;;
+        c) CALENDAR=$OPTARG;;
+        \?) echo "Usage: `basename $0` [-i <ipod mountpoint>] [-d <webcalendar 
uri>] [-c <calendar_name>]"
+            exit 1;;
     esac
 done
 
-echo -n "Syncing webcalendar to iPod... "
-wget -q $WGET_OPTIONS -O ${IPOD_MOUNT}/Calendars/webcalendar.ics $DATAFILE
+echo -n "Syncing Web Calendar \"${CALENDAR}\" to iPod... "
+wget -q $WGET_OPTIONS -O ${IPOD_MOUNT}/Calendars/${CALENDAR}.ics $DATAFILE
 echo "done!"


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
gtkpod-cvs2 mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gtkpod-cvs2

Reply via email to