Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Failing to write to history file if containing directory doesn't exist
- X-seq: zsh-users 12023
- From: "Richard Hartmann" <richih.mailinglist@xxxxxxxxx>
- To: "Matthew Wozniski" <godlygeek@xxxxxxxxx>
- Subject: Re: Failing to write to history file if containing directory doesn't exist
- Date: Wed, 17 Oct 2007 13:16:23 +0200
- Cc: zsh-users@xxxxxxxxxx
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=WC7BcBFxBjvXxBl+kjIlXMznfzeqT+93aK1jXl1UKkw=; b=WAD/mQkVCawhvhZpimqkwOczWqsanw6f0PbZaStGDG89Zs0Vp+rSEDEJ4nX81JwcYQb9FiCGv8A/p2NYzGWlNDH4cThCfgRW/GmaPP4ZoWpYUM4UC6+FQI2cdkPwEoJd8d+nJN1pR9zCICApvDooSJRdi9Q1dumDdRbHZgshhT0=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=TbZjz7wRmsNE98mFNUghNdUxuu2P0sJD0G345XXHI1il827DS86xtXYOzzw84GLCcRlnyuHCfhDHs7rx/oxKbcSYoKWr6ZCw1EUuodrFrPhG15wXmrxOR0aMKnMblR1MfViQgnqgSVzShpQB5asE65aM8e5CmsXfK+B3Yybq2bM=
- In-reply-to: <20071009015814.GA21038@mastermind>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <200710081015.l98AFlIU018448@xxxxxxxxxxxxxx> <200710081338.l98Dc2br012284@xxxxxxxxxxxxxx> <dbfc82860710080705w6e90db9i2a9714caf27460c4@xxxxxxxxxxxxxx> <20071008141403.GA25326@xxxxxxxxxxx> <20071008151949.GA18576@mastermind> <dbfc82860710080830r289c962eyde18f1564e7f0de0@xxxxxxxxxxxxxx> <20071008154632.GB18576@mastermind> <dbfc82860710081532m5672197crf568b7d120ab192f@xxxxxxxxxxxxxx> <071008184445.ZM25513@xxxxxxxxxxxxxxxxxxxxxx> <20071009015814.GA21038@mastermind>
On 09/10/2007, Matthew Wozniski <godlygeek@xxxxxxxxx> wrote:
> > History is only maintained for interactive shells, so you might get
> > more traction with an option to prompt the user to create the directory
> > and/or fix $HISTFILE when the file does not exist or is not writable.
If such an option were introduced, it could have potential security issues,
leaving a shell open that the user expects to close immediately (insert
CHECK_JOBS and HUP reference here).
> Along that vein, and still leaning towards a solution in shell code,
> might it be reasonable to put a precmd hook into the default
> /etc/zshrc to check up on HISTFILE? That seems like a compromise that
> allows everyone to get it but for it still to be maintained in shell,
> rather than c.
Perhaps check when the shell starts and in the history write function.
precmd should be as light as possible.
Richard
Messages sorted by:
Reverse Date,
Date,
Thread,
Author