[freenet-cvs] r18530 - in trunk/apps/new_installer: . res/unix/bin res/windows res/windows/bin
Florent Daignière
nextgens at freenetproject.org
Sat Mar 15 02:54:16 UTC 2008
* Matthew Toseland <toad at amphibian.dyndns.org> [2008-03-14 18:35:50]:
> Is there any chance of doing the browser detection and profile creation in the
> start script if it hasn't already been done? We want to be able to complain
> to the user if they don't have firefox ... and then automatically create a
> profile and use it when they do install it.
Done in r18539
>
> On Friday 14 March 2008 17:06, nextgens at freenetproject.org wrote:
> > Author: nextgens
> > Date: 2008-03-14 17:06:01 +0000 (Fri, 14 Mar 2008)
> > New Revision: 18530
> >
> > Added:
> > trunk/apps/new_installer/res/unix/bin/browse.sh
> > trunk/apps/new_installer/res/windows/browse.cmd
> > Modified:
> > trunk/apps/new_installer/Unix_shortcutSpec.xml
> > trunk/apps/new_installer/res/unix/bin/1run.sh
> > trunk/apps/new_installer/res/unix/bin/detect_port_availability.sh
> > trunk/apps/new_installer/res/windows/bin/install_ff_profile.cmd
> > trunk/apps/new_installer/res/windows/bin/install_wrapper.cmd
> > Log:
> > new_installer: second part of the patch... not tested on windows but who
> cares?
> >
> > Modified: trunk/apps/new_installer/Unix_shortcutSpec.xml
> > ===================================================================
> > --- trunk/apps/new_installer/Unix_shortcutSpec.xml 2008-03-14 15:14:49 UTC
> (rev 18529)
> > +++ trunk/apps/new_installer/Unix_shortcutSpec.xml 2008-03-14 17:06:01 UTC
> (rev 18530)
> > @@ -11,17 +11,21 @@
> > applications="no"
> > startMenu="no"
> > startup="no"
> > + target="$INSTALL_PATH/bin/browse.sh"
> > + commandLine=""
> > +
> > + initialState="noShow"
> > iconFile="$INSTALL_PATH/freenet.ico"
> > iconIndex="0"
> > - type="Link"
> > - url="http://localhost:8888"
> > + workingDirectory="$INSTALL_PATH"
> > + type="Application"
> > encoding="UTF-8"
> > createForAll="false"
> > description="Open the Freenet web interface in a browser">
> >
> > <createForPack name="Base" />
> > </shortcut>
> > -
> > +
> > <shortcut
> > name="The Freenet Project Website"
> > programGroup="yes"
> >
> > Modified: trunk/apps/new_installer/res/unix/bin/1run.sh
> > ===================================================================
> > --- trunk/apps/new_installer/res/unix/bin/1run.sh 2008-03-14 15:14:49 UTC
> (rev 18529)
> > +++ trunk/apps/new_installer/res/unix/bin/1run.sh 2008-03-14 17:06:01 UTC
> (rev 18530)
> > @@ -16,4 +16,5 @@
> > else
> > HTMLFILE="file://$INSTALL_PATH/welcome.html"
> > fi
> > -java -Djava.net.preferIPv4Stack=true -cp bin/browser.jar
> BareBonesBrowserLaunch "$HTMLFILE"
> > +
> > +./bin/browse.sh "$HTMLFILE"
> >
> > Added: trunk/apps/new_installer/res/unix/bin/browse.sh
> > ===================================================================
> > --- trunk/apps/new_installer/res/unix/bin/browse.sh
> (rev 0)
> > +++ trunk/apps/new_installer/res/unix/bin/browse.sh 2008-03-14 17:06:01 UTC
> (rev 18530)
> > @@ -0,0 +1,18 @@
> > +#!/bin/sh
> > +
> > +INSTALL_PATH="${INSTALL_PATH:-$PWD}"
> > +cd "$INSTALL_PATH"
> > +
> > +if test $# -lt 1
> > +then
> > + URL="http://127.0.0.1:8888"
> > +else
> > + URL="$1"
> > +fi
> > +
> > +if test -e firefox.location
> > +then
> > + `cat firefox.location` -no-remote -p freenet "$URL" &
> > +else
> > + java -Djava.net.preferIPv4Stack=true -cp bin/browser.jar
> BareBonesBrowserLaunch "$URL" &
> > +fi
> >
> >
> > Property changes on: trunk/apps/new_installer/res/unix/bin/browse.sh
> > ___________________________________________________________________
> > Name: svn:executable
> > + *
> >
> > Modified: trunk/apps/new_installer/res/unix/bin/detect_port_availability.sh
> > ===================================================================
> > --- trunk/apps/new_installer/res/unix/bin/detect_port_availability.sh
> 2008-03-14 15:14:49 UTC (rev 18529)
> > +++ trunk/apps/new_installer/res/unix/bin/detect_port_availability.sh
> 2008-03-14 17:06:01 UTC (rev 18530)
> > @@ -17,8 +17,12 @@
> > FPROXY_PORT=9999
> > echo "Can not bind fproxy to 8889: force it to $FPROXY_PORT instead."
> > fi
> > +
> > cat welcome.html | sed "s/8888/$FPROXY_PORT/g" >welcome2.html
> > mv welcome2.html welcome.html
> > + cat bin/browse.sh | sed "s/8888/$FPROXY_PORT/g" > browse.sh
> > + mv browse.sh bin/browse.sh
> > +
> > if test -e firefox_profile/user.js
> > then
> > cat firefox_profile/user.js | sed "s/8888/$FPROXY_PORT/g" >user.js.tmp
> >
> > Modified: trunk/apps/new_installer/res/windows/bin/install_ff_profile.cmd
> > ===================================================================
> > --- trunk/apps/new_installer/res/windows/bin/install_ff_profile.cmd
> 2008-03-14 15:14:49 UTC (rev 18529)
> > +++ trunk/apps/new_installer/res/windows/bin/install_ff_profile.cmd
> 2008-03-14 17:06:01 UTC (rev 18530)
> > @@ -15,7 +15,7 @@
> >
> > :: creation of the profile
> > @echo Creating a Firefox profile for freenet
> > -@"%FIREFOX%" -no-remote -CreateProfile "freenet %INSTALL_PATH%\firefox_profile"
> > NUL
> >
> +@%FIREFOX% -no-remote -CreateProfile "freenet %INSTALL_PATH%\firefox_profile"
> > NUL
> >
> > @goto end
> > :noff
> >
> > Modified: trunk/apps/new_installer/res/windows/bin/install_wrapper.cmd
> > ===================================================================
> > --- trunk/apps/new_installer/res/windows/bin/install_wrapper.cmd 2008-03-14
> 15:14:49 UTC (rev 18529)
> > +++ trunk/apps/new_installer/res/windows/bin/install_wrapper.cmd 2008-03-14
> 17:06:01 UTC (rev 18530)
> > @@ -11,13 +11,12 @@
> > @set FPROXY_PORT=8889
> > @bin\cat.exe welcome.html | bin\sed.exe "s/8888/%FPROXY_PORT%/g" >
> welcome2.html
> > @move /Y welcome2.html welcome.html > NUL
> > + at bin\cat.exe browse.cmd | bin\sed.exe "s/8888/%FPROXY_PORT%/g" >
> browse2.cmd
> > + at move /Y browse2.cmd browse.cmd > NUL
> > :configure_fproxy
> > @echo fproxy.enable=true >>freenet.ini
> > @echo fproxy.port=%FPROXY_PORT% >>freenet.ini
> >
> > -:: Create a script for the "browse shortcut"
> > - at echo @start http://127.0.0.1:%FPROXY_PORT%/ > browse.cmd
> > -
> > :: Try to detect a free, available port for fcp
> > @set FCP_PORT=9481
> > @java -jar bin\bindtest.jar %FCP_PORT%
> > @@ -101,8 +100,8 @@
> >
> > @echo Spawning up a browser
> > @if not exist welcome.%ISO3_LANG%.html goto nol10n
> > - at start welcome.%ISO3_LANG%.html
> > + at browse welcome.%ISO3_LANG%.html
> > @goto endl10n
> > :nol10n
> > - at start welcome.html
> > + at browse welcome.html
> > :endl10n
> >
> > Added: trunk/apps/new_installer/res/windows/browse.cmd
> > ===================================================================
> > --- trunk/apps/new_installer/res/windows/browse.cmd
> (rev 0)
> > +++ trunk/apps/new_installer/res/windows/browse.cmd 2008-03-14 17:06:01 UTC
> (rev 18530)
> > @@ -0,0 +1,10 @@
> > + at set COUNT=0
> > + at for %%x in (%*) do ( @set /A COUNT=!COUNT!+1 )
> > + at if %COUNT% LSS 1 @set URL=http://127.0.0.1:8888/ else @set URL=%1
> > +
> > + at set /P FIREFOX=<firefox.location
> > + at if not defined FIREFOX goto noff
> > +@%FIREFOX% -no-remote -p freenet "%URL%"
> > + at exit
> > +:noff
> > + at start "%URL%"
> >
> > _______________________________________________
> > cvs mailing list
> > cvs at freenetproject.org
> > http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs
> >
> >
> _______________________________________________
> cvs mailing list
> cvs at freenetproject.org
> http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://emu.freenetproject.org/pipermail/cvs/attachments/20080315/1b84fe54/attachment.pgp
More information about the cvs
mailing list