From 3badc1a2533a78431d7b2a48941a5b5895d9b9d3 Mon Sep 17 00:00:00 2001 From: r17x Date: Sun, 26 May 2024 03:27:10 +0700 Subject: [PATCH] refactor(nvim): enable image.nvim --- TODO.md | 5 ----- home/tmux.nix | 3 +++ notes/index.norg | 13 +++++++++++++ notes/journal/2024/05/26.norg | 30 ++++++++++++++++++++++++++++++ notes/todo.norg | 24 ++++++++++++++++++++++++ nvim.nix/config/ui.nix | 5 +++++ 6 files changed, 75 insertions(+), 5 deletions(-) delete mode 100644 TODO.md create mode 100644 notes/index.norg create mode 100644 notes/journal/2024/05/26.norg create mode 100644 notes/todo.norg diff --git a/TODO.md b/TODO.md deleted file mode 100644 index a052316..0000000 --- a/TODO.md +++ /dev/null @@ -1,5 +0,0 @@ -## TODO - -* [ ] migrate base flake to [flake.parts](https://flake.parts). -* [ ] merge [nvim.nix](https://github.com/r17x/nvim.nix) with this repository. -* [ ] merge [rin.rocks](https://github.com/r17x/rin.rocks) with this repository. diff --git a/home/tmux.nix b/home/tmux.nix index 5d39c95..19ec40e 100644 --- a/home/tmux.nix +++ b/home/tmux.nix @@ -21,6 +21,9 @@ set -g pane-border-style "fg=$bg_color bg=$bg_color" set -g pane-active-border-style "fg=$bg_color bg=$bg_color" set -sg escape-time 10 + + set -g visual-activity off + set -gq allow-passthrough on ''; # Plugin disable cause in version 3.3a tmux server crashed diff --git a/notes/index.norg b/notes/index.norg new file mode 100644 index 0000000..5c193f7 --- /dev/null +++ b/notes/index.norg @@ -0,0 +1,13 @@ +@document.meta +title: Taking All notes +description: +authors: r17 +categories: +created: 2024-05-26T02:36:39+0700 +updated: 2024-05-26T03:39:29+0700 +version: 1.1.1 +@end + +* {:todo:}[Todo] +* Journal +** {:journal/2024/05/26:}[2024/05/26] diff --git a/notes/journal/2024/05/26.norg b/notes/journal/2024/05/26.norg new file mode 100644 index 0000000..46699bc --- /dev/null +++ b/notes/journal/2024/05/26.norg @@ -0,0 +1,30 @@ +@document.meta +title: Merge nvim.nix with nixpkgs +description: +authors: r17x +categories: +created: 2024-05-26T00:35:26+0700 +updated: 2024-05-26T01:27:14+0700 +version: 1.1.1 +@end + +* It's about flake-parts + + *flake-parts* is /Core of a distributed framework for writing Nix Flakes/ {https://flake.parts/} - I think for make flake.nix more maintainable. + + @code nix + outputs = inputs: inputs.parts.lib.mkFlake { inherit inputs; } { + systems = [ + "aarch64-darwin" + "x86_64-linux" + ]; + + imports = [ + ]; + }; + @end + +** Refactoring is art and wasting time + + after adopt the *flake-parts* in my dotfiles *r17x/nixpkgs*, *nvim.nix* it's time to refactor it and merge it with *nixpkgs*. + diff --git a/notes/todo.norg b/notes/todo.norg new file mode 100644 index 0000000..03b2d42 --- /dev/null +++ b/notes/todo.norg @@ -0,0 +1,24 @@ +@document.meta +title: Todo +description: make things get fucking done +authors: r17 +categories: +created: 2024-05-26T02:31:16+0700 +updated: 2024-05-26T03:45:15+0700 +version: 1.1.1 +@end + +* Tasks +** Blog - Rin.rocks + - ( ) Fully OCaml/ReasonML with {https://melange.re}[melange.re] + +** Dotfiles + - ( ) move {https://github.com/r17x/rin.rocks}[rin.rocks] to {https://github.com/r17x/nixpkgs}[nixpkgs] + - (x) use *flake-parts* in {https://github.com/r17x/nixpkgs}[nixpkgs] + - (x) move {https://github.com/r17x/nvim.nix}[nvim.nix] to {https://github.com/r17x/nixpkgs}[nixpkgs] + - (x) use {https://github.com/3rd/image.nvim}[image.nvim] in `nvim.nix` with {https://nix-community.github.io/nixvim/plugins/image/index.html}[plugins.image] - see implementation in {/ ../nvim.nix/config/ui.nix:13}[config/ui.nix] and updated configuration of {/ ../home/tmux.nix:25}[home/tmux.nix] + +** Neovim + - ( ) Find why image cannot render correctly in `iTerm` + - (+) Revisit `cmp` in current nixvim + diff --git a/nvim.nix/config/ui.nix b/nvim.nix/config/ui.nix index 60ad6a9..2b6603b 100644 --- a/nvim.nix/config/ui.nix +++ b/nvim.nix/config/ui.nix @@ -10,6 +10,11 @@ "fhi" = [ "Telescope highlights" "Find Highlight Groups" ]; }; + plugins.image.enable = true; + plugins.image.integrations.neorg.enabled = true; + plugins.image.editorOnlyRenderWhenFocused = true; + plugins.image.tmuxShowOnlyInActiveWindow = true; + plugins.presence-nvim.enable = true; plugins.presence-nvim.enableLineNumber = true; plugins.presence-nvim.autoUpdate = true;