fix for puburl

This commit is contained in:
ville rantanen
2013-11-08 08:29:17 +02:00
parent 0d4ea78b05
commit 3386248c52

View File

@@ -1,16 +1,17 @@
#!/bin/bash #!/bin/bash
if [ ! -e "$HOME/.aerofs/pub.root" ] MyRoot=$( sqlite3 $HOME/.aerofs/conf "SELECT v FROM c WHERE k = 'root';" )/Public/
then echo file "$HOME/.aerofs/pub.root" not found.
if [ ! -e "$MyRoot/.pubroot" ]
then echo file "$MyRoot/.pubroot" not found.
echo it must contain the string of your http server with pub files. echo it must contain the string of your http server with pub files.
echo ex. http://server.com:7777/ echo ex. http://server.com:7777/
exit 1 exit 1
fi fi
MyRoot=$( sqlite3 $HOME/.aerofs/conf "SELECT v FROM c WHERE k = 'root';" )/Public/
MyServerRoot=$( cat "$HOME/.aerofs/pub.root" | tr -d "[:cntrl:]" ) MyServerRoot=$( cat "$MyRoot/.pubroot" | tr -d "[:cntrl:]" )
if [ -z "$1" ] if [ -z "$1" ]
then echo provide filename then echo provide filename