Skip to content

Commit

Permalink
Revert "fix(mininit): Ensure minimal init works on 0.11"
Browse files Browse the repository at this point in the history
This reverts commit 12d2324.
  • Loading branch information
kristijanhusak committed Dec 21, 2024
1 parent 12d2324 commit 44adb0f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
7 changes: 4 additions & 3 deletions lua/orgmode/config/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,11 @@ function Config:__index(key)
end

function Config:install_grammar()
local ok, _, err = pcall(vim.treesitter.language.add, 'org')
if not ok or err ~= nil then
require('orgmode.utils.treesitter.install').run()
local ok = pcall(vim.treesitter.language.add, 'org')
if ok then
return
end
require('orgmode.utils.treesitter.install').run()
end

---@param url? string
Expand Down
4 changes: 0 additions & 4 deletions scripts/minimal_init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@ local nvim_root = tmp_dir .. '/nvim_orgmode'
local lazy_root = nvim_root .. '/lazy'
local lazypath = lazy_root .. '/lazy.nvim'

for _, name in ipairs({ "config", "data", "state", "cache" }) do
vim.env[("XDG_%s_HOME"):format(name:upper())] = nvim_root .. "/" .. name
end

-- Install lazy.nvim if not already installed
if not vim.loop.fs_stat(lazypath) then
vim.fn.system({
Expand Down

0 comments on commit 44adb0f

Please sign in to comment.