summary refs log tree commit diff stats
path: root/emacs
diff options
context:
space:
mode:
Diffstat (limited to 'emacs')
-rw-r--r--emacs/.emacs.d/init.org71
1 files changed, 38 insertions, 33 deletions
diff --git a/emacs/.emacs.d/init.org b/emacs/.emacs.d/init.org
index 070f48c..9b814ec 100644
--- a/emacs/.emacs.d/init.org
+++ b/emacs/.emacs.d/init.org
@@ -176,11 +176,14 @@ Eziam looks nice, too
 #+BEGIN_SRC emacs-lisp
 (use-package eziam-light-theme
   :ensure eziam-theme
+  :if (or window-system
+          server-name)
   :defines (eziam-scale-headings)
   :config (progn
             (setq eziam-scale-headings nil)
             (load-theme 'eziam-light t)
             (custom-theme-set-faces 'user
+                                    '(default ((t (:background "#ffffff"))))
                                     '(js2-function-call ((t (:underline nil))))
                                     '(font-lock-keyword-face ((t (:weight normal))))
                                     '(git-gutter-fr:added ((t (:foreground "#96a4ab"))))
@@ -313,7 +316,8 @@ Sometimes I like to hide clutter.  Other times, it's useful.
 (when mode-line-default-hidden
   (call-interactively #'hide-mode-line))
 
-(setq-default indicate-buffer-boundaries 'left)
+(setq-default indicate-buffer-boundaries nil)
+(fringe-mode '(4 . 4))
 
 (defun hide-mode-line-if-default-hidden ()
   (if mode-line-default-hidden
@@ -560,7 +564,9 @@ based upon some folder conventions I use.
                   projectile-completion-system 'ivy)))
 
 (use-package counsel-projectile
-  :config (counsel-projectile-on))
+  :config (progn
+            (counsel-projectile-on)
+            (define-key projectile-mode-map [remap counsel-projectile-ag] #'counsel-projectile-rg)))
 #+END_SRC
 
 ** vc
@@ -596,15 +602,15 @@ fringe so it doesn’t interfere with flycheck.
             (setq-default fringes-outside-margins t)
             ;; thin fringe bitmaps
             (fringe-helper-define 'git-gutter-fr:added '(center repeated)
-              "XXX.....")
+              ".XXX....")
             (fringe-helper-define 'git-gutter-fr:modified '(center repeated)
-              "XXX.....")
+              ".XXX....")
             (fringe-helper-define 'git-gutter-fr:deleted 'bottom
-              "X......."
-              "XX......"
-              "XXX....."
-              "XXXX....")
-            (setq git-gutter-fr:side 'left-fringe)))
+              ".......X"
+              "......XX"
+              ".....XXX"
+              "....XXXX")
+            (setq git-gutter-fr:side 'right-fringe)))
 #+END_SRC
 
 ** magit
@@ -624,6 +630,17 @@ time.  Make sure to set it up with a nice =completing-read-function=
   :init (add-hook 'magit-mode-hook #'magit-load-config-extensions))
 #+END_SRC
 
+** git-messenger
+
+Popup the last commit that changed the line at point.
+
+#+BEGIN_SRC emacs-lisp
+(use-package git-messenger
+  :bind* (("C-x v p" . git-messenger:popup-message))
+  :config (progn
+            (setq git-messenger:use-magit-popup t)))
+#+END_SRC
+
 ** git-timemachine
 
 This package allow me to go through a file’s history with just a few
@@ -1310,7 +1327,7 @@ information here as well.
 #+BEGIN_SRC emacs-lisp
 (use-package bbdb
   :config (progn
-            (bbdb-initialize 'gnus 'mail 'message 'pgp)
+            (bbdb-initialize 'gnus 'message 'pgp)
             (bbdb-mua-auto-update-init 'gnus 'message)
             (setq bbdb-send-mail-style 'gnus
                   bbdb-complete-mail-allow-cycling t
@@ -1612,13 +1629,15 @@ works really nicely.
             (ledger-report "Budget (Cumulative)" nil)))
   :config (progn
             (setq ledger-use-iso-dates t
-                  ledger-post-use-completion-engine :built-in
+                  ledger-post-use-completion-engine :ido
                   ledger-reconcile-default-commodity "€"
                   ledger-clear-whole-transactions t
                   ledger-narrow-on-reconcile t
-                  ledger-default-date-format "%Y-%m-%d"
-                  ledger-reports '(("Monthly Expenses" "ledger -f %(ledger-file) reg -M Expenses --real -l \"payee != 'Opening Balances'\"")
-                                   ("Expenses:This Month" "ledger -f %(ledger-file) bal \\^Expenses -p \"this month\"")
+                  ledger-reports `(("Monthly Expenses" "ledger -f %(ledger-file) reg -M \\^Flex --real -X EUR -l \"payee != 'Opening Balances'\"")
+                                   ("Average Monthly Expenses (Past 12 Months)" ,(concat "ledger -f %(ledger-file) -b "
+                                                                                    (format-time-string "%Y-%m" (time-add (current-time) (days-to-time -365)))
+                                                                                    " --monthly --average balance ^Flex"))
+                                   ("Expenses:This Month" "ledger -f %(ledger-file) bal \\^Flex -p \"this month\"")
                                    ("On-budget Balances" "ledger -f %(ledger-file) bal --current -R :Budget: Assets:Receivable Liabilities:Personal")
                                    ("All Account Balances" "ledger -f %(ledger-file) bal --current -R \\^Assets \\^Liabilities")
                                    ("Budget Values (Current Month)" "ledger -f %(ledger-file) bal -p \"this month\" --limit \"payee=~/budget/\" \\^Funds")
@@ -1651,7 +1670,9 @@ Org is wünderbar.
 (use-package org
   :bind (("C-c C-a" . org-agenda-list)
          ("C-c a" . org-agenda)
-         ("C-c l" . org-store-link))
+         ("C-c l" . org-store-link)
+         :map org-src-mode-map
+         ("C-x C-s" . org-edit-src-exit))
   :defer 8
   :init (setq org-replace-disputed-keys t
               org-ellipsis "…")
@@ -1746,10 +1767,10 @@ On-the-fly error checking in programming modes?  Yes please.
   :config (progn
             (global-flycheck-mode)
             (setq flycheck-check-syntax-automatically '(save mode-enabled))
-            (setq flycheck-indication-mode 'right-fringe)
+            (setq flycheck-indication-mode 'left-fringe)
             (with-eval-after-load 'git-gutter-fringe
               (fringe-helper-define 'flycheck-fringe-bitmap-double-arrow '(center repeated)
-                ".XXXXXXX"))
+                ".XXX...."))
             (if (executable-find "eslint_d")
                 (setq flycheck-javascript-eslint-executable "eslint_d"))))
 #+END_SRC
@@ -2461,22 +2482,6 @@ I like to use the clipboard more than the primary selection in X11.
   (setq x-select-request-type '(UTF8_STRING COMPOUND_TEXT TEXT STRING)))
 #+END_SRC
 
-*** Copy formatted code
-
-#+BEGIN_SRC emacs-lisp
-(bind-key* "C-c w" (define-prefix-command 'copy-as-map))
-(use-package copy-as-format
-  :bind (("C-c C-w" . copy-as-format)
-         :map copy-as-map
-         ("b" . copy-as-format-bitbucket)
-         ("g" . copy-as-format-github)
-         ("h" . copy-as-format-hipchat)
-         ("w" . copy-as-format-html)
-         ("j" . copy-as-format-jira)
-         ("m" . copy-as-format-markdown)
-         ("s" . copy-as-format-slack)))
-#+END_SRC
-
 ** Selection
 
 I’m quite used to deleting text by selecting it and typing.  Emacs has