From f1589a8d156acf4c7eff0563c852a3937400950a Mon Sep 17 00:00:00 2001 From: mrflos Date: Fri, 9 Aug 2024 12:34:10 +0300 Subject: [PATCH] macos custom tweaks --- .gitignore | 1 + dotfiles/kitty/kitty.conf | 2 ++ dotfiles/nvim/lua/plugins/markdownpreview.lua | 21 +++++++++++++++++++ modules/local-dev.nix | 5 ++++- 4 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 dotfiles/nvim/lua/plugins/markdownpreview.lua diff --git a/.gitignore b/.gitignore index 40c7108..cc56fe3 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ +.DS_Store configuration.nix diff --git a/dotfiles/kitty/kitty.conf b/dotfiles/kitty/kitty.conf index 5e74838..a4de263 100644 --- a/dotfiles/kitty/kitty.conf +++ b/dotfiles/kitty/kitty.conf @@ -91,3 +91,5 @@ background_opacity 1 #background_tint 0.99 modify_font cell_height 130% startup_session ~/.config/kitty/session.conf +hide_window_decorations titlebar-only + diff --git a/dotfiles/nvim/lua/plugins/markdownpreview.lua b/dotfiles/nvim/lua/plugins/markdownpreview.lua new file mode 100644 index 0000000..9c52ab5 --- /dev/null +++ b/dotfiles/nvim/lua/plugins/markdownpreview.lua @@ -0,0 +1,21 @@ +return { + { + -- Install markdown preview, use npx if available. + "iamcco/markdown-preview.nvim", + cmd = { "MarkdownPreviewToggle", "MarkdownPreview", "MarkdownPreviewStop" }, + ft = { "markdown" }, + build = function(plugin) + if vim.fn.executable("npx") then + vim.cmd("!cd " .. plugin.dir .. " && cd app && npx --yes yarn install") + else + vim.cmd([[Lazy load markdown-preview.nvim]]) + vim.fn["mkdp#util#install"]() + end + end, + init = function() + if vim.fn.executable("npx") then + vim.g.mkdp_filetypes = { "markdown" } + end + end, + }, +} diff --git a/modules/local-dev.nix b/modules/local-dev.nix index 66e8ef6..4ca0118 100644 --- a/modules/local-dev.nix +++ b/modules/local-dev.nix @@ -85,7 +85,10 @@ # $ nix search wget environment.systemPackages = with pkgs; let - php83 = pkgs.php83.buildEnv { extraConfig = "max_upload_size = 2G"; }; + php83 = pkgs.php83.buildEnv { extraConfig = '' + max_upload_size = 2G + memory_limit = 1G + ''; }; in [ cmake dart-sass