ffixing a lot of broken code
This commit is contained in:
parent
acd99a5c59
commit
ca404b36b5
48
README.org
48
README.org
|
@ -389,7 +389,7 @@ Let's use =no-littering= in order to stop emacs from filling all our folders wit
|
||||||
|
|
||||||
** Ligatures
|
** Ligatures
|
||||||
Here let's try to add ligatures to our font system since the VictorMono Nerd Font supports all ligatures being a "Nerd Font".
|
Here let's try to add ligatures to our font system since the VictorMono Nerd Font supports all ligatures being a "Nerd Font".
|
||||||
#+begin_src emacs-lisp :tangle no
|
#+begin_src emacs-lisp :tangle yes
|
||||||
(let ((alist '((?! . "\\(?:!\\(?:==\\|[!=]\\)\\)")
|
(let ((alist '((?! . "\\(?:!\\(?:==\\|[!=]\\)\\)")
|
||||||
(?# . "\\(?:#\\(?:###?\\|_(\\|[!#(:=?[_{]\\)\\)")
|
(?# . "\\(?:#\\(?:###?\\|_(\\|[!#(:=?[_{]\\)\\)")
|
||||||
(?$ . "\\(?:\\$>\\)")
|
(?$ . "\\(?:\\$>\\)")
|
||||||
|
@ -1542,39 +1542,6 @@ Made for `org-tab-first-hook' in evil-mode."
|
||||||
(call-interactively #'tab-to-tab-stop)
|
(call-interactively #'tab-to-tab-stop)
|
||||||
t)))
|
t)))
|
||||||
|
|
||||||
;;;###autoload
|
|
||||||
(defun +org-yas-expand-maybe-h ()
|
|
||||||
"Expand a yasnippet snippet, if trigger exists at point or region is active.
|
|
||||||
Made for `org-tab-first-hook'."
|
|
||||||
(when (and (modulep! :editor snippets)
|
|
||||||
(require 'yasnippet nil t)
|
|
||||||
(bound-and-true-p yas-minor-mode))
|
|
||||||
(and (let ((major-mode (cond ((org-in-src-block-p t)
|
|
||||||
(org-src-get-lang-mode (org-eldoc-get-src-lang)))
|
|
||||||
((org-inside-LaTeX-fragment-p)
|
|
||||||
'latex-mode)
|
|
||||||
(major-mode)))
|
|
||||||
(org-src-tab-acts-natively nil) ; causes breakages
|
|
||||||
;; Smart indentation doesn't work with yasnippet, and painfully slow
|
|
||||||
;; in the few cases where it does.
|
|
||||||
(yas-indent-line 'fixed))
|
|
||||||
(cond ((and (or (not (bound-and-true-p evil-local-mode))
|
|
||||||
(evil-insert-state-p)
|
|
||||||
(evil-emacs-state-p))
|
|
||||||
(or (and (bound-and-true-p yas--tables)
|
|
||||||
(gethash major-mode yas--tables))
|
|
||||||
(progn (yas-reload-all) t))
|
|
||||||
(yas--templates-for-key-at-point))
|
|
||||||
(yas-expand)
|
|
||||||
t)
|
|
||||||
((use-region-p)
|
|
||||||
(yas-insert-snippet)
|
|
||||||
t)))
|
|
||||||
;; HACK Yasnippet breaks org-superstar-mode because yasnippets is
|
|
||||||
;; overzealous about cleaning up overlays.
|
|
||||||
(when (bound-and-true-p org-superstar-mode)
|
|
||||||
(org-superstar-restart)))))
|
|
||||||
|
|
||||||
;;;###autoload
|
;;;###autoload
|
||||||
(defun +org-cycle-only-current-subtree-h (&optional arg)
|
(defun +org-cycle-only-current-subtree-h (&optional arg)
|
||||||
"Toggle the local fold at the point, and no deeper.
|
"Toggle the local fold at the point, and no deeper.
|
||||||
|
@ -1648,7 +1615,7 @@ So, how do we use this? Well, let's try like this.
|
||||||
|
|
||||||
*** Ox-Spectacle
|
*** Ox-Spectacle
|
||||||
Spectacle.js is another beautiful slideshow builder that org can export to using ox-spectacle.
|
Spectacle.js is another beautiful slideshow builder that org can export to using ox-spectacle.
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp :tangle no
|
||||||
(use-package ox-spectacle
|
(use-package ox-spectacle
|
||||||
:config
|
:config
|
||||||
|
|
||||||
|
@ -2319,7 +2286,7 @@ Devdocs.io is a pretty great place to see documentation on nearly any developer
|
||||||
|
|
||||||
** YASnippet
|
** YASnippet
|
||||||
YASnippet is a templating system. It's powerful.
|
YASnippet is a templating system. It's powerful.
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp :tangle no
|
||||||
(use-package yasnippet
|
(use-package yasnippet
|
||||||
:config
|
:config
|
||||||
(setq yas-snippet-dirs (list (expand-file-name "yasnippets/" user-emacs-directory)))
|
(setq yas-snippet-dirs (list (expand-file-name "yasnippets/" user-emacs-directory)))
|
||||||
|
@ -2567,7 +2534,7 @@ Finally, here are some auto modes I'd like to setup
|
||||||
|
|
||||||
*** Tree Sitter
|
*** Tree Sitter
|
||||||
I'm gonna try this to speed up emacs and make it nicer
|
I'm gonna try this to speed up emacs and make it nicer
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp :tangle no
|
||||||
(use-package tree-sitter
|
(use-package tree-sitter
|
||||||
:config
|
:config
|
||||||
(global-tree-sitter-mode +1)
|
(global-tree-sitter-mode +1)
|
||||||
|
@ -2575,6 +2542,9 @@ I'm gonna try this to speed up emacs and make it nicer
|
||||||
(use-package tree-sitter-langs)
|
(use-package tree-sitter-langs)
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
|
||||||
|
#+end_src
|
||||||
*** C++
|
*** C++
|
||||||
In c++ I just want to make sure lsp is called when enter c++-mode
|
In c++ I just want to make sure lsp is called when enter c++-mode
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
|
@ -3853,7 +3823,7 @@ I use transmission on a server to manage my torrents
|
||||||
|
|
||||||
** HASS
|
** HASS
|
||||||
Hass is a package to control Home Assistant. I use HA so... I like HASS.
|
Hass is a package to control Home Assistant. I use HA so... I like HASS.
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp :tangle no
|
||||||
(use-package hass
|
(use-package hass
|
||||||
:init
|
:init
|
||||||
(setq hass-host "home.cochrun.xyz"
|
(setq hass-host "home.cochrun.xyz"
|
||||||
|
@ -3951,7 +3921,7 @@ I like to track my time with ActivityWatch so I can notice and kill bad habits.
|
||||||
** LanguageTool
|
** LanguageTool
|
||||||
I am going to try and use LanguageTool to fix grammatical issues.
|
I am going to try and use LanguageTool to fix grammatical issues.
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp :tangle no
|
||||||
(use-package langtool)
|
(use-package langtool)
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
|
|
61
init.el
61
init.el
|
@ -1213,39 +1213,6 @@ Made for `org-tab-first-hook' in evil-mode."
|
||||||
(call-interactively #'tab-to-tab-stop)
|
(call-interactively #'tab-to-tab-stop)
|
||||||
t)))
|
t)))
|
||||||
|
|
||||||
;;;###autoload
|
|
||||||
(defun +org-yas-expand-maybe-h ()
|
|
||||||
"Expand a yasnippet snippet, if trigger exists at point or region is active.
|
|
||||||
Made for `org-tab-first-hook'."
|
|
||||||
(when (and (modulep! :editor snippets)
|
|
||||||
(require 'yasnippet nil t)
|
|
||||||
(bound-and-true-p yas-minor-mode))
|
|
||||||
(and (let ((major-mode (cond ((org-in-src-block-p t)
|
|
||||||
(org-src-get-lang-mode (org-eldoc-get-src-lang)))
|
|
||||||
((org-inside-LaTeX-fragment-p)
|
|
||||||
'latex-mode)
|
|
||||||
(major-mode)))
|
|
||||||
(org-src-tab-acts-natively nil) ; causes breakages
|
|
||||||
;; Smart indentation doesn't work with yasnippet, and painfully slow
|
|
||||||
;; in the few cases where it does.
|
|
||||||
(yas-indent-line 'fixed))
|
|
||||||
(cond ((and (or (not (bound-and-true-p evil-local-mode))
|
|
||||||
(evil-insert-state-p)
|
|
||||||
(evil-emacs-state-p))
|
|
||||||
(or (and (bound-and-true-p yas--tables)
|
|
||||||
(gethash major-mode yas--tables))
|
|
||||||
(progn (yas-reload-all) t))
|
|
||||||
(yas--templates-for-key-at-point))
|
|
||||||
(yas-expand)
|
|
||||||
t)
|
|
||||||
((use-region-p)
|
|
||||||
(yas-insert-snippet)
|
|
||||||
t)))
|
|
||||||
;; HACK Yasnippet breaks org-superstar-mode because yasnippets is
|
|
||||||
;; overzealous about cleaning up overlays.
|
|
||||||
(when (bound-and-true-p org-superstar-mode)
|
|
||||||
(org-superstar-restart)))))
|
|
||||||
|
|
||||||
;;;###autoload
|
;;;###autoload
|
||||||
(defun +org-cycle-only-current-subtree-h (&optional arg)
|
(defun +org-cycle-only-current-subtree-h (&optional arg)
|
||||||
"Toggle the local fold at the point, and no deeper.
|
"Toggle the local fold at the point, and no deeper.
|
||||||
|
@ -1307,11 +1274,6 @@ All my (performant) foldings needs are met between this and `org-show-subtree'
|
||||||
org-re-reveal-mobile-app t)
|
org-re-reveal-mobile-app t)
|
||||||
)
|
)
|
||||||
|
|
||||||
(use-package ox-spectacle
|
|
||||||
:config
|
|
||||||
|
|
||||||
)
|
|
||||||
|
|
||||||
(use-package unicode-fonts
|
(use-package unicode-fonts
|
||||||
:ensure t
|
:ensure t
|
||||||
:config
|
:config
|
||||||
|
@ -1724,11 +1686,6 @@ targets."
|
||||||
(chris/leader-keys 'normal
|
(chris/leader-keys 'normal
|
||||||
"hd" 'devdocs-lookup))
|
"hd" 'devdocs-lookup))
|
||||||
|
|
||||||
(use-package yasnippet
|
|
||||||
:config
|
|
||||||
(setq yas-snippet-dirs (list (expand-file-name "yasnippets/" user-emacs-directory)))
|
|
||||||
(yas-global-mode 1))
|
|
||||||
|
|
||||||
(use-package tempel
|
(use-package tempel
|
||||||
:bind (("M-+" . tempel-complete) ;; Alternative tempel-expand
|
:bind (("M-+" . tempel-complete) ;; Alternative tempel-expand
|
||||||
("M-'" . tempel-insert)
|
("M-'" . tempel-insert)
|
||||||
|
@ -1918,11 +1875,7 @@ targets."
|
||||||
|
|
||||||
(add-to-list 'auto-mode-alist '("\\.yuck?\\'" . lisp-data-mode))
|
(add-to-list 'auto-mode-alist '("\\.yuck?\\'" . lisp-data-mode))
|
||||||
|
|
||||||
(use-package tree-sitter
|
|
||||||
:config
|
|
||||||
(global-tree-sitter-mode +1)
|
|
||||||
)
|
|
||||||
(use-package tree-sitter-langs)
|
|
||||||
|
|
||||||
(defun astyle-this-buffer ()
|
(defun astyle-this-buffer ()
|
||||||
"Use astyle command to auto format c/c++ code."
|
"Use astyle command to auto format c/c++ code."
|
||||||
|
@ -2899,16 +2852,6 @@ interfere with the default `bongo-playlist-buffer'."
|
||||||
:keymaps 'override
|
:keymaps 'override
|
||||||
"ot" 'transmission))
|
"ot" 'transmission))
|
||||||
|
|
||||||
(use-package hass
|
|
||||||
:init
|
|
||||||
(setq hass-host "home.cochrun.xyz"
|
|
||||||
hass-port "443"
|
|
||||||
hass-apikey "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiI2NDE1YTU5NzAzZDA0NDY0YTM0MmYzNTI1MjU0NjMwNyIsImlhdCI6MTY1Mjc1NjcwOSwiZXhwIjoxOTY4MTE2NzA5fQ.gGuxtwE2Xc1nGSgqpHiT2us-q04GWjtqnpgSHxvXgNI")
|
|
||||||
(hass-setup)
|
|
||||||
:general
|
|
||||||
(chris/leader-keys
|
|
||||||
"oh" 'hass-dash-open))
|
|
||||||
|
|
||||||
(use-package auth-source-pass
|
(use-package auth-source-pass
|
||||||
:defer 1
|
:defer 1
|
||||||
:config (auth-source-pass-enable))
|
:config (auth-source-pass-enable))
|
||||||
|
@ -2964,8 +2907,6 @@ interfere with the default `bongo-playlist-buffer'."
|
||||||
"v" 'chris/elfeed-bongo-insert-item
|
"v" 'chris/elfeed-bongo-insert-item
|
||||||
"N" 'mastodon-notifications--timeline))
|
"N" 'mastodon-notifications--timeline))
|
||||||
|
|
||||||
(use-package langtool)
|
|
||||||
|
|
||||||
(use-package qrencode)
|
(use-package qrencode)
|
||||||
|
|
||||||
;; Reduce rendering/line scan work for Emacs by not rendering cursors or regions
|
;; Reduce rendering/line scan work for Emacs by not rendering cursors or regions
|
||||||
|
|
Loading…
Reference in a new issue