File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change 1
- _G .orgmode = _G .orgmode or {
2
- ts_revision = ' 1c3eb533a9cf6800067357b59e03ac3f91fc3a54' ,
3
- }
1
+ _G .orgmode = _G .orgmode or {}
2
+ local ts_revision = ' 1c3eb533a9cf6800067357b59e03ac3f91fc3a54'
4
3
local setup_ts_grammar_used = false
5
4
local instance = nil
6
5
@@ -68,7 +67,7 @@ local function setup_ts_grammar(revision)
68
67
parser_config .org = {
69
68
install_info = {
70
69
url = ' https://github.com/milisims/tree-sitter-org' ,
71
- revision = revision or _G . orgmode . ts_revision ,
70
+ revision = revision or ts_revision ,
72
71
files = { ' src/parser.c' , ' src/scanner.cc' },
73
72
},
74
73
filetype = ' org' ,
@@ -81,7 +80,7 @@ local function check_ts_grammar()
81
80
end
82
81
vim .defer_fn (function ()
83
82
local parser_config = require (' nvim-treesitter.parsers' ).get_parser_configs ()
84
- if parser_config and parser_config .org and parser_config .org .install_info .revision ~= _G . orgmode . ts_revision then
83
+ if parser_config and parser_config .org and parser_config .org .install_info .revision ~= ts_revision then
85
84
require (' orgmode.utils' ).echo_error ({
86
85
' You are using outdated version of tree-sitter grammar for Orgmode.' ,
87
86
' To use latest version, replace current grammar installation with "require(\' orgmode\' ).setup_ts_grammar()" and run :TSUpdate org.' ,
You can’t perform that action at this time.
0 commit comments