From c869815fe28b1d8d5d00d3fec63ff2ebe1a8005f Mon Sep 17 00:00:00 2001 From: minhtrannhat Date: Fri, 22 Oct 2021 16:34:06 -0400 Subject: [PATCH] Org-roam-ui, newsboat and more --- doom-emacs/.doom.d/config.el | 32 ++++++++++++++++++++++++++++++++ doom-emacs/.doom.d/custom.el | 2 +- doom-emacs/.doom.d/init.el | 2 +- doom-emacs/.doom.d/packages.el | 3 +++ lvim/.config/lvim/config.lua | 6 ++++++ newsboat/.newsboat/config | 32 ++++++++++++++++++++++++++++++++ newsboat/.newsboat/urls | 5 +++++ 7 files changed, 80 insertions(+), 2 deletions(-) create mode 100644 newsboat/.newsboat/config create mode 100644 newsboat/.newsboat/urls diff --git a/doom-emacs/.doom.d/config.el b/doom-emacs/.doom.d/config.el index d167bbf..cf88f8f 100644 --- a/doom-emacs/.doom.d/config.el +++ b/doom-emacs/.doom.d/config.el @@ -129,3 +129,35 @@ ;; Whether display the minor modes in the mode-line. (setq doom-modeline-minor-modes nil) + +(use-package! websocket + :after org-roam) + +(use-package! org-roam-ui + :after org-roam ;; or :after org +;; normally we'd recommend hooking orui after org-roam, but since org-roam does not have +;; a hookable mode anymore, you're advised to pick something yourself +;; if you don't care about startup time, use +;; :hook (after-init . org-roam-ui-mode) + :config + (setq org-roam-ui-sync-theme t + org-roam-ui-follow t + org-roam-ui-update-on-save t + org-roam-ui-open-on-start t)) + +;; Deft - a Major mode for text searching +(setq deft-directory org-roam-directory) +(setq deft-recursive t) +(setq deft-use-filter-string-for-filename t) + +;; Function for inserting node into Org Roam +(defun org-roam-node-insert-immediate (arg &rest args) + (interactive "P") + (let ((args (cons arg args)) + (org-roam-capture-templates (list (append (car org-roam-capture-templates) + '(:immediate-finish t))))) + (apply #'org-roam-node-insert args))) + +(map! :leader + :desc "Insert node immediately" + "n r I" #'org-roam-node-insert-immediate) diff --git a/doom-emacs/.doom.d/custom.el b/doom-emacs/.doom.d/custom.el index 66b63e7..36a74d8 100644 --- a/doom-emacs/.doom.d/custom.el +++ b/doom-emacs/.doom.d/custom.el @@ -5,7 +5,7 @@ ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. '(custom-safe-themes - '("e3b2bad7b781a968692759ad12cb6552bc39d7057762eefaf168dbe604ce3a4b" "1704976a1797342a1b4ea7a75bdbb3be1569f4619134341bd5a4c1cfb16abad4" "d268b67e0935b9ebc427cad88ded41e875abfcc27abd409726a92e55459e0d01" default)) + '("5784d048e5a985627520beb8a101561b502a191b52fa401139f4dd20acb07607" "e3b2bad7b781a968692759ad12cb6552bc39d7057762eefaf168dbe604ce3a4b" "1704976a1797342a1b4ea7a75bdbb3be1569f4619134341bd5a4c1cfb16abad4" "d268b67e0935b9ebc427cad88ded41e875abfcc27abd409726a92e55459e0d01" default)) '(git-gutter:update-interval 1) '(warning-suppress-log-types '((iedit) (iedit) (iedit) (iedit) (iedit) (iedit) (iedit))) '(warning-suppress-types diff --git a/doom-emacs/.doom.d/init.el b/doom-emacs/.doom.d/init.el index ab48c28..0ac1f23 100644 --- a/doom-emacs/.doom.d/init.el +++ b/doom-emacs/.doom.d/init.el @@ -26,7 +26,7 @@ vertico ; the search engine of the future :ui - ;;deft ; notational velocity for Emacs + deft ; notational velocity for Emacs doom ; what makes DOOM look the way it does doom-dashboard ; a nifty splash screen for Emacs doom-quit ; DOOM quit-message prompts when you quit Emacs diff --git a/doom-emacs/.doom.d/packages.el b/doom-emacs/.doom.d/packages.el index e7bf5ac..7bb8a8c 100644 --- a/doom-emacs/.doom.d/packages.el +++ b/doom-emacs/.doom.d/packages.el @@ -52,3 +52,6 @@ (package! tree-sitter) (package! tree-sitter-langs) (package! pinentry) +(unpin! org-roam) +(package! websocket) +(package! org-roam-ui :recipe (:host github :repo "org-roam/org-roam-ui" :files ("*.el" "out"))) diff --git a/lvim/.config/lvim/config.lua b/lvim/.config/lvim/config.lua index 63153c3..6cb178e 100644 --- a/lvim/.config/lvim/config.lua +++ b/lvim/.config/lvim/config.lua @@ -1,6 +1,12 @@ -- general lvim.format_on_save = true lvim.lint_on_save = true + +vim.g.nord_contrast = true +vim.g.nord_borders = true +vim.g.nord_disable_background = false +vim.g.nord_italic = true + lvim.colorscheme = "nord" lvim.shell = "/bin/fish" vim.opt.guifont = "JetBrainsMono Nerd Font Mono:h16" diff --git a/newsboat/.newsboat/config b/newsboat/.newsboat/config new file mode 100644 index 0000000..13fc411 --- /dev/null +++ b/newsboat/.newsboat/config @@ -0,0 +1,32 @@ +auto-reload yes +browser "firefox --new-tab %u" +max-items 50 + +# unbind keys +unbind-key ENTER +unbind-key j +unbind-key k +unbind-key J +unbind-key K + +# bind keys - vim style +bind-key j down +bind-key k up +bind-key l open +bind-key h quit + +color background color236 default +color listnormal color248 default +color listnormal_unread color6 default +color listfocus color236 color12 +color listfocus_unread color15 color12 +color info color248 color236 +color article color248 default + +# highlights +highlight article "^(Feed|Link):.*$" color6 default bold +highlight article "^(Title|Date|Author):.*$" color6 default bold +highlight article "https?://[^ ]+" color10 default underline +highlight article "\\[[0-9]+\\]" color10 default bold +highlight article "\\[image\\ [0-9]+\\]" color10 default bold +highlight feedlist "^─.*$" color6 color236 bold diff --git a/newsboat/.newsboat/urls b/newsboat/.newsboat/urls new file mode 100644 index 0000000..8a6f3a9 --- /dev/null +++ b/newsboat/.newsboat/urls @@ -0,0 +1,5 @@ +http://lukesmith.xyz/rss.xml "Technology" +http://www.vox.com/rss/policy-and-politics/index.xml "Politics" +https://based.cooking/rss.xml "Cooking" +http://cyberciti.biz/feed "Technology" +https://medium.com/feed/better-programming "Technology"