We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
This would allow the following to work (open a file where I left):
Initial setup:
mkdir -p $XDG_DATA_HOME/kakoune sqlite3 $XDG_DATA_HOME/kakoune/info.db << 'INIT' CREATE TABLE recent ( file VARCHAR(200) UNIQUE, pos VARCHAR(20), stamp INTEGER ); CREATE INDEX _file ON recent (file); INIT
In kakrc:
hook global BufWritePre .* %{ %sh{ sqlite3 $XDG_DATA_HOME/kakoune/info.db "INSERT or REPLACE into recent (file, pos, stamp) values ('$kak_buffile', '$kak_selections_desc', strftime('%s', 'now'));" } } hook global BufOpen .* %{ %sh{ if [ -f "$kak_buffile" ] then selections=$(sqlite3 "$XDG_DATA_HOME"/kakoune/info.db "SELECT pos from recent where file = '$kak_buffile';") [ -n "$selections" ] && printf '%s\n' "select $selections" fi } }
The text was updated successfully, but these errors were encountered:
What's "not working" in the code you gave?
Sorry, something went wrong.
Quote from @mawww:
and if you were using WinCreate, that does not run in the client context (unfortunately), so you wont be modifying the actual user selections
Ok the issue is with selections, can't you use kak -p or the eval -client ?
kak -p
eval -client
No branches or pull requests
This would allow the following to work (open a file where I left):
Initial setup:
In kakrc:
The text was updated successfully, but these errors were encountered: