[Pkg-chromium-commit] chromium-browser/chromium-browser.sid: 599 [ Fabien Tassin ]

Giuseppe Iuculano iuculano at debian.org
Wed Jun 9 09:56:06 UTC 2010


Branch name: chromium-browser/chromium-browser.sid
Branch location : bzr+ssh://bzr.debian.org/bzr/pkg-chromium/chromium-browser/chromium-browser.sid
Browse location: http://bzr.debian.org/loggerhead/pkg-chromium
Revision No: 599
Revision Id: iuculano at debian.org-20100609095606-azovhzdb01nkv9l5
Committer: Giuseppe Iuculano <iuculano at debian.org>
Message : [ Fabien Tassin ]
* Add a --temp-profile knob to the launcher script starting Chromium with
  a new profile which will last only for the duration of the session
  - update debian/chromium-browser.sh


--------------------------------------------------------
  ** Modified :
        - debian/changelog
        - debian/chromium-browser.sh

-------------- next part --------------
=== modified file 'debian/changelog'
--- a/debian/changelog	2010-06-09 09:48:27 +0000
+++ b/debian/changelog	2010-06-09 09:56:06 +0000
@@ -1,5 +1,11 @@
 chromium-browser (5.0.375.70~r48679-1) UNRELEASED; urgency=low
 
+  [ Fabien Tassin ]
+  * Add a --temp-profile knob to the launcher script starting Chromium with
+    a new profile which will last only for the duration of the session
+    - update debian/chromium-browser.sh
+  
+  [ Giuseppe Iuculano ]
   * New upstream stable release, this release fixes the following security
     issues:
     - [15766] Medium Cross-origin keystroke redirection.
@@ -15,7 +21,7 @@
     - [44955] High Memory corruption in rendering of list markers.
 
 
- -- Giuseppe Iuculano <iuculano at debian.org>  Wed, 09 Jun 2010 11:41:07 +0200
+ -- Giuseppe Iuculano <iuculano at debian.org>  Wed, 09 Jun 2010 11:55:41 +0200
 
 chromium-browser (5.0.375.55~r47796-1) unstable; urgency=low
 

=== modified file 'debian/chromium-browser.sh'
--- a/debian/chromium-browser.sh	2009-12-15 22:29:56 +0000
+++ b/debian/chromium-browser.sh	2010-06-09 09:56:06 +0000
@@ -11,10 +11,11 @@
 GDB=/usr/bin/gdb
 
 usage () {
-  echo "$APPNAME [-h|--help] [-g|--debug] [options] [URL]"
+  echo "$APPNAME [-h|--help] [-g|--debug] [--temp-profile] [options] [URL]"
   echo
   echo "        -g or --debug           Start within $GDB"
   echo "        -h or --help            This help screen"
+  echo "        --temp-profile          Start with a new and temporary profile"
   echo
   echo " Other supported options are:"
   MANWIDTH=80 man chromium-browser | sed -e '1,/OPTIONS/d; /ENVIRONMENT/,$d'
@@ -47,6 +48,7 @@
 export CHROME_VERSION_EXTRA=Ubuntu
 
 want_debug=0
+want_temp_profile=0
 while [ $# -gt 0 ]; do
   case "$1" in
     -h | --help | -help )
@@ -55,6 +57,9 @@
     -g | --debug )
       want_debug=1
       shift ;;
+    --temp-profile )
+      want_temp_profile=1
+      shift ;;
     -- ) # Stop option prcessing
       shift
       break ;;
@@ -63,6 +68,11 @@
   esac
 done
 
+if [ $want_temp_profile -eq 1 ] ; then
+  TEMP_PROFILE=`mktemp -d`
+  CHROMIUM_FLAGS="$CHROMIUM_FLAGS --user-data-dir=$TEMP_PROFILE"
+fi
+
 if [ $want_debug -eq 1 ] ; then
   if [ ! -x $GDB ] ; then
     echo "Sorry, can't find usable $GDB. Please install it."
@@ -79,8 +89,17 @@
   echo "#      CHROMIUM_FLAGS=$CHROMIUM_FLAGS"
   echo "$GDB $LIBDIR/$APPNAME -x $tmpfile"
   $GDB "$LIBDIR/$APPNAME" -x $tmpfile
+  if [ $want_temp_profile -eq 1 ] ; then
+    rm -rf $TEMP_PROFILE
+  fi
   exit $?
 else
-  exec $LIBDIR/$APPNAME $CHROMIUM_FLAGS "$@"
+  if [ $want_temp_profile -eq 0 ] ; then
+    exec $LIBDIR/$APPNAME $CHROMIUM_FLAGS "$@"
+  else
+    # we can't exec here as we need to clean-up the temporary profile
+    $LIBDIR/$APPNAME $CHROMIUM_FLAGS "$@"
+    rm -rf $TEMP_PROFILE
+  fi
 fi
 



More information about the Pkg-chromium-commit mailing list