Orgmode clone written in Lua for Neovim 0.9.4+
[[#setup][Setup]] • [[/DOCS.md][Docs]] • [[#showcase][Showcase]] • [[#treesitter-info][Treesitter]] • [[#troubleshoot][Troubleshoot]] • [[#plugins][Plugins]] • [[CONTRIBUTING.md][Contributing]] • [[#thanks-to][Kudos]]
** Quickstart
*** Requirements
*** Installation
Use your favourite package manager:
{ 'nvim-orgmode/orgmode', event = 'VeryLazy', ft = { 'org' }, config = function() -- Setup orgmode require('orgmode').setup({ org_agenda_files = '~/orgfiles/*/', org_default_notes_file = '~/orgfiles/refile.org', })
-- NOTE: If you are using nvim-treesitter with ~ensure_installed = "all"~ option
-- add ~org~ to ignore_install
-- require('nvim-treesitter.configs').setup({
-- ensure_installed = 'all',
-- ignore_install = { 'org' },
-- })
end, }
use {'nvim-orgmode/orgmode', config = function() require('orgmode').setup{} end }
Plug 'nvim-orgmode/orgmode'
call dein#add('nvim-orgmode/orgmode')
*** Setup
Note that this setup is not needed for [[https://github.com/folke/lazy.nvim][lazy.nvim]] since instructions above covers full setup
-- init.lua
require('orgmode').setup({ org_agenda_files = {'~/Dropbox/org/*', '~/my-orgs/*/'}, org_default_notes_file = '~/Dropbox/org/refile.org', })
-- NOTE: If you are using nvim-treesitter with ~ensure_installed = "all"~ option -- add ~org~ to ignore_install -- require('nvim-treesitter.configs').setup({ -- ensure_installed = 'all', -- ignore_install = { 'org' }, -- })
Or if you are using ~init.vim~, wrap the above snippet like so:
" init.vim lua << EOF
require('orgmode').setup({ org_agenda_files = {'~/Dropbox/org/*', '~/my-orgs/*/'}, org_default_notes_file = '~/Dropbox/org/refile.org', })
EOF
**** Completion
require('cmp').setup({ sources = { { name = 'orgmode' } } })
vim.g.completion_chain_complete_list = { org = { { mode = 'omni'}, }, } -- add additional keyword chars vim.cmd[[autocmd FileType org setlocal iskeyword+=:,#,+]]
Or just use ~omnifunc~ via =
*** Usage
If you are new to Orgmode, see [[/DOCS.md#getting-started-with-orgmode][Getting started]] section in the Docs or a hands-on [[https://github.com/nvim-orgmode/orgmode/wiki/Getting-Started][tutorial]] in our wiki.
** Showcase
*** Agenda
[[https://user-images.githubusercontent.com/1782860/123549968-8521f600-d76b-11eb-9a93-02bad08b37ce.gif]]
*** Org file
[[https://user-images.githubusercontent.com/1782860/123549982-90752180-d76b-11eb-8828-9edf9f76af08.gif]]
*** Capturing and refiling
[[https://user-images.githubusercontent.com/1782860/123549993-9a972000-d76b-11eb-814b-b348a93df08a.gif]]
*** Autocompletion
[[https://user-images.githubusercontent.com/1782860/123550227-e8605800-d76c-11eb-96f6-c0a677d562d4.gif]]
** Treesitter Info
The built-in treesitter parser is used for parsing the org files.
*** Known highlighting issues and limitations
** Troubleshoot
*** Indentation is not working
Make sure you are not overriding indentexpr in Org buffers with [[https://github.com/nvim-treesitter/nvim-treesitter#indentation][nvim-treesitter indentation]]
*** I get ~treesitter/query.lua~ errors when opening agenda/capture prompt or org files
Tree-sitter parser might not be installed. Try running ~:lua require('orgmode.config'):reinstall_grammar()~ to reinstall it.
*** Dates are not in English
Dates are generated with Lua native date support, and it reads your current locale when creating them.
To use different locale you can add this to your ~init.lua~:
vim.cmd('language en_US.utf8')
or ~init.vim~
language en_US.utf8
Just make sure you have ~en_US~ locale installed on your system. To see what you have available on the system you can
start the command ~:language~ and press ~
*** Links are not concealed
Links are concealed with Vim's conceal feature (see ~:help conceal~). To enable concealing, add this to your ~init.lua~:
vim.opt.conceallevel = 2 vim.opt.concealcursor = 'nc'
Or if you are using ~init.vim~:
set conceallevel=2 set concealcursor=nc
*** Jumping to file path is not working for paths with forward slash
If you are using Windows, paths are by default written with backslashes. To use forward slashes, you must enable ~shellslash~ option (see ~:help shellslash~).
vim.opt.shellslash = true
Or if you are using ~init.vim~:
set shellslash
More info on issue [[https://github.com/nvim-orgmode/orgmode/issues/281#issuecomment-1120200775][#281]]
** Features
*** TL;DR
*** Detailed breakdown
Link to detailed documentation: [[DOCS.md][DOCS]]
** Plugins
See all available plugins on [[https://github.com/topics/orgmode-nvim][orgmode-nvim]]
If you built a plugin please add "orgmode-nvim" topic to it.
NOTE: None of the Emacs Orgmode plugins will be built into nvim-orgmode. Anything that's a separate plugin in Emacs Orgmode should be a separate plugin in here. The point of this plugin is to provide functionality that's built into Emacs Orgmode core, and a good foundation for external plugins.
If you want to build a plugin, post suggestions and improvements on [[https://github.com/nvim-orgmode/orgmode/issues/26][Plugins infrastructure]] issue.
*** :wrench: API
Documentation for our work-in-progress API can be found [[doc/orgmode_api.txt][here]]
** Contributing
See [[CONTRIBUTING.md][CONTRIBUTING.md]]
** Documentation
If you are just starting out with orgmode, have a look at the [[https://github.com/nvim-orgmode/orgmode/wiki/Getting-Started][Getting Started]] section in our wiki.
Vim documentation is auto generated from [[DOCS.md][DOCS.md]] file with [[https://github.com/FooSoft/md2vim][md2vim]].
Hosted documentation is on: [[https://nvim-orgmode.github.io/][https://nvim-orgmode.github.io/]]
** Roadmap
** Thanks to