Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: An example of writing a custom history file?
On Dec 15, 9:26am, Rocky Bernstein wrote:
}
} Almost there! The only remaining problem is now how write the accumulated
} history. For that, I assume I use fc -W *filename* or fc -A *filename*.
I don't really mind helping you out here, but if you were to actually
read the documentation for the "fc" command or even look more closely
at the way it's used in sticky-note you should be able to figure this
out for yourself.
} #!/usr/bin/zsh
} fc -ap /tmp/example_history 1000
You need to supply another argument to "fc -ap" telling it what the
maximum size of the saved file is. Then that number of lines will
be saved automatically when the current function goes out of scope.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author