[GRASS-SVN] r31030 - grass/trunk/lib/init
svn_grass at osgeo.org
svn_grass at osgeo.org
Fri Apr 18 17:42:06 EDT 2008
Author: hamish
Date: 2008-04-18 17:42:05 -0400 (Fri, 18 Apr 2008)
New Revision: 31030
Modified:
grass/trunk/lib/init/init.sh
Log:
longer command history for csh,cygwin (trac #132)
Modified: grass/trunk/lib/init/init.sh
===================================================================
--- grass/trunk/lib/init/init.sh 2008-04-18 18:15:06 UTC (rev 31029)
+++ grass/trunk/lib/init/init.sh 2008-04-18 21:42:05 UTC (rev 31030)
@@ -885,7 +885,7 @@
tcshrc="$HOME/.tcshrc"
rm -f "$cshrc" "$tcshrc"
echo "set home = $USERHOME" > "$cshrc"
- echo "set history = 500 savehist = 500 noclobber ignoreeof" >> "$cshrc"
+ echo "set history = 3000 savehist = 3000 noclobber ignoreeof" >> "$cshrc"
echo "set histfile = $HOME/.history" >> "$cshrc"
echo "set prompt = '\\" >> "$cshrc"
@@ -959,6 +959,15 @@
;;
cygwin)
+ # save command history in mapset dir and remember more
+ export HISTFILE="$LOCATION/.bash_history"
+ if [ -z "$HISTSIZE" ] && [ -z "$HISTFILESIZE" ] ; then
+ export HISTSIZE=3000
+ fi
+
+ # instead of changing $HOME, start bash with: --rcfile "$LOCATION/.bashrc" ?
+ # if so, must care be taken to explicity call .grass.bashrc et al for
+ # non-interactive bash batch jobs?
USERHOME="$HOME" # save original home
HOME="$LOCATION" # save .bashrc in $LOCATION
export HOME
More information about the grass-commit
mailing list