Commit graph

19 commits

Author SHA1 Message Date
1a58909e94
Rename create_link to make_link
Should prepare the differentiation between a 'new' link and linking an
existing zetttel -- one is 'new_link' and one just 'makes_link' to
something else.
2021-05-04 09:46:18 +02:00
4e3d364d17
Add word under cursor and (manual) mode selection 2021-05-03 23:02:59 +02:00
2310f4a2d0
Implement initial selection link creation 2021-05-03 17:31:28 +02:00
3f3e5ec7c2
Remove bignumber allocation, refactor open function
Switched out manual BIGNUMBER creation for the lua inbuilt `math.huge`.
Refactored `open_selected` a tiny bit in preparation for automatic link
creation.
2021-04-30 17:32:03 +02:00
9dcd2556ba
Rename list module to files module
Renamed to 'files.lua' since it is the only module actively working on
the underlying filesystem so far -- gathering existing files and zettel
in the directories.
2021-04-30 15:30:43 +02:00
e4e6fca765
Fix unused variables and useless pending test 2021-04-30 13:28:00 +02:00
d29d92cc0a
Remove hardcoded options, do repo house-cleaning
Update readme and tmux.session file.

Remove unused tests, update option calling.
2020-11-04 22:27:30 +01:00
aef7d29997
Add action module
Action module contains the interactions the user can take directly with
the zettelkasten, and which in turn act on the editor.

First action to be taken is the opening of zettel links.
`action.open(mytext)` allows the user to pass in a md/wikilink-formatted
string from which the function will open the first found in the current
buffer.

`action.open_selected()` does the same, but looks at the cursor context
to get its string (the link under current cursor position as of now; in
the future probably also the next link on current line, and the first
link in visual selection)
2020-10-31 14:17:26 +01:00
320007e14b
Move anchor prepend function to anchor module 2020-10-31 11:05:30 +01:00
cac9720d35
Refactor anchor and link functions into files 2020-10-30 16:30:37 +01:00
ece30350c2
Refactor options to separate file
Options were previously set ad-hoc in the initialize function, but
re-set and overwritten at various places.

Options now live in one central module (options.lua), where they
directly access the neovim options set, and re-access them on any run.

That means options can be changed while the plugin is running and it
will use their newer versions, without requiring any re-initialization.
2020-10-30 16:04:23 +01:00
441cbcbc63
Fix zettel listing obeying zettel extension option 2020-10-29 19:09:56 +01:00
e5afcb5e15
Reformat lua code with lua-format 2020-10-29 19:00:23 +01:00
a365cef6c7
Move intended features to README 2020-10-29 18:41:05 +01:00
1c44f244e4
Refactor list functions and options
Moved list functionality into separate file list.lua.
Moved zettelkasten options from local variables to table-scoped
variables, initialized in ZK.init().
2020-10-29 18:17:00 +01:00
72f84898f0
Add recursive file listing 2020-10-29 15:22:51 +01:00
7e77b616ea
Add simple anchor listing functionality 2020-10-29 12:18:19 +01:00
c7236ad295
Add Datestamp and Link creation functionality 2020-10-26 19:32:27 +01:00
86ab71b1d6
Initial commit 2020-10-26 15:55:40 +01:00