Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
TwIStOy committed Nov 22, 2023
1 parent c9725af commit 0b6e945
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 2 deletions.
8 changes: 8 additions & 0 deletions lua/ht/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,14 @@ local function bootstrap_plugin_manager()
end

require("lazy").setup(lazy_settings)
package.path = package.path
.. ";"
.. vim.fn.expand("$HOME")
.. "/.luarocks/share/lua/5.1/?/init.lua;"
package.path = package.path
.. ";"
.. vim.fn.expand("$HOME")
.. "/.luarocks/share/lua/5.1/?.lua;"

local FF = require("ht.core.functions")
FF:add_function_set {
Expand Down
2 changes: 2 additions & 0 deletions src/conf/plugins/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { plugins as uiPlugins } from "./ui";
import { plugins as otherPlugins } from "./other";
import { plugins as codingPlugins } from "./coding";
import { plugins as treesitterPlugins } from "./treesitter";
import { plugins as libPlugins } from "./lib";
import { Action, Plugin, PluginActionIds } from "@core/model";
import { TupleToUnion } from "@core/type_traits";

Expand All @@ -19,6 +20,7 @@ export const AllPlugins = [
otherPlugins,
codingPlugins,
treesitterPlugins,
libPlugins,
] as const;

export const LazySpecs = [...AllPlugins, ...AllLspServers]
Expand Down
34 changes: 32 additions & 2 deletions src/conf/plugins/lib/image-nvim.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,37 @@ const spec: PluginOptsBase = {
shortUrl: "3rd/image.nvim",
lazy: {
lazy: true,
}
}
build: "luarocks --local install magick",
config: true,
opts: {
backend: "kitty",
integrations: {
markdown: {
enabled: true,
clear_in_insert_mode: false,
download_remote_images: true,
only_render_image_at_cursor: false,
filetypes: ["markdown", "vimwiki"],
},
neorg: {
enabled: true,
clear_in_insert_mode: false,
download_remote_images: true,
only_render_image_at_cursor: false,
filetypes: ["norg"],
},
},
max_width: null,
max_height: null,
max_width_window_percentage: null,
max_height_window_percentage: 50,
window_overlap_clear_enabled: false,
window_overlap_clear_ft_ignore: ["cmp_menu", "cmp_docs", ""],
editor_only_render_when_focused: false,
tmux_show_only_in_active_window: false,
hijack_file_patterns: ["*.png", "*.jpg", "*.jpeg", "*.gif", "*.webp"],
},
},
};

export const plugin = new Plugin(spec);
3 changes: 3 additions & 0 deletions src/conf/plugins/lib/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import { plugin as imageNvim } from "./image-nvim";

export const plugins = [imageNvim] as const;

0 comments on commit 0b6e945

Please sign in to comment.