~thecatster/.emacs.d

1b50d8d321f92a9e9927e8ce62bbe04b1210ae16 — Daniel Rose 3 years ago b5a53ee
Add Flutter, Treemacs. Remove JVM.
2 files changed, 96 insertions(+), 96 deletions(-)

M emacs.org
M init.el
M emacs.org => emacs.org +58 -60
@@ 439,7 439,7 @@ this font name! And if we're talking about fonts, you gotta have
emojis.

#+BEGIN_SRC emacs-lisp
(add-to-list 'default-frame-alist '(font . "JetBrainsMono Nerd Font 10"))
(add-to-list 'default-frame-alist '(font . "JetBrainsMono Nerd Font 12"))
(use-package emojify
  :hook (erc-mode . emojify-mode)
  :commands emojify-mode)


@@ 853,7 853,7 @@ Especially when learning the Emacs keybindings, Which Key is quite helpful.
#+END_SRC

** Projectile
I had never really used treemacs/neotree in Doom, but projectile was a must.
projectile is a must

#+BEGIN_SRC emacs-lisp
  (use-package projectile


@@ 1422,6 1422,29 @@ erc is a cool irc client for emacs
  (erc-update-modules))
#+END_SRC

** Treemacs
I used to be opposed to using Treemacs, but have learned to appreciate
it over time.

#+BEGIN_SRC emacs-lisp
(use-package treemacs
  :defer t
  :config
  (treemacs-follow-mode t)
  (treemacs-filewatch-mode t)
  (treemacs-fringe-indicator-mode 'always)
  (treemacs-git-mode 'deferred))

(use-package lsp-treemacs
  :after treemacs)

(use-package treemacs-projectile
  :after (treemacs projectile))

(use-package treemacs-magit
  :after (treemacs magit))
#+END_SRC

** Screenshot
Sharing pictures of code is useful, why not build that into Emacs.



@@ 1759,9 1782,7 @@ phenomenal, allowing for a proper debugging experience within Emacs
           web-mode
           typescript-mode
           clojure-mode
           java-mode
           kotlin-mode
           scala-mode) . lsp)
           dart-mode) . lsp)
         (lsp-mode . lsp-enable-which-key-integration))
  :commands (lsp)
  :init


@@ 1826,8 1847,8 @@ Languages are marked ~:disabled~ in ~use-package~ when I am not
currently doing a project in them (but would like to keep my setup).

*** Rust
Crustacean for life! Rust is a great language, but is taking it's time to
completely be accepted. Most of my work nowadays is done in Rust.
Crustacean for life! Rust is a great language, but is taking it's time
to completely be accepted. Most of my work nowadays is done in Rust.

#+BEGIN_SRC emacs-lisp
;;; Source: Configuring Emacs for Rust development - https://robert.kra.hn/posts/2021-02-07_rust-with-emacs/


@@ 1865,6 1886,34 @@ nice to have anyways.
  (add-hook 'rustic-mode-hook 'cargo-minor-mode))
#+END_SRC

*** Dart
I love Rust. If I could do every project in it, I probably would. But
Rust has places it really doesn't work (i.e. certain embedded
scenarios) and especially cross-platform mobile/web apps.

That latter is where Dart and Flutter come in for me.

#+BEGIN_SRC emacs-lisp
(use-package dart-mode
  :hook (dart-mode . flutter-test-mode)
  :custom
  (dart-format-on-save t))

(use-package flutter
  :after dart-mode
  :bind (:map dart-mode-map
              ("C-M-x" . #'flutter-run-or-hot-reload))
  :custom
  (flutter-sdk-path "/opt/flutter/"))

(use-package flutter-l10n-flycheck
  :after flutter
  :config
  (flutter-l10n-flycheck-setup))

(use-package lsp-dart)
#+END_SRC

*** Python
Python is everywhere, and I still have to use it quite often. Not my
preferred language, but not a bad one. Great language for fast


@@ 2006,11 2055,12 @@ Kotlin.
(use-package clojure-mode)
(use-package cider)
#+END_SRC

*** Web Languages
Despite my usual hate for these languages (and web languages in
general), I've recently been learning more about them and
understanding how they truly are powerful (and the numerous pitfalls
with them.) This is my configuration for JS, TS, React, and whatever
with them). This is my configuration for JS, TS, React, and whatever
else I'll eventually need.

#+BEGIN_SRC emacs-lisp


@@ 2060,58 2110,6 @@ work through SICP and Software Design for Flexibility in it is great!
  :after geiser-repl
  :config (add-hook 'geiser-repl-mode-hook #'macrostep-geiser-setup))
