summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Lemon <matt@matthewlemon.com>2022-10-28 14:52:43 +0100
committerMatthew Lemon <matt@matthewlemon.com>2022-10-28 14:52:43 +0100
commit24d11555c28338e3862bdf7a01f3667631d8952d (patch)
tree5ab4edc74372dbd4e7620e5857fa71dc6aa045a2
parent3577c3d4b9bee411631a28b96249696f8df865e0 (diff)
update before trying Doom
Diffstat (limited to '')
-rw-r--r--bookmarks8
-rw-r--r--init.el2
-rw-r--r--myinit.org985
-rw-r--r--org-clock-save.el2
4 files changed, 505 insertions, 492 deletions
diff --git a/bookmarks b/bookmarks
index 992622f..5e2197b 100644
--- a/bookmarks
+++ b/bookmarks
@@ -1,4 +1,4 @@
-;;;; Emacs Bookmark Format Version 1 ;;;; -*- coding: utf-8 -*-
+;;;; Emacs Bookmark Format Version 1;;;; -*- coding: utf-8; mode: lisp-data -*-
;;; This format is meant to be slightly human-readable;
;;; nevertheless, you probably don't want to edit it.
;;; -*- End Of Bookmark File Format Version Stamp -*-
@@ -39,8 +39,8 @@
(rear-context-string . " Christmas 2021\n")
(position . 2261))
("org-capture-last-stored"
- (filename . "~/org/work.org")
- (front-context-string . "** NEXT Make sur")
+ (filename . "~/org/home.org")
+ (front-context-string . "** TODO Book tic")
(rear-context-string . " Single Actions\n")
- (position . 108))
+ (position . 18))
)
diff --git a/init.el b/init.el
index a0fcbb5..24de399 100644
--- a/init.el
+++ b/init.el
@@ -34,7 +34,7 @@
'(org-agenda-files
'("~/org/home.org" "~/org/projects.org" "~/org/journal.org" "~/org/work.org" "~/org/notes.org" "~/org/habits.org" "~/org/calendar/cal.org"))
'(package-selected-packages
- '(elfeed-score yasnippet-snippets yasnippet browse-kill-ring expand-region ace-window amx flycheck ace-jump-mode gruvbox-theme company helm auto-package-update ledger-mode magit elfeed-org which-key use-package rainbow-delimiters paredit evil counsel)))
+ '(epdfinfo pdf-tools elfeed-score yasnippet-snippets yasnippet browse-kill-ring expand-region ace-window amx flycheck ace-jump-mode gruvbox-theme company helm auto-package-update ledger-mode magit elfeed-org which-key use-package rainbow-delimiters paredit evil counsel)))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
diff --git a/myinit.org b/myinit.org
index 8623be8..7afd154 100644
--- a/myinit.org
+++ b/myinit.org
@@ -290,495 +290,508 @@ This now is all about the agenda dispatcher - a critical piece of my configurato
* Rest of config
#+BEGIN_SRC emacs-lisp
- ;;; Code:
- (setq inhibit-startup-message 1)
-
- (scroll-bar-mode -1)
- (tool-bar-mode -1)
- (tooltip-mode -1)
- (set-fringe-mode 10)
-
- ;; Put backups in /tmp where they belong
- (setq backup-directory-alist
- `((".*" . ,temporary-file-directory)))
- (setq auto-save-file-name-transforms
- `((".*" ,temporary-file-directory t)))
-
- ;; recursively copy by default
- (setq dired-recursive-copies 'always)
-
- ;; y or n instead of yes or no
- (fset 'yes-or-no-p 'y-or-n-p)
-
- ;; auto revert files
- (global-auto-revert-mode t)
-
- ;; Display the current time
- (display-time-mode t)
-
- (setq visible-bell t)
-
- (set-face-attribute 'default nil :font "Iosevka Regular" :height 130)
- ;;(set-face-attribute 'default nil :font "UbuntuMono Nerd Font Mono" :height 160)
- ;;(load-theme 'tango-dark)
- (load-theme 'gruvbox-dark-hard t)
-
- ;; calendar proper Monday start
- (setq calendar-week-start-day 1)
- (setq calendar-date-style (quote european))
-
-
- (use-package dired
- :ensure nil
- :bind
- (("C-x C-j" . dired-jump)
- ("C-x j" . dired-jump-other-window))
- :custom
- ;; Always delete and copy recursively
- (dired-recursive-deletes 'always)
- (dired-recursive-copies 'always)
- ;; Auto refresh Dired, but be quiet about it
- (global-auto-revert-non-file-buffers t)
- (auto-revert-verbose nil)
- ;; Quickly copy/move file in Dired
- (dired-dwim-target t)
- ;; Move files to trash when deleting
- (delete-by-moving-to-trash t)
- :config
- ;; Reuse same dired buffer, to prevent numerous buffers while navigating in dired
+ ;;; Code:
+ (setq inhibit-startup-message 1)
+
+ (scroll-bar-mode -1)
+ (tool-bar-mode -1)
+ (tooltip-mode -1)
+ (set-fringe-mode 10)
+
+ ;; enable
+ (put 'narrow-to-defun 'disabled nil)
+ (put 'narrow-to-page 'disabled nil)
+ (put 'narrow-to-region 'disabled nil)
+
+ ;; install pdf-tools
+ (use-package pdf-tools)
+ (pdf-tools-install)
+
+ ;; Put backups in /tmp where they belong
+ (setq backup-directory-alist
+ `((".*" . ,temporary-file-directory)))
+ (setq auto-save-file-name-transforms
+ `((".*" ,temporary-file-directory t)))
+
+ ;; recursively copy by default
+ (setq dired-recursive-copies 'always)
+
+ ;; y or n instead of yes or no
+ (fset 'yes-or-no-p 'y-or-n-p)
+
+ ;; auto revert files
+ (global-auto-revert-mode t)
+
+ ;; Display the current time
+ (display-time-mode t)
+
+ (setq visible-bell t)
+
+ (set-face-attribute 'default nil :font "Iosevka Regular" :height 130)
+ ;;(set-face-attribute 'default nil :font "UbuntuMono Nerd Font Mono" :height 160)
+ ;;(load-theme 'tango-dark)
+ (load-theme 'gruvbox-dark-hard t)
+
+ ;; calendar proper Monday start
+ (setq calendar-week-start-day 1)
+ (setq calendar-date-style (quote european))
+
+
+ (use-package dired
+ :ensure nil
+ :bind
+ (("C-x C-j" . dired-jump)
+ ("C-x j" . dired-jump-other-window))
+ :custom
+ ;; Always delete and copy recursively
+ (dired-recursive-deletes 'always)
+ (dired-recursive-copies 'always)
+ ;; Auto refresh Dired, but be quiet about it
+ (global-auto-revert-non-file-buffers t)
+ (auto-revert-verbose nil)
+ ;; Quickly copy/move file in Dired
+ (dired-dwim-target t)
+ ;; Move files to trash when deleting
+ (delete-by-moving-to-trash t)
+ :config
+ ;; Reuse same dired buffer, to prevent numerous buffers while navigating in dired
+ (put 'dired-find-alternate-file 'disabled nil)
+ :hook
+ (dired-mode . (lambda ()
+ (local-set-key (kbd "<mouse-2>") #'dired-find-alternate-file)
+ (local-set-key (kbd "RET") #'dired-find-alternate-file)
+ (local-set-key (kbd "^")
+ (lambda () (interactive) (find-alternate-file ".."))))))
+
+ ;; dired config
+ ;; human readable
+ (setq-default dired-listing-switches "-alh")
+ ;; Ability to use a to visit a new directory or file in dired instead of using RET. RET works just fine,
+ ;; but it will create a new buffer for every interaction whereas a reuses the current buffer.
(put 'dired-find-alternate-file 'disabled nil)
- :hook
- (dired-mode . (lambda ()
- (local-set-key (kbd "<mouse-2>") #'dired-find-alternate-file)
- (local-set-key (kbd "RET") #'dired-find-alternate-file)
- (local-set-key (kbd "^")
- (lambda () (interactive) (find-alternate-file ".."))))))
-
- ;; dired config
- ;; human readable
- (setq-default dired-listing-switches "-alh")
-
- ;; auto package update
- (use-package auto-package-update
- :if (not (daemonp))
- :custom
- (auto-package-update-interval 7) ;; in days
- (auto-package-update-prompt-before-update t)
- (auto-package-update-delete-old-versions t)
- (auto-package-update-hide-results t)
- :config
- (auto-package-update-maybe))
-
- ;; remove certain minor modes from the mode line
- (use-package diminish)
-
- ;; some core bindings
- ;; Use iBuffer instead of Buffer List
- ;;(global-set-key (kbd "C-x C-b") #'ibuffer)
- ;; Truncate lines
- (global-set-key (kbd "C-x C-l") #'toggle-truncate-lines)
- ;; Adjust font size like web browsers
- (global-set-key (kbd "C-+") #'text-scale-increase)
- (global-set-key (kbd "C--") #'text-scale-decrease)
- ;; Move up/down paragraph
- (global-set-key (kbd "M-n") #'forward-paragraph)
- (global-set-key (kbd "M-p") #'backward-paragraph)
-
- ;; kill other buffers
- (defun kill-other-buffers ()
- "Kill all other buffers."
- (interactive)
- (mapc 'kill-buffer (delq (current-buffer) (buffer-list))))
-
- ;; Windmove - use Shift and arrow keys to move in windows
- ;; this fucks around with org mode - we want to shift timestamps and stuff
- ;;(when (fboundp 'windmove-default-keybindings)
- ;; (windmove-default-keybindings))
-
- ;; Winner mode - undo and redo changes in window config
- ;; with C-c left and C-c right
- (use-package winner
- :ensure nil
- :custom
- (winner-boring-buffers
- '("*Completions*"
- "*Compile-Log*"
- "*inferior-lisp*"
- "*Fuzzy Completions*"
- "*Apropos*"
- "*Help*"
- "*cvs*"
- "*Buffer List*"
- "*Ibuffer*"
- "*esh command on file*"))
- :config
- (winner-mode 1))
-
- ;; Handling tabs (for programming)
- (setq-default tab-width 2)
- (setq-default tab-width 2 indent-tabs-mode nil)
- (setq-default indent-tabs-mode nil)
- (setq js-indent-level 2)
- (setq coffee-tab-width 2)
- (setq python-indent 2)
- (setq css-indent-offset 2)
- (add-hook 'sh-mode-hook
- (lambda ()
- (setq sh-basic-offset 2
- sh-indentation 2)))
- (setq web-mode-markup-indent-offset 2)
-
- ;; flycheck syntax highlighting
- (use-package flycheck
- :ensure t
- :init (global-flycheck-mode))
-
- ;; turn off flycheck-mode for org
- (setq flycheck-global-modes '(not org-mode))
-
- ;; Highlight matching parens
- (show-paren-mode t)
-
- ;; Stop C-z suspending emacs
- (global-set-key (kbd "C-z") 'nil)
-
- ;; elpy for python
- (use-package elpy
- :ensure t
- :config
+ (setq dired-recursive-copies 'always)
+
+ ;; auto package update
+ (use-package auto-package-update
+ :if (not (daemonp))
+ :custom
+ (auto-package-update-interval 7) ;; in days
+ (auto-package-update-prompt-before-update t)
+ (auto-package-update-delete-old-versions t)
+ (auto-package-update-hide-results t)
+ :config
+ (auto-package-update-maybe))
+
+ ;; remove certain minor modes from the mode line
+ (use-package diminish)
+
+ ;; some core bindings
+ ;; Use iBuffer instead of Buffer List
+ ;;(global-set-key (kbd "C-x C-b") #'ibuffer)
+ ;; Truncate lines
+ (global-set-key (kbd "C-x C-l") #'toggle-truncate-lines)
+ ;; Adjust font size like web browsers
+ (global-set-key (kbd "C-+") #'text-scale-increase)
+ (global-set-key (kbd "C--") #'text-scale-decrease)
+ ;; Move up/down paragraph
+ (global-set-key (kbd "M-n") #'forward-paragraph)
+ (global-set-key (kbd "M-p") #'backward-paragraph)
+
+ ;; kill other buffers
+ (defun kill-other-buffers ()
+ "Kill all other buffers."
+ (interactive)
+ (mapc 'kill-buffer (delq (current-buffer) (buffer-list))))
+
+ ;; Windmove - use Shift and arrow keys to move in windows
+ ;; this fucks around with org mode - we want to shift timestamps and stuff
+ ;;(when (fboundp 'windmove-default-keybindings)
+ ;; (windmove-default-keybindings))
+
+ ;; Winner mode - undo and redo changes in window config
+ ;; with C-c left and C-c right
+ (use-package winner
+ :ensure nil
+ :custom
+ (winner-boring-buffers
+ '("*Completions*"
+ "*Compile-Log*"
+ "*inferior-lisp*"
+ "*Fuzzy Completions*"
+ "*Apropos*"
+ "*Help*"
+ "*cvs*"
+ "*Buffer List*"
+ "*Ibuffer*"
+ "*esh command on file*"))
+ :config
+ (winner-mode 1))
+
+ ;; Handling tabs (for programming)
+ (setq-default tab-width 2)
+ (setq-default tab-width 2 indent-tabs-mode nil)
+ (setq-default indent-tabs-mode nil)
+ (setq js-indent-level 2)
+ (setq coffee-tab-width 2)
+ (setq python-indent 2)
+ (setq css-indent-offset 2)
+ (add-hook 'sh-mode-hook
+ (lambda ()
+ (setq sh-basic-offset 2
+ sh-indentation 2)))
+ (setq web-mode-markup-indent-offset 2)
+
+ ;; flycheck syntax highlighting
+ (use-package flycheck
+ :ensure t
+ :init (global-flycheck-mode))
+
+ ;; turn off flycheck-mode for org
+ (setq flycheck-global-modes '(not org-mode))
+
+ ;; Highlight matching parens
+ (show-paren-mode t)
+
+ ;; Stop C-z suspending emacs
+ (global-set-key (kbd "C-z") 'nil)
+
+ ;; elpy for python
+ (use-package elpy
+ :ensure t
+ :config
+ (setq elpy-modules (delq 'elpy-module-flymake elpy-modules))
+ (add-hook 'elpy-mode-hook 'flycheck-mode)
+ :init
+ (elpy-enable))
+
+ (when (load "flycheck" t t)
(setq elpy-modules (delq 'elpy-module-flymake elpy-modules))
- (add-hook 'elpy-mode-hook 'flycheck-mode)
- :init
- (elpy-enable))
-
- (when (load "flycheck" t t)
- (setq elpy-modules (delq 'elpy-module-flymake elpy-modules))
- (add-hook 'elpy-mode-hook 'flycheck-mode))
-
- (use-package ivy
- :diminish
- :init
- (use-package amx :defer t)
- (use-package counsel :diminish :config (counsel-mode 1))
- (use-package swiper :defer t)
- (ivy-mode 1)
- :bind
- (("C-s" . swiper-isearch)
- ("C-x C-f" . counsel-find-file)
- ("C-x C-m" . counsel-M-x)
- ("C-h f" . counsel-describe-function)
- ("C-h v" . counsel-describe-variable)
- ("C-z s" . counsel-rg)
- ("C-x C-r" . counsel-recentf)
- ("C-z b" . counsel-buffer-or-recentf)
- ("C-z C-b" . counsel-ibuffer)
- (:map ivy-minibuffer-map
- ("C-r" . ivy-previous-line-or-history)
- ("M-RET" . ivy-immediate-done))
- (:map counsel-find-file-map
- ("C-~" . counsel-goto-local-home)))
- :custom
- (ivy-use-virtual-buffers t)
- (ivy-height 10)
- (ivy-on-del-error-function nil)
- (ivy-magic-slash-non-match-action 'ivy-magic-slash-non-match-create)
- (ivy-count-format "【%d/%d】")
- (ivy-wrap t)
- :config
- (setq projectile-completion-system 'ivy)
- (defun counsel-goto-local-home ()
- "Go to the $HOME of the local machine."
+ (add-hook 'elpy-mode-hook 'flycheck-mode))
+
+ (use-package ivy
+ :diminish
+ :init
+ (use-package amx :defer t)
+ (use-package counsel :diminish :config (counsel-mode 1))
+ (use-package swiper :defer t)
+ (ivy-mode 1)
+ :bind
+ (("C-s" . swiper-isearch)
+ ("C-x C-f" . counsel-find-file)
+ ("C-x C-m" . counsel-M-x)
+ ("C-h f" . counsel-describe-function)
+ ("C-h v" . counsel-describe-variable)
+ ("C-z s" . counsel-rg)
+ ("C-x C-r" . counsel-recentf)
+ ("C-z b" . counsel-buffer-or-recentf)
+ ("C-z C-b" . counsel-ibuffer)
+ (:map ivy-minibuffer-map
+ ("C-r" . ivy-previous-line-or-history)
+ ("M-RET" . ivy-immediate-done))
+ (:map counsel-find-file-map
+ ("C-~" . counsel-goto-local-home)))
+ :custom
+ (ivy-use-virtual-buffers t)
+ (ivy-height 10)
+ (ivy-on-del-error-function nil)
+ (ivy-magic-slash-non-match-action 'ivy-magic-slash-non-match-create)
+ (ivy-count-format "【%d/%d】")
+ (ivy-wrap t)
+ :config
+ (setq projectile-completion-system 'ivy)
+ (defun counsel-goto-local-home ()
+ "Go to the $HOME of the local machine."
+ (interactive)
+ (ivy--cd "~/")))
+
+ ;; Ace Window
+ (use-package ace-window
+ :bind (("C-x o" . ace-window)
+ ("M-2" . ace-window))
+ :init
+ (setq aw-background t
+ aw-keys '(?a ?o ?e ?u ?i ?d ?h ?t ?n ?s)))
+
+ ;; expand-region
+ (use-package expand-region
+ :bind (("C-@" . er/expand-region)
+ ("C-=" . er/expand-region)
+ ("M-3" . er/expand-region)))
+
+ ;; browse-kill-ring
+ (use-package browse-kill-ring
+ :bind ("C-x C-y" . browse-kill-ring)
+ :config
+ (setq browse-kill-ring-quit-action 'kill-and-delete-window))
+
+ (setq save-interprogram-paste-before-kill t)
+
+
+ ;; recentf
+ (use-package recentf
+ :hook (after-init . recentf-mode)
+ :custom
+ (recentf-auto-cleanup "05:00am")
+ (recentf-exclude '((expand-file-name package-user-dir)
+ ".cache"
+ ".cask"
+ ".elfeed"
+ "bookmarks"
+ "cache"
+ "ido.*"
+ "persp-confs"
+ "recentf"
+ "undo-tree-hist"
+ "url"
+ "COMMIT_EDITMSG\\'"))
+ (setq recentf-auto-cleanup 'never
+ recentf-max-saved-items 50
+ recentf-save-file (concat user-emacs-directory ".recentf"))
+ (setq recentf-max-menu-items 25)
+ (setq recentf-max-saved-items 25)
+ (recentf-mode t))
+
+ ;; encoding
+ (prefer-coding-system 'utf-8)
+ (setq coding-system-for-read 'utf-8)
+ (setq coding-system-for-write 'utf-8)
+
+ ;; beacon mode
+ (use-package beacon
+ :config
+ (setq beacon-color "OrangeRed")
+ (beacon-mode 1))
+
+ ;; (use-package ivy
+ ;; :bind (("C-s" . swiper)
+ ;; :map ivy-minibuffer-map
+ ;; ("TAB" . ivy-alt-done)
+ ;; ("C-l" . ivy-alt-done)
+ ;; ("C-j" . ivy-next-line)
+ ;; ("C-k" . ivy-previous-line)
+ ;; :map ivy-switch-buffer-map
+ ;; ("C-k" . ivy-previous-line)
+ ;; ("C-l" . ivy-done)
+ ;; ("C-d" . ivy-switch-buffer-kill)
+ ;; :map ivy-reverse-i-search-map
+ ;; ("C-k" . ivy-previous-line)
+ ;; ("C-d" . ivy-reverse-i-search-kill))
+ ;; :config
+ ;; (ivy-mode 1))
+
+
+ ;; Yasnippet
+ (use-package yasnippet
+ :diminish yas-minor-mode
+ :hook ((prog-mode LaTeX-mode org-mode) . yas-minor-mode)
+ :bind
+ (:map yas-minor-mode-map ("C-c C-n" . yas-expand-from-trigger-key))
+ (:map yas-keymap
+ (("TAB" . smarter-yas-expand-next-field)
+ ([(tab)] . smarter-yas-expand-next-field)))
+ :config
+ (use-package yasnippet-snippets)
+ (yas-reload-all)
+ (defun smarter-yas-expand-next-field ()
+ "Try to `yas-expand' then `yas-next-field' at current cursor position."
(interactive)
- (ivy--cd "~/")))
-
- ;; Ace Window
- (use-package ace-window
- :bind (("C-x o" . ace-window)
- ("M-2" . ace-window))
- :init
- (setq aw-background t
- aw-keys '(?a ?o ?e ?u ?i ?d ?h ?t ?n ?s)))
-
- ;; expand-region
- (use-package expand-region
- :bind (("C-@" . er/expand-region)
- ("C-=" . er/expand-region)
- ("M-3" . er/expand-region)))
-
- ;; browse-kill-ring
- (use-package browse-kill-ring
- :bind ("C-x C-y" . browse-kill-ring)
- :config
- (setq browse-kill-ring-quit-action 'kill-and-delete-window))
-
- (setq save-interprogram-paste-before-kill t)
-
-
- ;; recentf
- (use-package recentf
- :hook (after-init . recentf-mode)
- :custom
- (recentf-auto-cleanup "05:00am")
- (recentf-exclude '((expand-file-name package-user-dir)
- ".cache"
- ".cask"
- ".elfeed"
- "bookmarks"
- "cache"
- "ido.*"
- "persp-confs"
- "recentf"
- "undo-tree-hist"
- "url"
- "COMMIT_EDITMSG\\'"))
- (setq recentf-auto-cleanup 'never
- recentf-max-saved-items 50
- recentf-save-file (concat user-emacs-directory ".recentf"))
- (setq recentf-max-menu-items 25)
- (setq recentf-max-saved-items 25)
- (recentf-mode t))
-
- ;; encoding
- (prefer-coding-system 'utf-8)
- (setq coding-system-for-read 'utf-8)
- (setq coding-system-for-write 'utf-8)
-
- ;; beacon mode
- (use-package beacon
- :config
- (setq beacon-color "OrangeRed")
- (beacon-mode 1))
-
- ;; (use-package ivy
- ;; :bind (("C-s" . swiper)
- ;; :map ivy-minibuffer-map
- ;; ("TAB" . ivy-alt-done)
- ;; ("C-l" . ivy-alt-done)
- ;; ("C-j" . ivy-next-line)
- ;; ("C-k" . ivy-previous-line)
- ;; :map ivy-switch-buffer-map
- ;; ("C-k" . ivy-previous-line)
- ;; ("C-l" . ivy-done)
- ;; ("C-d" . ivy-switch-buffer-kill)
- ;; :map ivy-reverse-i-search-map
- ;; ("C-k" . ivy-previous-line)
- ;; ("C-d" . ivy-reverse-i-search-kill))
- ;; :config
- ;; (ivy-mode 1))
-
-
- ;; Yasnippet
- (use-package yasnippet
- :diminish yas-minor-mode
- :hook ((prog-mode LaTeX-mode org-mode) . yas-minor-mode)
- :bind
- (:map yas-minor-mode-map ("C-c C-n" . yas-expand-from-trigger-key))
- (:map yas-keymap
- (("TAB" . smarter-yas-expand-next-field)
- ([(tab)] . smarter-yas-expand-next-field)))
- :config
- (use-package yasnippet-snippets)
- (yas-reload-all)
- (defun smarter-yas-expand-next-field ()
- "Try to `yas-expand' then `yas-next-field' at current cursor position."
- (interactive)
- (let ((old-point (point))
- (old-tick (buffer-chars-modified-tick)))
- (yas-expand)
- (when (and (eq old-point (point))
- (eq old-tick (buffer-chars-modified-tick)))
- (ignore-errors (yas-next-field))))))
-
- ;; this config works better with yasnippet
- (use-package company
- :diminish company-mode
- :hook ((prog-mode LaTeX-mode latex-mode ess-r-mode ledger-mode) . company-mode)
- :bind
- (:map company-active-map
- ([tab] . smarter-yas-expand-next-field-complete)
- ("TAB" . smarter-yas-expand-next-field-complete))
- :custom
- (company-tooltip-align-annotations t)
- (company-begin-commands '(self-insert-command))
- (company-require-match 'never)
- ;; Don't use company in the following modes
- (company-global-modes '(not shell-mode eaf-mode))
- ;; Trigger completion immediately.
- (company-idle-delay 0.1)
- ;; Number the candidates (use M-1, M-2 etc to select completions).
- (company-show-numbers t)
- :config
- ;; clangd variable not present which was a problem
- ;; (unless *clangd* (delete 'company-clang company-backends))
- ;; (global-company-mode 1)
- (setq company-idle-delay 0)
- (setq company-minimum-prefix-length 3)
- (defun smarter-yas-expand-next-field-complete ()
- "Try to `yas-expand' and `yas-next-field' at current cursor position.
-
- If failed try to complete the common part with `company-complete-common'"
- (interactive)
- (if yas-minor-mode
- (let ((old-point (point))
- (old-tick (buffer-chars-modified-tick)))
- (yas-expand)
- (when (and (eq old-point (point))
- (eq old-tick (buffer-chars-modified-tick)))
- (ignore-errors (yas-next-field))
+ (let ((old-point (point))
+ (old-tick (buffer-chars-modified-tick)))
+ (yas-expand)
+ (when (and (eq old-point (point))
+ (eq old-tick (buffer-chars-modified-tick)))
+ (ignore-errors (yas-next-field))))))
+
+ ;; this config works better with yasnippet
+ (use-package company
+ :diminish company-mode
+ :hook ((prog-mode LaTeX-mode latex-mode ess-r-mode ledger-mode) . company-mode)
+ :bind
+ (:map company-active-map
+ ([tab] . smarter-yas-expand-next-field-complete)
+ ("TAB" . smarter-yas-expand-next-field-complete))
+ :custom
+ (company-tooltip-align-annotations t)
+ (company-begin-commands '(self-insert-command))
+ (company-require-match 'never)
+ ;; Don't use company in the following modes
+ (company-global-modes '(not shell-mode eaf-mode))
+ ;; Trigger completion immediately.
+ (company-idle-delay 0.1)
+ ;; Number the candidates (use M-1, M-2 etc to select completions).
+ (company-show-numbers t)
+ :config
+ ;; clangd variable not present which was a problem
+ ;; (unless *clangd* (delete 'company-clang company-backends))
+ ;; (global-company-mode 1)
+ (setq company-idle-delay 0)
+ (setq company-minimum-prefix-length 3)
+ (defun smarter-yas-expand-next-field-complete ()
+ "Try to `yas-expand' and `yas-next-field' at current cursor position.
+
+ If failed try to complete the common part with `company-complete-common'"
+ (interactive)
+ (if yas-minor-mode
+ (let ((old-point (point))
+ (old-tick (buffer-chars-modified-tick)))
+ (yas-expand)
(when (and (eq old-point (point))
(eq old-tick (buffer-chars-modified-tick)))
- (company-complete-common))))
- (company-complete-common))))
-
-
- ;; Ace Jump
- (use-package ace-jump-mode
- :bind ("C-M-SPC" . ace-jump-mode))
-
- ;; Lisp programming
- (use-package paredit
- :init
- (add-hook 'clojure-mode-hook #'enable-paredit-mode)
- (add-hook 'cider-repl-mode-hook #'enable-paredit-mode)
- (add-hook 'emacs-lisp-mode-hook #'enable-paredit-mode)
- (add-hook 'eval-expression-minibuffer-setup-hook #'enable-paredit-mode)
- (add-hook 'ielm-mode-hook #'enable-paredit-mode)
- (add-hook 'lisp-mode-hook #'enable-paredit-mode)
- (add-hook 'lisp-interaction-mode-hook #'enable-paredit-mode)
- (add-hook 'scheme-mode-hook #'enable-paredit-mode)
- :config
- (show-paren-mode t)
- :bind (("M-[" . paredit-wrap-square)
- ("M-{" . paredit-wrap-curly))
- :diminish nil)
-
- (use-package rainbow-delimiters
- :config
- (add-hook 'prog-mode-hook 'rainbow-delimiters-mode))
-
- ;; EVIL
- (use-package evil
- :init
- :config
- (setq evil-respect-visual-line-mode t)
- (setq evil-default-state 'emacs)
- (evil-mode 1))
-
- ; ;; which-key - for nice menu
- ; (use-package which-key
- ; :config
- ; (which-key-mode)
- ; )
-
- ;; which-key
- (use-package which-key
- :config
- (which-key-mode))
-
- ;; elfeed
- (use-package elfeed
- :config
- (setq elfeed-feeds
- '(("http://feeds.bbci.co.uk/news/rss.xml?edition=uk" news)
- ("http://feeds.bbci.co.uk/news/technology/rss.xml" tech news)
- ("https://planet.emacslife.com/atom.xml" emacs)
- ("https://irreal.org/blog/?feed=rss2" emacs)
- ("https://karl-voit.at/feeds/lazyblorg-all.atom_1.0.links-only.xml" emacs)
- ("https://dominiccummings.com/rss.xml" blog tech)
- ("https://usesthis.com/feed.atom" tech blog)
- ("https://plaintextproject.online/feed.xml" plaintext productivity)
- ("https://feeds.feedburner.com/StudyHacks" productivity)
- ("http://newsrss.bbc.co.uk/rss/sportonline_uk_edition/rugby_union/rss.xml" rugby)
- ("http://feeds.bbci.co.uk/news/video_and_audio/politics/rss.xml" news)
- ("https://feeds.feedburner.com/arstechnica/open-source" opensource)
- ("https://www.computerweekly.com/rss/IT-security.xml" cyber)
- ("http://tonsky.me/blog/atom.xml" blog)
- ("https://akkshaya.blog/feed" blob)
- ("https://miguelmota.com/index.xml" blog)
- ("https://www.computerweekly.com/rss/IT-security.xml" security)
- ("https://www.fsf.org/static/fsforg/rss/news.xml" opensource)
- ("https://www.reddit.com/r/emacs.rss" emacs)
- ("https://www.reddit.com/r/rugbyunion/.rss" rugby)
- ("http://pragmaticemacs.com/feed/" emacs)
- ("https://200ok.ch/atom.xml" emacs)
- ("http://www.linuxinsider.com/perl/syndication/rssfull.pl" linux)
- ("http://planet.debian.org/rss20.xml" debian linux)
- ("http://feeds2.feedburner.com/Command-line-fu" linux)
- ("https://opensource.org/news.xml" opensource)
- ("https://www.wired.com/feed/rss" news tech)
- ("https://sivers.org/en.atom" blog))))
-
- ;; get scoring in elfeed
- (use-package elfeed-score
- :ensure t
- :config
- (progn
- (elfeed-score-enable)
- (define-key elfeed-search-mode-map "=" elfeed-score-map)))
-
- ;; Basic magit
- (use-package magit
- :bind ("C-x g" . magit-status))
-
- ;; ido
-
- (ido-mode 1)
- ;; Interactively Do Things (ido)
- (use-package ido
- :config
- (ido-mode t)
- (ido-everywhere t)
- (setq ido-enable-flex-matching t)
- (setq ido-everywhere t)
- (setq ido-file-extensions-order '(".org" ".txt" ".py" ".emacs" ".md" ".xml" ".el" ".ini"))
- (setq ido-enable-flex-matching t))
-
-
- ;; ;; helm
- ;; (require 'helm-config)
- ;; (global-set-key (kbd "M-x") #'helm-M-x)
- ;; (global-set-key (kbd "C-x r b") #'helm-filtered-bookmarks)
- ;; (global-set-key (kbd "C-x C-f") #'helm-find-files)
- ;; ;; The default "C-x c" is quite close to "C-x C-c", which quits Emacs.
- ;; ;; Changed to "C-c h". Note: We must set "C-c h" globally, because we
- ;; ;; cannot change `helm-command-prefix-key' once `helm-config' is loaded.
- ;; (global-set-key (kbd "C-c h") 'helm-command-prefix)
- ;; (global-unset-key (kbd "C-x c"))
- ;; (helm-mode 1)
-
- ;; ledger mode
- (use-package ledger-mode
- :mode ("\\.ledger\\'")
- :config
- ;; (setq ledger-default-date-format "%d/%m/%Y")
- (setq ledger-reports
- '(("hsbc_current_account" "ledger [[ledger-mode-flags]] --date-format \"%d/%m/%Y\" -f /home/lemon/Documents/Budget/ledger/2021/budget2021.ledger reg Assets\\:HSBC\\:Current")
- ("bal" "%(binary) -f %(ledger-file) bal")
- ("reg" "%(binary) -f %(ledger-file) reg")
- ("payee" "%(binary) -f %(ledger-file) reg @%(payee)")
- ("account" "%(binary) -f %(ledger-file) reg %(account)")))
- (add-hook 'ledger-mode-hook
- (lambda ()
- (setq-local tab-always-indent 'complete)
- (setq-local completion-cycle-threshold t)
- (setq-local ledger-complete-in-steps t)))
- :custom (ledger-clear-whole-transactions t))
-
-
- (custom-set-variables
- ;; custom-set-variables was added by Custom.
- ;; If you edit it by hand, you could mess it up, so be careful.
- ;; Your init file should contain only one such instance.
- ;; If there is more than one, they won't work right.
- '(company-show-quick-access t nil nil "Customized with use-package company")
- '(custom-safe-themes
- '("6b5c518d1c250a8ce17463b7e435e9e20faa84f3f7defba8b579d4f5925f60c1" default))
- '(package-selected-packages
- '(elfeed-score yasnippet-snippets yasnippet browse-kill-ring expand-region ace-window amx flycheck ace-jump-mode gruvbox-theme company helm auto-package-update ledger-mode magit elfeed-org which-key use-package rainbow-delimiters paredit evil counsel)))
- (custom-set-faces
- ;; custom-set-faces was added by Custom.
- ;; If you edit it by hand, you could mess it up, so be careful.
- ;; Your init file should contain only one such instance.
- ;; If there is more than one, they won't work right.
- )
+ (ignore-errors (yas-next-field))
+ (when (and (eq old-point (point))
+ (eq old-tick (buffer-chars-modified-tick)))
+ (company-complete-common))))
+ (company-complete-common))))
+
+
+ ;; Ace Jump
+ (use-package ace-jump-mode
+ :bind ("C-M-SPC" . ace-jump-mode))
+
+ ;; Lisp programming
+ (use-package paredit
+ :init
+ (add-hook 'clojure-mode-hook #'enable-paredit-mode)
+ (add-hook 'cider-repl-mode-hook #'enable-paredit-mode)
+ (add-hook 'emacs-lisp-mode-hook #'enable-paredit-mode)
+ (add-hook 'eval-expression-minibuffer-setup-hook #'enable-paredit-mode)
+ (add-hook 'ielm-mode-hook #'enable-paredit-mode)
+ (add-hook 'lisp-mode-hook #'enable-paredit-mode)
+ (add-hook 'lisp-interaction-mode-hook #'enable-paredit-mode)
+ (add-hook 'scheme-mode-hook #'enable-paredit-mode)
+ :config
+ (show-paren-mode t)
+ :bind (("M-[" . paredit-wrap-square)
+ ("M-{" . paredit-wrap-curly))
+ :diminish nil)
+
+ (use-package rainbow-delimiters
+ :config
+ (add-hook 'prog-mode-hook 'rainbow-delimiters-mode))
+
+ ;; EVIL
+ (use-package evil
+ :init
+ :config
+ (setq evil-respect-visual-line-mode t)
+ (setq evil-default-state 'emacs)
+ (evil-mode 1))
+
+ ; ;; which-key - for nice menu
+ ; (use-package which-key
+ ; :config
+ ; (which-key-mode)
+ ; )
+
+ ;; which-key
+ (use-package which-key
+ :config
+ (which-key-mode))
+
+ ;; elfeed
+ (use-package elfeed
+ :config
+ (setq elfeed-feeds
+ '(("http://feeds.bbci.co.uk/news/rss.xml?edition=uk" news)
+ ("http://feeds.bbci.co.uk/news/technology/rss.xml" tech news)
+ ("https://planet.emacslife.com/atom.xml" emacs)
+ ("https://irreal.org/blog/?feed=rss2" emacs)
+ ("https://karl-voit.at/feeds/lazyblorg-all.atom_1.0.links-only.xml" emacs)
+ ("https://dominiccummings.com/rss.xml" blog tech)
+ ("https://usesthis.com/feed.atom" tech blog)
+ ("https://plaintextproject.online/feed.xml" plaintext productivity)
+ ("https://feeds.feedburner.com/StudyHacks" productivity)
+ ("http://newsrss.bbc.co.uk/rss/sportonline_uk_edition/rugby_union/rss.xml" rugby)
+ ("http://feeds.bbci.co.uk/news/video_and_audio/politics/rss.xml" news)
+ ("https://feeds.feedburner.com/arstechnica/open-source" opensource)
+ ("https://www.computerweekly.com/rss/IT-security.xml" cyber)
+ ("http://tonsky.me/blog/atom.xml" blog)
+ ("https://akkshaya.blog/feed" blob)
+ ("https://miguelmota.com/index.xml" blog)
+ ("https://www.computerweekly.com/rss/IT-security.xml" security)
+ ("https://www.fsf.org/static/fsforg/rss/news.xml" opensource)
+ ("https://www.reddit.com/r/emacs.rss" emacs)
+ ("https://www.reddit.com/r/rugbyunion/.rss" rugby)
+ ("http://pragmaticemacs.com/feed/" emacs)
+ ("https://200ok.ch/atom.xml" emacs)
+ ("http://www.linuxinsider.com/perl/syndication/rssfull.pl" linux)
+ ("http://planet.debian.org/rss20.xml" debian linux)
+ ("http://feeds2.feedburner.com/Command-line-fu" linux)
+ ("https://opensource.org/news.xml" opensource)
+ ("https://www.wired.com/feed/rss" news tech)
+ ("https://sivers.org/en.atom" blog))))
+
+ ;; get scoring in elfeed
+ (use-package elfeed-score
+ :ensure t
+ :config
+ (progn
+ (elfeed-score-enable)
+ (define-key elfeed-search-mode-map "=" elfeed-score-map)))
+
+ ;; Basic magit
+ (use-package magit
+ :bind ("C-x g" . magit-status))
+
+ ;; ido
+
+ (ido-mode 1)
+ ;; Interactively Do Things (ido)
+ (use-package ido
+ :config
+ (ido-mode t)
+ (ido-everywhere t)
+ (setq ido-enable-flex-matching t)
+ (setq ido-everywhere t)
+ (setq ido-file-extensions-order '(".org" ".txt" ".py" ".emacs" ".md" ".xml" ".el" ".ini"))
+ (setq ido-enable-flex-matching t))
+
+
+ ;; ;; helm
+ ;; (require 'helm-config)
+ ;; (global-set-key (kbd "M-x") #'helm-M-x)
+ ;; (global-set-key (kbd "C-x r b") #'helm-filtered-bookmarks)
+ ;; (global-set-key (kbd "C-x C-f") #'helm-find-files)
+ ;; ;; The default "C-x c" is quite close to "C-x C-c", which quits Emacs.
+ ;; ;; Changed to "C-c h". Note: We must set "C-c h" globally, because we
+ ;; ;; cannot change `helm-command-prefix-key' once `helm-config' is loaded.
+ ;; (global-set-key (kbd "C-c h") 'helm-command-prefix)
+ ;; (global-unset-key (kbd "C-x c"))
+ ;; (helm-mode 1)
+
+ ;; ledger mode
+ (use-package ledger-mode
+ :mode ("\\.ledger\\'")
+ :config
+ ;; (setq ledger-default-date-format "%d/%m/%Y")
+ (setq ledger-reports
+ '(("hsbc_current_account" "ledger [[ledger-mode-flags]] --date-format \"%d/%m/%Y\" -f /home/lemon/Documents/Budget/ledger/2021/budget2021.ledger reg Assets\\:HSBC\\:Current")
+ ("bal" "%(binary) -f %(ledger-file) bal")
+ ("reg" "%(binary) -f %(ledger-file) reg")
+ ("payee" "%(binary) -f %(ledger-file) reg @%(payee)")
+ ("account" "%(binary) -f %(ledger-file) reg %(account)")))
+ (add-hook 'ledger-mode-hook
+ (lambda ()
+ (setq-local tab-always-indent 'complete)
+ (setq-local completion-cycle-threshold t)
+ (setq-local ledger-complete-in-steps t)))
+ :custom (ledger-clear-whole-transactions t))
+
+
+ (custom-set-variables
+ ;; custom-set-variables was added by Custom.
+ ;; If you edit it by hand, you could mess it up, so be careful.
+ ;; Your init file should contain only one such instance.
+ ;; If there is more than one, they won't work right.
+ '(company-show-quick-access t nil nil "Customized with use-package company")
+ '(custom-safe-themes
+ '("6b5c518d1c250a8ce17463b7e435e9e20faa84f3f7defba8b579d4f5925f60c1" default))
+ '(package-selected-packages
+ '(elfeed-score yasnippet-snippets yasnippet browse-kill-ring expand-region ace-window amx flycheck ace-jump-mode gruvbox-theme company helm auto-package-update ledger-mode magit elfeed-org which-key use-package rainbow-delimiters paredit evil counsel)))
+ (custom-set-faces
+ ;; custom-set-faces was added by Custom.
+ ;; If you edit it by hand, you could mess it up, so be careful.
+ ;; Your init file should contain only one such instance.
+ ;; If there is more than one, they won't work right.
+ )
#+END_SRC
diff --git a/org-clock-save.el b/org-clock-save.el
index 079e53a..aea83e5 100644
--- a/org-clock-save.el
+++ b/org-clock-save.el
@@ -1,2 +1,2 @@
-;; org-clock-save.el - pop-os at <2022-10-27 Thu 19:11>
+;; org-clock-save.el - archdesk at <2022-10-28 Fri 14:51>
(setq org-clock-stored-history '(("/home/lemon/org/archive.org" . 24934) ("/home/lemon/org/archive.org" . 61601) ("/home/lemon/org/work.org" . 1) ("/home/lemon/org/home.org" . 1)))