[sqlite] Customizing the location of the .sqlite_history

2016-02-03 Thread Keith Medcalf

> Jes Slow  wrote:
> 
> > Many applications do this by allowing the user to set an environment
> > variable to customize the location, altho personally I would prefer
> > another way since environment variables are also global.
> 
> Global?  Environment variables are per-process, and changeable by the
> process with putenv(3).

Each process when it starts gets a "copy" of its parent process environment, 
which it may modify and will be "copied" to its children.  The "first process" 
creates the "first environment" by copying from its parent (NUL) and passing 
its modifications along to its children.









[sqlite] Customizing the location of the .sqlite_history

2016-02-02 Thread James K. Lowden
On Sun, 31 Jan 2016 21:46:18 -0800
Jes Slow  wrote:

> Many applications do this by allowing the user to set an environment
> variable to customize the location, altho personally I would prefer
> another way since environment variables are also global. 

Global?  Environment variables are per-process, and changeable by the
process with putenv(3).  

--jkl


[sqlite] Customizing the location of the .sqlite_history

2016-02-01 Thread Rowan Worth
sqlite3() {
confs='.sqlite_history .sqliterc'
for c in $confs; do ln -s ~/.config/$c ~/$c; done
(sleep 10; cd; rm $confs)&
command sqlite3 "$@"
}

Alternately, simply create a new user with home directory matching your
~/.config, and su to that user to run sqlite3.

(no, neither of these suggestions are serious :P)
-Rowan

On 1 February 2016 at 13:46, Jes Slow  wrote:

> Hi - this is kind of a trivial request, but .sqlite_history is one of the
> relatively few files that I can't move into ~/.config folder (or wherever
> it fits).
>
> We know that globals can become messy as you scale, and up until the XDG
> standard applications treated the home folder as their global place to drop
> configuration files. When you have dozens of programs, that starts to get
> messy.
>
> Many applications do this by allowing the user to set an environment
> variable to customize the location, altho personally I would prefer another
> way since environment variables are also global. Hope you consider it.
> Thanks
> ___
> sqlite-users mailing list
> sqlite-users at mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
>


[sqlite] Customizing the location of the .sqlite_history

2016-01-31 Thread Jes Slow
Hi - this is kind of a trivial request, but .sqlite_history is one of the
relatively few files that I can't move into ~/.config folder (or wherever
it fits).

We know that globals can become messy as you scale, and up until the XDG
standard applications treated the home folder as their global place to drop
configuration files. When you have dozens of programs, that starts to get
messy.

Many applications do this by allowing the user to set an environment
variable to customize the location, altho personally I would prefer another
way since environment variables are also global. Hope you consider it.
Thanks