#+END_SRC
*** JVM
I rarely use the JVM languages (except Clojure) but still do enjoy
them (even Java!) every once in a while. Why not set them up as well?

All of JVM is disabled (no projects currently in these languages).

**** Java
Ole' grandpa himself.

#+BEGIN_SRC emacs-lisp
  (use-package lsp-java
    :disabled)
#+END_SRC

**** Kotlin
The cool kid.

#+BEGIN_SRC emacs-lisp
(use-package kotlin-mode
  :disabled)

(use-package flycheck-kotlin
  :disabled)

(use-package android-mode
  :disabled)
#+END_SRC

**** Scala
The nerd.

#+BEGIN_SRC emacs-lisp
  (use-package scala-mode
    :mode "\\.s\\(cala\\|bt\\)$"
    :disabled)

  (use-package sbt-mode
    :commands sbt-start sbt-command
    :disabled
    :custom
    (sbt:default-command "testQuick")
    :config
    ;; WORKAROUND: https://github.com/ensime/emacs-sbt-mode/issues/31
    ;; allows using SPACE when in the minibuffer
    (substitute-key-definition
     'minibuffer-complete-word
     'self-insert-command
     minibuffer-local-completion-map))

  (use-package lsp-metals
    :disabled)
#+END_SRC

* Org Mode
Even more features to org-mode!

M init.el => init.el +38 -36
@@ 239,7 239,7 @@

(add-hook 'before-save-hook 'delete-trailing-whitespace)

(add-to-list 'default-frame-alist '(font . "JetBrainsMono Nerd Font 10"))
(add-to-list 'default-frame-alist '(font . "JetBrainsMono Nerd Font 12"))
(use-package emojify
  :hook (erc-mode . emojify-mode)
  :commands emojify-mode)


@@ 995,6 995,23 @@
  (erc-services-mode 1)
  (erc-update-modules))

(use-package treemacs
  :defer t
  :config
  (treemacs-follow-mode t)
  (treemacs-filewatch-mode t)
  (treemacs-fringe-indicator-mode 'always)
  (treemacs-git-mode 'deferred))

(use-package lsp-treemacs
  :after treemacs)

(use-package treemacs-projectile
  :after (treemacs projectile))

(use-package treemacs-magit
  :after (treemacs magit))

(use-package screenshot
  :straight (:host github :repo "tecosaur/screenshot"))



@@ 1182,9 1199,7 @@
           web-mode
           typescript-mode
           clojure-mode
           java-mode
           kotlin-mode
           scala-mode) . lsp)
           dart-mode) . lsp)
         (lsp-mode . lsp-enable-which-key-integration))
  :commands (lsp)
  :init


@@ 1258,6 1273,25 @@
  :config
  (add-hook 'rustic-mode-hook 'cargo-minor-mode))

(use-package dart-mode
  :hook (dart-mode . flutter-test-mode)
  :custom
  (dart-format-on-save t))

(use-package flutter
  :after dart-mode
  :bind (:map dart-mode-map
              ("C-M-x" . #'flutter-run-or-hot-reload))
  :custom
  (flutter-sdk-path "/opt/flutter/"))

(use-package flutter-l10n-flycheck
  :after flutter
  :config
  (flutter-l10n-flycheck-setup))

(use-package lsp-dart)

(use-package lsp-python-ms
  :after lsp-mode
  :defer 0.3


@@ 1407,38 1441,6 @@
  :after geiser-repl
  :config (add-hook 'geiser-repl-mode-hook #'macrostep-geiser-setup))

(use-package lsp-java
  :disabled)

(use-package kotlin-mode
  :disabled)

(use-package flycheck-kotlin
  :disabled)

(use-package android-mode
  :disabled)

(use-package scala-mode
  :mode "\\.s\\(cala\\|bt\\)$"
  :disabled)

(use-package sbt-mode
  :commands sbt-start sbt-command
  :disabled
  :custom
  (sbt:default-command "testQuick")
  :config
  ;; WORKAROUND: https://github.com/ensime/emacs-sbt-mode/issues/31
  ;; allows using SPACE when in the minibuffer
  (substitute-key-definition
   'minibuffer-complete-word
   'self-insert-command
   minibuffer-local-completion-map))

(use-package lsp-metals
  :disabled)

(defun +org|setup-ui ()
  "Configures the UI for `org-mode'."
  (org-indent-mode)