@ -1,2 +1,7 @@ | |||
/.hive-maint | |||
/var | |||
auto-save-list | |||
/history | |||
*.elc | |||
/recentf~ | |||
recentf |
@ -0,0 +1,78 @@ | |||
;; This file is automatically generated by the multiple-cursors extension. | |||
;; It keeps track of your preferences for running commands with multiple cursors. | |||
(setq mc/cmds-to-run-for-all | |||
'( | |||
LaTeX-babel-insert-hyphen | |||
LaTeX-insert-left-brace | |||
TeX-insert-backslash | |||
ace-jump-done | |||
ace-jump-mode | |||
ace-jump-move | |||
amd-kill-line | |||
artist-forward-char | |||
backward-sentence | |||
backward-sexp | |||
c-electric-delete-forward | |||
coffee-dedent-line-backspace | |||
comment-dwim | |||
counsel-yank-pop | |||
dabbrev-expand | |||
electric-pair-delete-pair | |||
end-of-visual-line | |||
eval-and-replace | |||
eval-last-sexp | |||
exchange-point-and-mark-noactivate | |||
forward-sexp | |||
helm-M-x | |||
indent-for-tab-command | |||
insert-register | |||
ivy-done | |||
js2r-kill | |||
js2r-rename-var | |||
kill-region | |||
markdown-enter-key | |||
org-beginning-of-line | |||
org-delete-char | |||
org-end-of-line | |||
org-kill-line | |||
org-self-insert-command | |||
orgtbl-hijacker-command-109 | |||
orgtbl-self-insert-command | |||
paredit-backslash | |||
paredit-backward | |||
paredit-backward-kill-word | |||
paredit-backward-slurp-sexp | |||
paredit-comment-dwim | |||
paredit-doublequote | |||
paredit-forward | |||
paredit-forward-delete | |||
paredit-forward-kill-word | |||
paredit-forward-slurp-sexp | |||
paredit-kill | |||
paredit-meta-doublequote | |||
paredit-open-round | |||
paredit-raise-sexp | |||
paredit-wrap-round | |||
picture-backward-clear-column | |||
picture-clear-column | |||
picture-self-insert | |||
sgml-slash | |||
transpose-words | |||
wdired-finish-edit | |||
web-mode-element-insert | |||
wgrep-finish-edit | |||
yaml-electric-backspace | |||
yas-expand | |||
)) | |||
(setq mc/cmds-to-run-once | |||
'( | |||
edebug-step-mode | |||
end-of-buffer | |||
ido-switch-buffer | |||
js2r-extract-var | |||
markdown-exdent-or-delete | |||
mu4e | |||
paredit-semicolon | |||
)) |
@ -0,0 +1,2 @@ | |||
-/elpa | |||
-/.cask |
@ -0,0 +1 @@ | |||
My Emacs config |
@ -0,0 +1,418 @@ | |||
;;-*-coding: utf-8;-*- | |||
(define-abbrev-table 'Buffer-menu-mode-abbrev-table '()) | |||
(define-abbrev-table 'Custom-mode-abbrev-table '()) | |||
(define-abbrev-table 'Info-edit-mode-abbrev-table '()) | |||
(define-abbrev-table 'Man-mode-abbrev-table '()) | |||
(define-abbrev-table 'ag-mode-abbrev-table '()) | |||
(define-abbrev-table 'apropos-mode-abbrev-table '()) | |||
(define-abbrev-table 'awk-mode-abbrev-table | |||
'( | |||
)) | |||
(define-abbrev-table 'bibtex-mode-abbrev-table '()) | |||
(define-abbrev-table 'bookmark-bmenu-mode-abbrev-table '()) | |||
(define-abbrev-table 'bookmark-edit-annotation-mode-abbrev-table '()) | |||
(define-abbrev-table 'browse-kill-ring-edit-mode-abbrev-table '()) | |||
(define-abbrev-table 'browse-kill-ring-mode-abbrev-table '()) | |||
(define-abbrev-table 'c++-mode-abbrev-table | |||
'( | |||
)) | |||
(define-abbrev-table 'c-mode-abbrev-table | |||
'( | |||
)) | |||
(define-abbrev-table 'calc-trail-mode-abbrev-table '()) | |||
(define-abbrev-table 'calendar-mode-abbrev-table '()) | |||
(define-abbrev-table 'change-log-mode-abbrev-table '()) | |||
(define-abbrev-table 'cider-browse-ns-mode-abbrev-table '()) | |||
(define-abbrev-table 'cider-connections-buffer-mode-abbrev-table '()) | |||
(define-abbrev-table 'cider-docview-mode-abbrev-table '()) | |||
(define-abbrev-table 'cider-inspector-mode-abbrev-table '()) | |||
(define-abbrev-table 'cider-repl-mode-abbrev-table '()) | |||
(define-abbrev-table 'cider-stacktrace-mode-abbrev-table '()) | |||
(define-abbrev-table 'cider-test-report-mode-abbrev-table '()) | |||
(define-abbrev-table 'cljr--change-signature-mode-abbrev-table '()) | |||
(define-abbrev-table 'clojure-mode-abbrev-table '()) | |||
(define-abbrev-table 'clojurec-mode-abbrev-table '()) | |||
(define-abbrev-table 'clojurescript-mode-abbrev-table '()) | |||
(define-abbrev-table 'clojurex-mode-abbrev-table '()) | |||
(define-abbrev-table 'comint-mode-abbrev-table '()) | |||
(define-abbrev-table 'completion-list-mode-abbrev-table '()) | |||
(define-abbrev-table 'conf-colon-mode-abbrev-table '()) | |||
(define-abbrev-table 'conf-javaprop-mode-abbrev-table '()) | |||
(define-abbrev-table 'conf-ppd-mode-abbrev-table '()) | |||
(define-abbrev-table 'conf-space-mode-abbrev-table '()) | |||
(define-abbrev-table 'conf-unix-mode-abbrev-table '()) | |||
(define-abbrev-table 'conf-windows-mode-abbrev-table '()) | |||
(define-abbrev-table 'conf-xdefaults-mode-abbrev-table '()) | |||
(define-abbrev-table 'css-mode-abbrev-table '()) | |||
(define-abbrev-table 'dcl-mode-abbrev-table '()) | |||
(define-abbrev-table 'debugger-mode-abbrev-table '()) | |||
(define-abbrev-table 'diary-fancy-display-mode-abbrev-table '()) | |||
(define-abbrev-table 'diary-mode-abbrev-table '()) | |||
(define-abbrev-table 'diff-mode-abbrev-table '()) | |||
(define-abbrev-table 'dig-mode-abbrev-table '()) | |||
(define-abbrev-table 'edebug-eval-mode-abbrev-table '()) | |||
(define-abbrev-table 'edit-abbrevs-mode-abbrev-table '()) | |||
(define-abbrev-table 'elisp-byte-code-mode-abbrev-table '()) | |||
(define-abbrev-table 'emacs-lisp-mode-abbrev-table '()) | |||
(define-abbrev-table 'epa-info-mode-abbrev-table '()) | |||
(define-abbrev-table 'epa-key-list-mode-abbrev-table '()) | |||
(define-abbrev-table 'epa-key-mode-abbrev-table '()) | |||
(define-abbrev-table 'ert-results-mode-abbrev-table '()) | |||
(define-abbrev-table 'ert-simple-view-mode-abbrev-table '()) | |||
(define-abbrev-table 'eshell-mode-abbrev-table '()) | |||
(define-abbrev-table 'flycheck-error-list-mode-abbrev-table '()) | |||
(define-abbrev-table 'fundamental-mode-abbrev-table '()) | |||
(define-abbrev-table 'gdb-breakpoints-mode-abbrev-table '()) | |||
(define-abbrev-table 'gdb-disassembly-mode-abbrev-table '()) | |||
(define-abbrev-table 'gdb-frames-mode-abbrev-table '()) | |||
(define-abbrev-table 'gdb-locals-mode-abbrev-table '()) | |||
(define-abbrev-table 'gdb-memory-mode-abbrev-table '()) | |||
(define-abbrev-table 'gdb-registers-mode-abbrev-table '()) | |||
(define-abbrev-table 'gdb-script-mode-abbrev-table '()) | |||
(define-abbrev-table 'gdb-threads-mode-abbrev-table '()) | |||
(define-abbrev-table 'gfm-mode-abbrev-table '()) | |||
(define-abbrev-table 'ggtags-global-mode-abbrev-table '()) | |||
(define-abbrev-table 'ggtags-view-search-history-mode-abbrev-table '()) | |||
(define-abbrev-table 'git-rebase-mode-abbrev-table '()) | |||
(define-abbrev-table 'global-abbrev-table | |||
'( | |||
("accomodate" "accommodate" nil 0) | |||
("apres" "après" nil 2) | |||
("bebes" "bébés" nil 0) | |||
("beleive" "believe" nil 0) | |||
("bientot" "bientôt" nil 3) | |||
("completement" "complètement" nil 1) | |||
("componenp" "component" nil 0) | |||
("custon" "custom" nil 0) | |||
("etre" "être" nil 0) | |||
("facon" "façon" nil 0) | |||
("genera" "gênera" nil 0) | |||
("helol" "hello" nil 0) | |||
("interesse" "intéresse" nil 0) | |||
("interessé" "intéressé" nil 0) | |||
("intéréssés" "intéressés" nil 0) | |||
("nioc" "nco" nil 0) | |||
("oeil" "œil" nil 0) | |||
("recu" "reçu" nil 0) | |||
("reparer" "réparer" nil 0) | |||
("tres" "très" nil 0) | |||
("widjet" "widget" nil 0) | |||
)) | |||
(define-abbrev-table 'gnus-article-edit-mode-abbrev-table '()) | |||
(define-abbrev-table 'gnus-article-mode-abbrev-table '()) | |||
(define-abbrev-table 'gnus-group-mode-abbrev-table '()) | |||
(define-abbrev-table 'gnus-sticky-article-mode-abbrev-table '()) | |||
(define-abbrev-table 'google-maps-static-mode-abbrev-table '()) | |||
(define-abbrev-table 'grep-mode-abbrev-table '()) | |||
(define-abbrev-table 'gud-mode-abbrev-table '()) | |||
(define-abbrev-table 'helm-ag-mode-abbrev-table '()) | |||
(define-abbrev-table 'helm-grep-mode-abbrev-table '()) | |||
(define-abbrev-table 'helm-major-mode-abbrev-table '()) | |||
(define-abbrev-table 'helm-moccur-mode-abbrev-table '()) | |||
(define-abbrev-table 'help-mode-abbrev-table '()) | |||
(define-abbrev-table 'html-mode-abbrev-table '()) | |||
(define-abbrev-table 'ibuffer-mode-abbrev-table '()) | |||
(define-abbrev-table 'idl-mode-abbrev-table '()) | |||
(define-abbrev-table 'image-dired-display-image-mode-abbrev-table '()) | |||
(define-abbrev-table 'image-dired-thumbnail-mode-abbrev-table '()) | |||
(define-abbrev-table 'internal-ange-ftp-mode-abbrev-table '()) | |||
(define-abbrev-table 'ivy-occur-grep-mode-abbrev-table '()) | |||
(define-abbrev-table 'ivy-occur-mode-abbrev-table '()) | |||
(define-abbrev-table 'jade-debugger-frames-mode-abbrev-table '()) | |||
(define-abbrev-table 'jade-debugger-locals-mode-abbrev-table '()) | |||
(define-abbrev-table 'jade-inspector-mode-abbrev-table '()) | |||
(define-abbrev-table 'jade-repl-mode-abbrev-table '()) | |||
(define-abbrev-table 'java-mode-abbrev-table | |||
'( | |||
)) | |||
(define-abbrev-table 'js-jsx-mode-abbrev-table '()) | |||
(define-abbrev-table 'js-mode-abbrev-table '()) | |||
(define-abbrev-table 'js2-jsx-mode-abbrev-table '()) | |||
(define-abbrev-table 'js2-mode-abbrev-table '()) | |||
(define-abbrev-table 'ledger-check-mode-abbrev-table '()) | |||
(define-abbrev-table 'ledger-mode-abbrev-table '()) | |||
(define-abbrev-table 'ledger-reconcile-mode-abbrev-table '()) | |||
(define-abbrev-table 'ledger-report-mode-abbrev-table '()) | |||
(define-abbrev-table 'less-css-mode-abbrev-table '()) | |||
(define-abbrev-table 'lisp-mode-abbrev-table '()) | |||
(define-abbrev-table 'log-edit-mode-abbrev-table '()) | |||
(define-abbrev-table 'log4e-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-cherry-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-diff-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-log-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-log-select-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-merge-preview-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-popup-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-process-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-reflog-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-refs-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-repolist-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-revision-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-stash-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-stashes-mode-abbrev-table '()) | |||
(define-abbrev-table 'magit-status-mode-abbrev-table '()) | |||
(define-abbrev-table 'makefile-automake-mode-abbrev-table '()) | |||
(define-abbrev-table 'makefile-bsdmake-mode-abbrev-table '()) | |||
(define-abbrev-table 'makefile-gmake-mode-abbrev-table '()) | |||
(define-abbrev-table 'makefile-imake-mode-abbrev-table '()) | |||
(define-abbrev-table 'makefile-makepp-mode-abbrev-table '()) | |||
(define-abbrev-table 'makefile-mode-abbrev-table '()) | |||
(define-abbrev-table 'markdown-mode-abbrev-table '()) | |||
(define-abbrev-table 'message-mode-abbrev-table '()) | |||
(define-abbrev-table 'messages-buffer-mode-abbrev-table '()) | |||
(define-abbrev-table 'mu4e-about-mode-abbrev-table '()) | |||
(define-abbrev-table 'mu4e~update-mail-mode-abbrev-table '()) | |||
(define-abbrev-table 'nix-mode-abbrev-table '()) | |||
(define-abbrev-table 'notmuch-hello-mode-abbrev-table '()) | |||
(define-abbrev-table 'notmuch-message-mode-abbrev-table '()) | |||
(define-abbrev-table 'notmuch-search-mode-abbrev-table '()) | |||
(define-abbrev-table 'notmuch-show-mode-abbrev-table '()) | |||
(define-abbrev-table 'notmuch-tree-mode-abbrev-table '()) | |||
(define-abbrev-table 'nrepl-messages-mode-abbrev-table '()) | |||
(define-abbrev-table 'nxml-mode-abbrev-table '()) | |||
(define-abbrev-table 'objc-mode-abbrev-table | |||
'( | |||
)) | |||
(define-abbrev-table 'occur-edit-mode-abbrev-table '()) | |||
(define-abbrev-table 'occur-mode-abbrev-table '()) | |||
(define-abbrev-table 'org-export-stack-mode-abbrev-table '()) | |||
(define-abbrev-table 'org-mode-abbrev-table '()) | |||
(define-abbrev-table 'outline-mode-abbrev-table '()) | |||
(define-abbrev-table 'package-menu-mode-abbrev-table '()) | |||
(define-abbrev-table 'pass-mode-abbrev-table '()) | |||
(define-abbrev-table 'pass-view-mode-abbrev-table '()) | |||
(define-abbrev-table 'pike-mode-abbrev-table | |||
'( | |||
)) | |||
(define-abbrev-table 'process-menu-mode-abbrev-table '()) | |||
(define-abbrev-table 'prodigy-mode-abbrev-table '()) | |||
(define-abbrev-table 'prodigy-view-mode-abbrev-table '()) | |||
(define-abbrev-table 'prog-mode-abbrev-table '()) | |||
(define-abbrev-table 'quickurl-list-mode-abbrev-table '()) | |||
(define-abbrev-table 'reb-lisp-mode-abbrev-table '()) | |||
(define-abbrev-table 'reb-mode-abbrev-table '()) | |||
(define-abbrev-table 'restclient-mode-abbrev-table '()) | |||
(define-abbrev-table 'ruby-mode-abbrev-table '()) | |||
(define-abbrev-table 'scss-mode-abbrev-table '()) | |||
(define-abbrev-table 'select-tags-table-mode-abbrev-table '()) | |||
(define-abbrev-table 'sgml-mode-abbrev-table '()) | |||
(define-abbrev-table 'sh-mode-abbrev-table '()) | |||
(define-abbrev-table 'shell-mode-abbrev-table '()) | |||
(define-abbrev-table 'sldb-mode-abbrev-table '()) | |||
(define-abbrev-table 'slime-compiler-notes-mode-abbrev-table '()) | |||
(define-abbrev-table 'slime-connection-list-mode-abbrev-table '()) | |||
(define-abbrev-table 'slime-fuzzy-completions-mode-abbrev-table '()) | |||
(define-abbrev-table 'slime-inspector-mode-abbrev-table '()) | |||
(define-abbrev-table 'slime-thread-control-mode-abbrev-table '()) | |||
(define-abbrev-table 'slime-trace-dialog--detail-mode-abbrev-table '()) | |||
(define-abbrev-table 'slime-trace-dialog-mode-abbrev-table '()) | |||
(define-abbrev-table 'slime-xref-mode-abbrev-table '()) | |||
(define-abbrev-table 'smime-mode-abbrev-table '()) | |||
(define-abbrev-table 'snapshot-timeline-mode-abbrev-table '()) | |||
(define-abbrev-table 'snippet-mode-abbrev-table '()) | |||
(define-abbrev-table 'special-mode-abbrev-table '()) | |||
(define-abbrev-table 'speedbar-mode-abbrev-table '()) | |||
(define-abbrev-table 'tabulated-list-mode-abbrev-table '()) | |||
(define-abbrev-table 'term-mode-abbrev-table '()) | |||
(define-abbrev-table 'text-mode-abbrev-table '()) | |||
(define-abbrev-table 'url-cookie-mode-abbrev-table '()) | |||
(define-abbrev-table 'vc-annotate-mode-abbrev-table '()) | |||
(define-abbrev-table 'vc-dir-mode-abbrev-table '()) | |||
(define-abbrev-table 'vc-git-log-edit-mode-abbrev-table '()) | |||
(define-abbrev-table 'vc-git-log-view-mode-abbrev-table '()) | |||
(define-abbrev-table 'vc-git-region-history-mode-abbrev-table '()) | |||
(define-abbrev-table 'vc-svn-log-view-mode-abbrev-table '()) | |||
(define-abbrev-table 'web-mode-abbrev-table '()) | |||
(define-abbrev-table 'xref--xref-buffer-mode-abbrev-table '()) | |||
@ -0,0 +1,353 @@ | |||
;;;; Emacs Bookmark Format Version 1 ;;;; | |||
;;; 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 -*- | |||
((#("emacs.cafe" 0 10 | |||
(face ivy-virtual)) | |||
(filename . "~/work/emacs.cafe/") | |||
(front-context-string . "_config.yml\n dr") | |||
(rear-context-string . "3K Apr 21 22:26 ") | |||
(position . 274)) | |||
("contacts.org" | |||
(filename . "~/org/contacts.org") | |||
(front-context-string . "#+STARTUP: showe") | |||
(rear-context-string) | |||
(position . 1)) | |||
(#("stumpwm.d" 0 9 | |||
(face ivy-virtual)) | |||
(filename . "~/config/stumpwm.d/") | |||
(front-context-string . " /home/nico/con") | |||
(rear-context-string) | |||
(position . 1)) | |||
(#("ynh" 0 3 | |||
(face ivy-virtual)) | |||
(filename . "~/work/ynh/") | |||
(front-context-string . "drone_ynh\n drwx") | |||
(rear-context-string . "0K Nov 6 16:54 ") | |||
(position . 213)) | |||
(#("zerodark" 0 8 | |||
(face ivy-virtual)) | |||
(filename . "~/work/elisp/zerodark/") | |||
(front-context-string . "LICENSE\n -rw---") | |||
(rear-context-string . "4K Jun 29 11:49 ") | |||
(position . 226)) | |||
(#("indium" 0 6 | |||
(face ivy-virtual)) | |||
(filename . "~/work/elisp/indium/") | |||
(front-context-string . "jade.el\n -rw-r-") | |||
(rear-context-string . "8K May 26 12:00 ") | |||
(position . 283)) | |||
(#("lisp" 0 4 | |||
(face ivy-virtual)) | |||
(filename . "~/work/lisp/") | |||
(front-context-string . "land-of-lisp\n d") | |||
(rear-context-string . "0K Jan 6 2015 ") | |||
(position . 215)) | |||
(#("config" 0 6 | |||
(face ivy-virtual)) | |||
(filename . "~/config/") | |||
(front-context-string) | |||
(rear-context-string . "0K Apr 14 16:46 ") | |||
(position . 489)) | |||
(#("nixpkgs" 0 7 | |||
(face ivy-virtual)) | |||
(filename . "~/nixpkgs/") | |||
(front-context-string . "COPYING\n -rw-r-") | |||
(rear-context-string . "7K Apr 9 18:15 ") | |||
(position . 213)) | |||
(#("win8" 0 4 | |||
(face ivy-virtual)) | |||
(filename . "/smb:nicolas@ftgp-win8:/Users/Nicolas/") | |||
(front-context-string . "Desktop\n dr-xr-") | |||
(rear-context-string . " 0 Feb 12 13:32 ") | |||
(position . 349)) | |||
(#("labo109" 0 7 | |||
(face ivy-virtual)) | |||
(filename . "~/work/ruby/labo109/") | |||
(front-context-string . "app\n drwxr-xr-x") | |||
(rear-context-string . "0K Jul 14 17:22 ") | |||
(position . 222)) | |||
(#("objectjs" 0 8 | |||
(face ivy-virtual)) | |||
(filename . "~/work/javascript/objectjs/") | |||
(front-context-string) | |||
(rear-context-string . "0K Mar 1 13:38 ") | |||
(position . 708)) | |||
(#("projects" 0 8 | |||
(face ivy-virtual)) | |||
(filename . "~/org/projects/") | |||
(front-context-string . "client-side-impr") | |||
(rear-context-string . "18 Feb 7 00:06 ") | |||
(position . 293)) | |||
(#("couch-vm" 0 8 | |||
(face ivy-virtual)) | |||
(filename . "/scp:nico@192.168.124.179:/home/nico/") | |||
(front-context-string . "Desktop\n drwxr-") | |||
(rear-context-string . "0K Jan 23 22:48 ") | |||
(position . 193)) | |||
(#("magellan" 0 8 | |||
(face ivy-virtual)) | |||
(filename . "~/work/javascript/magellan/") | |||
(front-context-string . "css\n -rw-rw-r--") | |||
(rear-context-string . "0K Feb 22 06:35 ") | |||
(position . 230)) | |||
(#("javascript" 0 10 | |||
(face ivy-virtual)) | |||
(filename . "~/work/javascript/") | |||
(front-context-string . "aa\n drwx------.") | |||
(rear-context-string . "0K Jul 7 2015 ") | |||
(position . 221)) | |||
(#("build" 0 5 | |||
(face ivy-virtual)) | |||
(filename . "~/build/") | |||
(front-context-string . "ios-webkit-debug") | |||
(rear-context-string . "0K Jan 6 2015 ") | |||
(position . 567)) | |||
(#("conkerorrc" 0 10 | |||
(face ivy-virtual)) | |||
(filename . "~/.conkerorrc/") | |||
(front-context-string . "index.js\n drwxr") | |||
(rear-context-string . "13 Jan 16 15:19 ") | |||
(position . 214)) | |||
(#("Pictures" 0 8 | |||
(face ivy-virtual)) | |||
(filename . "~/Pictures/") | |||
(front-context-string . "2015\n -rw-rw-r-") | |||
(rear-context-string . "0K Dec 21 15:45 ") | |||
(position . 365)) | |||
(#("media" 0 5 | |||
(face ivy-virtual)) | |||
(filename . "/run/media/nico/") | |||
(front-context-string) | |||
(rear-context-string . "0K Jan 1 1970 ") | |||
(position . 206)) | |||
("ledger" | |||
(filename . "~/org/reference/ledger/ledger.dat") | |||
(front-context-string . ";; Local Variabl") | |||
(rear-context-string . "edish_checking\n\n") | |||
(position . 27198)) | |||
(#("emacs-website" 0 13 | |||
(face ivy-virtual)) | |||
(filename . "~/work/emacs-website/") | |||
(front-context-string . "design\n drwxrwx") | |||
(rear-context-string . "0K Dec 3 01:22 ") | |||
(position . 223)) | |||
(#("stream" 0 6 | |||
(face ivy-virtual)) | |||
(filename . "~/work/elisp/stream/") | |||
(front-context-string . "Cask\n -rw------") | |||
(rear-context-string . "06 Oct 14 13:06 ") | |||
(position . 222)) | |||
(#("elpa" 0 4 | |||
(face ivy-virtual)) | |||
(filename . "~/work/elisp/elpa/") | |||
(front-context-string . "admin\n -rw-----") | |||
(rear-context-string . "0K Oct 22 18:21 ") | |||
(position . 224)) | |||
(#("fpod-teamcity" 0 13 | |||
(face ivy-virtual)) | |||
(filename . "/scp:fpod-teamcity:/home/ftgp/") | |||
(front-context-string . "tmp\n drwxrwxrwx") | |||
(rear-context-string . "0K Jun 17 10:03 ") | |||
(position . 186)) | |||
("org-capture-last-stored-marker" | |||
(filename . "~/org/gtd.org") | |||
(front-context-string . "** WAITING Nouve") | |||
(rear-context-string . "7-28 Thu 20:00>\n") | |||
(position . 26694)) | |||
(#("sudo petton.fr" 0 14 | |||
(face ivy-virtual)) | |||
(filename . | |||
#("/sudo:root@petton.fr:/home/nico/" 6 10 | |||
(tramp-default t))) | |||
(front-context-string) | |||
(rear-context-string . "0K Jun 14 07:18 ") | |||
(position . 347)) | |||
(#("emacs" 0 5 | |||
(face ivy-virtual)) | |||
(filename . "~/work/emacs/") | |||
(front-context-string . "aclocal.m4\n drw") | |||
(rear-context-string . "4K May 16 12:50 ") | |||
(position . 217)) | |||
(#("infrastructure" 0 14 | |||
(face ivy-virtual)) | |||
(filename . "~/work/ftgp/infrastructure/") | |||
(front-context-string . "azure-office-inv") | |||
(rear-context-string . "73 May 16 10:03 ") | |||
(position . 402)) | |||
(#("Downloads" 0 9 | |||
(face ivy-virtual)) | |||
(filename . "~/Downloads/") | |||
(front-context-string . " /home/nico/Dow") | |||
(rear-context-string) | |||
(position . 1)) | |||
(#("reference" 0 9 | |||
(face ivy-virtual)) | |||
(filename . "~/org/reference/") | |||
(front-context-string) | |||
(rear-context-string . "0K Dec 13 14:30 ") | |||
(position . 219)) | |||
(#("petton.fr" 0 9 | |||
(face ivy-virtual)) | |||
(filename . "/scp:petton.fr:/") | |||
(front-context-string . "etc\n drwxr-xr-x") | |||
(rear-context-string . "0K Oct 19 09:56 ") | |||
(position . 321)) | |||
(#("raspberry" 0 9 | |||
(face ivy-virtual)) | |||
(filename . "/scp:pi@raspberry.local:/home/pi/") | |||
(front-context-string . " drwxr-xr-x 2 ") | |||
(rear-context-string . "Jan 1 1970 ..\n") | |||
(position . 140) | |||
(annotation . "")) | |||
(#("backitup" 0 8 | |||
(face ivy-virtual)) | |||
(filename . "~/work/elisp/backitup/") | |||
(front-context-string . "todo.org\n -rw-r") | |||
(rear-context-string . "5K Sep 7 15:31 ") | |||
(position . 876)) | |||
(#("js2-refactor.el" 0 15 | |||
(face ivy-virtual)) | |||
(filename . "~/work/elisp/js2-refactor.el/") | |||
(front-context-string . "Cask\n drwxr-xr-") | |||
(rear-context-string . "23 Aug 28 09:31 ") | |||
(position . 233)) | |||
(#("clojure" 0 7 | |||
(face ivy-virtual)) | |||
(filename . "~/work/clojure/") | |||
(front-context-string) | |||
(rear-context-string . "0K Jun 20 20:10 ") | |||
(position . 218)) | |||
(#("yomaco" 0 6 | |||
(face ivy-virtual)) | |||
(filename . "~/work/ftgp/yomaco/") | |||
(front-context-string . "apps\n -rw-rw-r-") | |||
(rear-context-string . "0K May 28 15:45 ") | |||
(position . 622)) | |||
(#("monitor" 0 7 | |||
(face ivy-virtual)) | |||
(filename . "~/work/ftgp/monitor/monitor/Monitor.Web.Ui/Client/") | |||
(front-context-string . "- 1 nico nico ") | |||
(rear-context-string . "ules\n -rw-r--r-") | |||
(position . 780)) | |||
(#("emacs.d" 0 7 | |||
(face ivy-virtual)) | |||
(filename . "~/config/emacs.d/") | |||
(front-context-string . "ac-comphist.dat\n") | |||
(rear-context-string . "3K Apr 22 21:26 ") | |||
(position . 217)) | |||
(#("ebooks" 0 6 | |||
(face ivy-virtual)) | |||
(filename . "~/ebooks/") | |||
(front-context-string . ", David\n drwxr-") | |||
(rear-context-string . "p 2 2013 Allen") | |||
(position . 331)) | |||
(#("emacs-backup-files" 0 18 | |||
(face ivy-virtual)) | |||
(filename . "~/.tmp/") | |||
(front-context-string . "..\n -rw-r--r-- ") | |||
(rear-context-string . "4K Mar 23 18:19 ") | |||
(position . 162)) | |||
(#("elisp" 0 5 | |||
(face ivy-virtual)) | |||
(filename . "~/work/elisp/") | |||
(front-context-string . "discover-js2-ref") | |||
(rear-context-string . "0K Feb 4 13:02 ") | |||
(position . 212)) | |||
(#("priv" 0 4 | |||
(face ivy-virtual)) | |||
(filename . "~/.priv/") | |||
(front-context-string . "elisp\n -rw-r--r") | |||
(rear-context-string . "0K Jan 21 14:35 ") | |||
(position . 210)) | |||
(#("nicolas-petton.fr" 0 17 | |||
(face ivy-virtual)) | |||
(filename . "~/work/nicolas-petton.fr/") | |||
(front-context-string . "blog\n -rw-r--r-") | |||
(rear-context-string . "0K Oct 16 17:47 ") | |||
(position . 277)) | |||
(#("public" 0 6 | |||
(face ivy-virtual)) | |||
(filename . "~/Public/") | |||
(front-context-string . "client\n drwxr-x") | |||
(rear-context-string . "0K Sep 2 21:12 ") | |||
(position . 210)) | |||
(#("snippets" 0 8 | |||
(face ivy-virtual)) | |||
(filename . "~/.emacs.d/snippets/") | |||
(front-context-string . "css-mode\n drwxr") | |||
(rear-context-string . "6B Jul 16 02:20 ") | |||
(position . 235)) | |||
(#("widgetjs" 0 8 | |||
(face ivy-virtual)) | |||
(filename . "~/work/ftgp/widget-js/") | |||
(front-context-string . "Gruntfile.js\n -") | |||
(rear-context-string . "0K Jun 12 15:34 ") | |||
(position . 235)) | |||
("keychain" | |||
(filename . "~/.priv/keychain.org.gpg") | |||
(front-context-string . "* Websites\n|----") | |||
(rear-context-string) | |||
(position . 1)) | |||
(#("Documents" 0 9 | |||
(face ivy-virtual)) | |||
(filename . "~/Documents/") | |||
(front-context-string . "createyourprogla") | |||
(rear-context-string . "0K Dec 12 17:39 ") | |||
(position . 210)) | |||
(#("Desktop" 0 7 | |||
(face ivy-virtual)) | |||
(filename . "~/Desktop/") | |||
(front-context-string . "barth-weinberger") | |||
(rear-context-string . "3K Oct 26 17:01 ") | |||
(position . 209)) | |||
("org-refile-last-stored" | |||
(filename . "~/org/gtd.org") | |||
(front-context-string . "** DONE deco de ") | |||
(rear-context-string . "2016-12-07 Wed>\n") | |||
(position . 57486)) | |||
(#("org" 0 3 | |||
(face ivy-virtual)) | |||
(filename . "~/org/") | |||
(front-context-string . "amber.org\n -rw-") | |||
(rear-context-string . "15 Dec 7 14:02 ") | |||
(position . 205)) | |||
(#("ftgp" 0 4 | |||
(face ivy-virtual)) | |||
(filename . "~/work/ftgp/") | |||
(front-context-string . "monitor\n drwxr-") | |||
(rear-context-string . "0K Apr 28 17:15 ") | |||
(position . 375)) | |||
("org-capture-last-stored" | |||
(filename . "~/org/inbox.org") | |||
(front-context-string . "** TODO use epkg") | |||
(rear-context-string . "our demain soir\n") | |||
(position . 179)) | |||
(#("work" 0 4 | |||
(face ivy-virtual)) | |||
(filename . "~/work/") | |||
(front-context-string . "Appify-UI\n drwx") | |||
(rear-context-string . "0K Apr 19 17:04 ") | |||
(position . 207)) | |||
(#("FTP alpha.GNU.org" 0 17 | |||
(face ivy-virtual)) | |||
(filename . | |||
#("/ftp:anonymous@alpha.gnu.org:/" 0 30 | |||
(face ivy-virtual))) | |||
(front-context-string . "gnu\n lrwxrwxrwx") | |||
(rear-context-string . "96 Jan 29 09:55 ") | |||
(position . 453)) | |||
(#("FTP GNU.org" 0 11 | |||
(face ivy-virtual)) | |||
(filename . | |||
#("/ftp:anonymous@ftp.gnu.org:/" 0 28 | |||
(face ivy-virtual))) | |||
(front-context-string . "gnu+linux-distro") | |||
(rear-context-string . "96 Mar 10 2011 ") | |||
(position . 732)) | |||
("org-capture-last-stored-marker<2><2>" | |||
(filename . "~/org/home.org") | |||
(front-context-string . "*** TODO amener ") | |||
(rear-context-string . "2-26 Thu 10:25]\n") | |||
(position . 1203)) | |||
) |
@ -0,0 +1,4 @@ | |||
(when (window-system) | |||
(set-face-attribute 'default nil :height 115 :family "Fira Mono")) | |||
(provide 'init-blueberry-appearance) |
@ -0,0 +1,6 @@ | |||
(let ((packages-to-load '(notmuch alert org-gnome))) | |||
(dolist (package packages-to-load) | |||
(when (not (package-installed-p package)) | |||
(package-install package)))) | |||
(provide 'init-blueberry-package) |
@ -0,0 +1,10 @@ | |||
(require 'init-notmuch) | |||
(require 'init-org) | |||
(require 'init-org-publish) | |||
(require 'init-latex) | |||
(require 'init-prodigy) | |||
(require 'init-ledger) | |||
(require 'init-blueberry-appearance) | |||
(require 'init-epg) | |||
(provide 'init-blueberry) |
@ -0,0 +1,7 @@ | |||
(require 'epg) | |||
(require 'magit) | |||
(setq epg-gpg-program "gpg2") | |||
(setq magit-commit-arguments (quote ("--gpg-sign=233587A47C207910"))) | |||
(provide 'init-epg) |
@ -0,0 +1,28 @@ | |||
(require 'reftex) | |||
;; (require 'auctex-evince-sync) | |||
(add-hook 'LaTeX-mode-hook 'tex-pdf-mode) | |||
(eval-after-load "LaTeX" | |||
'(progn | |||
;; synctex | |||
(TeX-source-correlate-mode) | |||
(add-to-list 'TeX-expand-list | |||
'("%q" skim-make-url)))) | |||
(defun skim-make-url () (concat | |||
(TeX-current-line) | |||
" " | |||
(expand-file-name (funcall file (TeX-output-extension) t) | |||
(file-name-directory (TeX-master-file))) | |||
" " | |||
(buffer-file-name))) | |||
(setq TeX-view-program-list | |||
'(("evince" "evince %o"))) | |||
(setq TeX-view-program-selection '((output-pdf "evince"))) | |||
(provide 'init-latex) |
@ -0,0 +1,43 @@ | |||
(require 'ledger-mode) | |||
(require 'company) | |||
(require 'map) | |||
(add-hook 'ledger-mode-hook #'company-mode) | |||
(defvar nico-ledger-imports nil) | |||
(defun nico-ledger-autosync () | |||
(interactive) | |||
(switch-to-buffer (get-buffer-create "*ledger sync*")) | |||
(erase-buffer) | |||
(ledger-mode) | |||
(shell-command "ledger-autosync -l ~/org/reference/ledger/ledger.dat ~/Downloads/\\ telechargement.ofx -a Assets:Checking:CE --fid 10" (current-buffer))) | |||
(defun nico-ledger-convert-transaction () | |||
(interactive) | |||
(save-excursion | |||
(back-to-indentation) | |||
(let* ((match (map-some (lambda (k v) | |||
(when (search-forward k (line-end-position) t) | |||
k)) | |||
nico-ledger-imports)) | |||
(replacement (if match | |||
(map-elt nico-ledger-imports match) | |||
(read-string "Import as: " "Expenses:Misc")))) | |||
(search-forward "Expenses:Misc") | |||
(delete-backward-char 13) | |||
(insert replacement) | |||
(ledger-post-align-xact (point))) | |||
(goto-char (point-min)) | |||
(while (re-search-forward "\\bEUR\\b" nil t) | |||
(replace-match "€" nil t))) | |||
(ledger-navigate-next-xact-or-directive)) | |||
(defun nico-ledger-convert-all-transactions () | |||
(interactive) | |||
(while (not (eobp)) | |||
(nico-ledger-convert-transaction))) | |||
(define-key ledger-mode-map (kbd "C-c M-i") #'nico-ledger-convert-transaction) | |||
(provide 'init-ledger) |
@ -0,0 +1,139 @@ | |||
(require 'mu4e) | |||
(require 'alert) | |||
(require 'smtpmail) | |||
(require 'org-mu4e) | |||
(require 'gnus-dired) | |||
(define-key global-map (kbd "M-N") 'mu4e) | |||
(setq mu4e-attachment-dir "~/Download") | |||
;; don't keep message buffers around | |||
(setq message-kill-buffer-on-exit t) | |||
;; attempt to show images when viewing messages | |||
(setq mu4e-view-show-images t | |||
mu4e-view-image-max-width 800) | |||
;; use imagemagick, if available | |||
(when (fboundp 'imagemagick-register-types) | |||
(imagemagick-register-types)) | |||
(setq mu4e-sent-messages-behavior 'sent) | |||
(setq mu4e-msg2pdf "/usr/bin/msg2pdf" | |||
mu4e-get-mail-command "offlineimap" | |||
mu4e-html2text-command "w3m -T text/html" | |||
mu4e-update-interval 600) | |||
(defun nico/notify-new-email () | |||
(alert | |||
"You have unread emails" | |||
:title "New mail!" | |||
:icon "/usr/share/icons/gnome/32x32/status/mail-unread.png")) | |||
(add-hook 'mu4e-index-updated-hook #'nico/notify-new-email) | |||
(setq message-send-mail-function 'smtpmail-send-it | |||
user-full-name "Nicolas Petton" | |||
mu4e-compose-signature "Nicolas Petton | |||
http://nicolas-petton.fr" | |||
mu4e-compose-signature-auto-include t | |||
starttls-use-gnutls t) | |||
(defvar nico/mu4e-account-alist | |||
'(("nicolas@petton.fr" | |||
(user-mail-address "nicolas@petton.fr") | |||
(smtpmail-starttls-credentials '(("mail.messagingengine.com" 465 nil nil))) | |||
(smtpmail-auth-credentials | |||
'(("smtp.gmail.com" 587 "mail.messagingengine.com" nil))) | |||
(smtpmail-default-smtp-server "mail.messagingengine.com") | |||
(smtpmail-smtp-server "mail.messagingengine.com") | |||
(smtpmail-smtp-service 587)) | |||
;; ("FTGP" | |||
;; (user-mail-address "nicolas.petton@foretagsplatsen.se") | |||
;; (smtpmail-starttls-credentials '(("smtp.gmail.com" 587 nil nil))) | |||
;; (smtpmail-auth-credentials | |||
;; '(("smtp.gmail.com" 587 "nicolas.petton@foretagsplatsen.se" nil))) | |||
;; (smtpmail-default-smtp-server "smtp.gmail.com") | |||
;; (smtpmail-smtp-server "smtp.gmail.com") | |||
;; (smtpmail-smtp-service 587)) | |||
)) | |||
(defun nico/mu4e-set-account () | |||
"Set the account for composing a message. | |||
Try to match the current maildir or ask for the account name" | |||
(interactive) | |||
(let* ((account | |||
(nico/select-mail-account))) | |||
(nico/setup-mail-account account))) | |||
(defun nico/select-mail-account () | |||
(interactive) | |||
(completing-read (format "Compose with account: (%s) " | |||
(mapconcat #'(lambda (var) (car var)) nico/mu4e-account-alist "/")) | |||
(mapcar #'(lambda (var) (car var)) nico/mu4e-account-alist) | |||
nil t nil nil (caar nico/mu4e-account-alist))) | |||
(defun nico/setup-mail-account (account) | |||
(let ((account-vars (cdr (assoc account nico/mu4e-account-alist)))) | |||
(mapc #'(lambda (var) | |||
(set (car var) (cadr var))) | |||
account-vars))) | |||
(nico/setup-mail-account "nicolas@petton.fr") | |||
(add-hook 'mu4e-compose-pre-hook #'nico/mu4e-set-account) | |||
(add-hook 'mu4e-compose-mode-hook #'mml-secure-message-sign) | |||
(add-to-list 'mu4e-view-actions | |||
'("View in browser" . mu4e-action-view-in-browser) t) | |||
;; Attach files with dired | |||
;; make the `gnus-dired-mail-buffers' function also work on | |||
;; message-mode derived modes, such as mu4e-compose-mode | |||
(defun gnus-dired-mail-buffers () | |||
"Return a list of active message buffers." | |||
(let (buffers) | |||
(save-current-buffer | |||
(dolist (buffer (buffer-list t)) | |||
(set-buffer buffer) | |||
(when (and (derived-mode-p 'message-mode) | |||
(null message-sent-message-via)) | |||
(push (buffer-name buffer) buffers)))) | |||
(nreverse buffers))) | |||
(setq gnus-dired-mail-mode 'mu4e-user-agent) | |||
(add-hook 'dired-mode-hook 'turn-on-gnus-dired-mode) | |||
;; epa | |||
(add-hook 'mu4e-view-mode-hook #'epa-mail-mode) | |||
(add-hook 'mu4e-compose-mode-hook #'epa-mail-mode) | |||
;; Display embedded diffs nicely | |||
(defun mu2diff () | |||
(interactive) | |||
(let ((buf "*Diff message view*") | |||
(message-contents (buffer-string))) | |||
(switch-to-buffer buf) | |||
(read-only-mode 0) | |||
(erase-buffer) | |||
(insert message-contents) | |||
(goto-char (point-min)) | |||
(mu2diff--skip-message-headers) | |||
(read-only-mode 1) | |||
(diff-mode))) | |||
(defun mu2diff--skip-message-headers () | |||
(let ((message-header-regex "^[\\\s+\\\t+]+\\|^[A-Za-z0-9-]+:\\\s")) | |||
(save-excursion | |||
(goto-char (point-min)) | |||
(while (looking-at message-header-regex) | |||
(forward-line)) | |||
(delete-region (point-min) (point))))) | |||
(define-key mu4e-view-mode-map (kbd "C-c d") #'mu2diff) | |||
(provide 'init-mu4e) |
@ -0,0 +1,261 @@ | |||
(add-to-list 'load-path (expand-file-name "lib/notmuch/emacs" user-emacs-directory)) | |||
(require 'notmuch) | |||
(require 'seq) | |||
(require 'org-notmuch) | |||
(require 'fetch-email) | |||
(require 'alert) | |||
(require 'yasnippet) | |||
;; For existing org links, load mu4e anyway | |||
;; use notmuch for sending emails | |||
(global-set-key (kbd "C-x m") #'notmuch-mua-new-mail) | |||
;; don't keep message buffers around | |||
(setq message-kill-buffer-on-exit t) | |||
;; Attach files from dired | |||
(add-hook 'dired-mode-hook 'turn-on-gnus-dired-mode) | |||
;; use imagemagick, if available | |||
(when (fboundp 'imagemagick-register-types) | |||
(imagemagick-register-types)) | |||
(defvar nico-pgp-sign-excluded-emails '("monitor\.issues@gmail\.com")) | |||
;; Sign messages by default | |||
(add-hook 'message-setup-hook #'nico-maybe-sign-email) | |||
(add-hook 'message-setup-hook #'yas-minor-mode-on) | |||
(defun nico-maybe-sign-email () | |||
"Sign the current buffer's email unless the message is sent to | |||
one of `nico-pgp-sign-excluded-emails'." | |||
(let ((email (message-fetch-field "to"))) | |||
(unless (and email | |||
(seq-some (lambda (regex) | |||
(string-match regex email)) | |||
nico-pgp-sign-excluded-emails)) | |||
(mml-secure-sign-pgpmime)))) | |||
(define-key global-map (kbd "M-N") #'notmuch) | |||
(add-to-list 'fetch-email-post-command-hook #'nico-notmuch-update) | |||
(define-key notmuch-hello-mode-map (kbd "C-c C-c") #'fetch-email) | |||
(define-key notmuch-hello-mode-map "g" #'notmuch-refresh-this-buffer) | |||
(define-key notmuch-search-mode-map "g" #'notmuch-refresh-this-buffer) | |||
(define-key notmuch-search-mode-map "d" #'nico-notmuch-search-tag-read) | |||
(define-key notmuch-search-mode-map "D" #'nico-notmuch-search-tag-all-read) | |||
(define-key notmuch-search-mode-map "u" #'nico-notmuch-search-tag-unread) | |||
(define-key notmuch-show-mode-map "d" #'nico-notmuch-show-tag-read) | |||
(define-key notmuch-show-mode-map "D" #'nico-notmuch-show-tag-all-read) | |||
(define-key notmuch-show-mode-map "u" #'nico-notmuch-show-tag-unread) | |||
(defun nico-notmuch-update (&rest args) | |||
(interactive) | |||
(notmuch-poll-and-refresh-this-buffer)) | |||
(defun nico-notmuch-address-selection-function (prompt collection initial-input) | |||
"Call (`completing-read' | |||
PROMPT COLLECTION nil nil INITIAL-INPUT 'notmuch-address-history)" | |||
(ido-completing-read | |||
prompt (cons initial-input collection) nil nil initial-input 'notmuch-address-history)) | |||
(defun nico-notmuch-search-tag (tags) | |||
(notmuch-search-tag tags) | |||
(forward-line 1)) | |||
(defun nico-notmuch-search-tag-read () | |||
(interactive) | |||
(nico-notmuch-search-tag '("-unread"))) | |||
(defun nico-notmuch-search-tag-all-read () | |||
(interactive) | |||
(if (y-or-n-p "Mark all threads as read? ") | |||
(progn | |||
(notmuch-search-tag-all '("-unread"))))) | |||
(defun nico-notmuch-search-tag-unread () | |||
(interactive) | |||
(nico-notmuch-search-tag '("+unread"))) | |||
(defun nico-notmuch-show-tag-read () | |||
(interactive) | |||
(notmuch-show-tag '("-unread"))) | |||
(defun nico-notmuch-show-tag-all-read () | |||
(interactive) | |||
(if (y-or-n-p "Mark all threads as read? ") | |||
(progn | |||
(notmuch-show-tag-all '("-unread"))))) | |||
(defun nico-notmuch-show-tag-unread () | |||
(interactive) | |||
(notmuch-show-tag '("+unread"))) | |||
(setq message-send-mail-function #'message-send-mail-with-sendmail | |||
sendmail-program "msmtpq" | |||
user-full-name "Nicolas Petton" | |||
starttls-use-gnutls t) | |||
(defvar nico-notmuch-account-alist | |||
'(("nicolas@petton.fr" | |||
(user-mail-address "nicolas@petton.fr")) | |||
("nicolas@foretagsplatsen.se" | |||
(user-mail-address "nicolas@foretagsplatsen.se")))) | |||
(defun nico-setup-mail-account (account) | |||
(let ((account-vars (cdr (assoc account nico-notmuch-account-alist)))) | |||
(mapc #'(lambda (var) | |||
(set (car var) (cadr var))) | |||
account-vars))) | |||
(defun nico-select-mail-account () | |||
(completing-read (format "Compose with account: (%s) " | |||
(mapconcat #'(lambda (var) (car var)) nico-notmuch-account-alist "/")) | |||
(mapcar #'(lambda (var) (car var)) nico-notmuch-account-alist) | |||
nil t nil nil (caar nico-notmuch-account-alist))) | |||
(add-hook 'message-setup-hook #'nico-set-email-account-and-setup-message) | |||
(defun nico-set-email-account () | |||
"Set the account for composing a message." | |||
(interactive) | |||
(let* ((account | |||
(nico-select-mail-account))) | |||
(nico-setup-mail-account account))) | |||
(defun nico-set-email-account-and-setup-message () | |||
(nico-set-email-account) | |||
(message-goto-from) | |||
(message-beginning-of-line) | |||
(delete-region (point) (point-at-eol)) | |||
(insert (format "%s <%s>" user-full-name user-mail-address))) | |||
(nico-setup-mail-account "nicolas@petton.fr") | |||
(setq smtpmail-debug-info t) | |||
;; notifications | |||
(defvar nico-notmuch-refresh-count 0) | |||
(defun nico-notmuch-refresh-status-message () | |||
(let* ((new-count | |||
(string-to-number | |||
(car (process-lines notmuch-command "count")))) | |||
(diff-count (- new-count nico-notmuch-refresh-count))) | |||
(if (and (not (zerop nico-notmuch-refresh-count)) | |||
(> diff-count 0)) | |||
(alert (format "You have %s messages." | |||
(notmuch-hello-nice-number diff-count)) | |||
:title "New messages" | |||
:icon "/usr/share/icons/gnome/32x32/status/mail-unread.png")) | |||
(setq nico-notmuch-refresh-count new-count))) | |||
;; (add-hook 'notmuch-hello-refresh-hook #'nico-notmuch-refresh-status-message) | |||
;; opening attachments within emacs & xwidgets | |||
(define-key notmuch-show-part-map "e" #'nico-notmuch-view-part-in-emacs) | |||
(define-key notmuch-show-part-map "w" #'nico-notmuch-view-part-in-webkit) | |||
(define-key notmuch-show-part-map "p" #'nico-notmuch-apply-git-patch) | |||
(define-key notmuch-show-part-map "a" #'nico-notmuch-git-am-patch) | |||
(defun nico-notmuch-view-part-in-emacs () | |||
"View the MIME part containing point from within Emacs." | |||
(interactive) | |||
(notmuch-show-apply-to-current-part-handle #'nico-view-part-in-emacs)) | |||
(defun nico-notmuch-view-part-in-webkit () | |||
"View the MIME part containing point from within an xwidget webkit buffer." | |||
(interactive) | |||
(notmuch-show-apply-to-current-part-handle #'nico-view-part-in-webkit)) | |||
(defun nico-notmuch-apply-git-patch () | |||
"Apply the MIME part at point as a git patch using `git patch'." | |||
(interactive) | |||
(notmuch-show-apply-to-current-part-handle #'nico-notmuch-apply-git-patch-part)) | |||
(defun nico-notmuch-git-am-patch () | |||
"Apply the MIME part at point as a git patch using `git am'." | |||
(interactive) | |||
(notmuch-show-apply-to-current-part-handle #'nico-notmuch-git-am-part)) | |||
(defun nico-view-part-in-emacs (handle) | |||
(interactive) | |||
(let* ((dir (make-temp-dir)) | |||
(filename (or (mail-content-type-get | |||
(mm-handle-disposition handle) 'filename) | |||
(mail-content-type-get | |||
(mm-handle-type handle) 'name) | |||
"<file>")) | |||
(contents (mm-get-part handle)) | |||
(file (expand-file-name filename dir)) | |||
(buf (find-file-noselect file))) | |||
(with-current-buffer buf | |||
(insert contents) | |||
(save-buffer)) | |||
(kill-buffer buf) | |||
(pop-to-buffer (find-file-noselect file)))) | |||
(defun nico-view-part-in-webkit (handle) | |||
(interactive) | |||
(let* ((dir (make-temp-dir)) | |||
(filename (or (mail-content-type-get | |||
(mm-handle-disposition handle) 'filename) | |||
(mail-content-type-get | |||
(mm-handle-type handle) 'name) | |||
"<file>")) | |||
(contents (mm-get-part handle)) | |||
(file (expand-file-name filename dir)) | |||
(encoding 'raw-text) | |||
(buf (find-file-noselect file))) | |||
(with-current-buffer buf | |||
(insert contents) | |||
(set-buffer-file-coding-system encoding) | |||
(save-buffer)) | |||
(kill-buffer buf) | |||
(xwidget-webkit-browse-url (format "file://%s" file)))) | |||
(defun nico-notmuch-apply-git-patch-part (handle) | |||
(let ((dir (read-directory-name "Git directory: "))) | |||
(mm-pipe-part handle (format "cd %s; git apply" (expand-file-name dir))))) | |||
(defun nico-notmuch-git-am-part (handle) | |||
(let ((dir (read-directory-name "Git directory: "))) | |||
(mm-pipe-part handle (format "cd %s; git am" (expand-file-name dir))))) | |||
(defun make-temp-dir () | |||
(let* ((dirname (make-temp-name temporary-file-directory)) | |||
(absolute-name (expand-file-name dirname temporary-file-directory))) | |||
(make-directory absolute-name) | |||
absolute-name)) | |||
;; Function to return first name of email recipient | |||
;; Used by yasnippet | |||
;; Based closely on | |||
;; http://blog.binchen.org/posts/how-to-use-yasnippets-to-produce-email-templates-in-emacs.html | |||
(defun nico-yas-get-first-name-from-to-field () | |||
(let ((rlt "NAME") str rlt2) | |||
(save-excursion | |||
(goto-char (point-min)) | |||
;; first line in email could be some hidden line containing NO to field | |||
(setq str (buffer-substring-no-properties (point-min) (point-max)))) | |||
;; take name from TO field | |||
(when (string-match "^To: \"?\\([^ ,]+\\)" str) | |||
(setq rlt (match-string 1 str))) | |||
;;get name in FROM field if available | |||
(when (string-match "^\\([^ ,\n]+\\).+writes:$" str) | |||
(progn (setq rlt2 (match-string 1 str)) | |||
;;prefer name in FROM field if TO field has "@" | |||
(when (string-match "@" rlt) | |||
(setq rlt rlt2)) | |||
)) | |||
(message "rlt=%s" rlt) | |||
rlt)) | |||
(provide 'init-notmuch) | |||
;;; init-notmuch ends here |
@ -0,0 +1,120 @@ | |||
(require 'org) | |||
(require 'ox) | |||
(require 'ox-rss) | |||
(defvar nico-website-html-head | |||
"<link href='/images/favicon.ico' rel='shortcut icon' type='image/x-icon'> | |||
<link rel='stylesheet' href='css/site.css?v=2' type='text/css'/> | |||
<meta name='viewport' content='width=device-width, initial-scale=1'> | |||
<script src='/js/Hyphenator.js' type='text/javascript'></script> | |||
<script src='/js/jquery.js' type='text/javascript'></script> | |||
<link href='http://netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css' rel='stylesheet'>") | |||
(defvar nico-analytics-html | |||
"<script> | |||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ | |||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), | |||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) | |||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga'); | |||
ga('create', 'UA-2614862-2', 'nicolas-petton.fr'); | |||
ga('send', 'pageview'); | |||
</script>") | |||
(defvar nico-website-html-blog-head | |||
"<link href='/images/favicon.ico' rel='shortcut icon' type='image/x-icon'> | |||
<link rel='stylesheet' href='../css/site.css?v=2' type='text/css'/> | |||
<link rel='stylesheet' href='../css/blog.css?v=2' type='text/css'/> | |||
<meta name='viewport' content='width=device-width, initial-scale=1'> | |||
<script src='/js/Hyphenator.js' type='text/javascript'></script> | |||
<script src='/js/jquery.js' type='text/javascript'></script> | |||
<link href='http://netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css' rel='stylesheet'>") | |||
(defvar nico-website-html-preamble | |||
"<div class='intro'> | |||
<h1><b>Nicolas</b> Petton</h1> | |||
<p>Web developer, Lisper, Smalltalker & Emacs maniac.</p> | |||
</div> | |||
<div class='nav'> | |||
<ul> | |||
<li><a href='/'>Home</a>/</li> | |||
<li><a href='/blog/index.html'>Blog</a>/</li> | |||
<li><a href='https://emacs.cafe'>Emacs Café</a>/</li> | |||
<li><a href='https://petton.fr/git/nico'>Git repositories</a>/</li> | |||
<li><a href='http://github.com/NicolasPetton'>GitHub</a>/</li> | |||
<li><a href='http://twitter.com/NicolasPetton'>Twitter</a>/</li> | |||
<li><a href='/contact.html'>Contact</a></li> | |||
</ul> | |||
</div> | |||
") | |||
(defvar nico-website-html-postamble | |||
(concat | |||
"<script type='text/javascript'> | |||
$('p').addClass('hyphenate'); | |||
Hyphenator.run(); | |||
</script>" | |||
"<div class='footer'> | |||
Copyright " | |||
(format-time-string "%Y") | |||
" %a.<br> | |||
Last updated %C. <br> | |||
Built with %c. | |||
</div>")) | |||
(defun nico-html-head () | |||
(concat nico-website-html-head nico-analytics-html)) | |||
(defun nico-blog-html-head () | |||
(concat nico-website-html-blog-head nico-analytics-html)) | |||
(setq org-publish-project-alist | |||
`(("org" | |||
:base-directory "~/work/nicolas-petton.fr/" | |||
:base-extension "org" | |||
:publishing-directory "~/Public/nicolas-petton.fr/" | |||
:publishing-function org-html-publish-to-html | |||
:section-numbers nil | |||
:with-toc nil | |||
:html-head ,(nico-html-head) | |||
:html-preamble ,nico-website-html-preamble | |||
:html-postamble ,nico-website-html-postamble) | |||
("blog" | |||
:base-directory "~/work/nicolas-petton.fr/blog" | |||
:base-extension "org" | |||
:publishing-directory "~/Public/nicolas-petton.fr/blog/" | |||
:publishing-function org-html-publish-to-html | |||
:section-numbers nil | |||
:with-toc nil | |||
:html-head ,(nico-blog-html-head) | |||
:html-head-extra | |||
"<link rel=\"alternate\" type=\"application/rss+xml\" | |||
href=\"http://nicolas-petton.fr/blog/index.xml\" | |||
title=\"RSS feed\">" | |||
:html-preamble ,nico-website-html-preamble | |||
:html-postamble ,nico-website-html-postamble) | |||
("ressources" | |||
:base-directory "~/work/nicolas-petton.fr/" | |||
:base-extension "jpg\\|jpeg\\|gif\\|png\\|js\\|html\\|css\\|ogv\\|ogg\\|mp4\\|ico\\|asc" | |||
:recursive t | |||
:publishing-directory "~/Public/nicolas-petton.fr/" | |||
:publishing-function org-publish-attachment) | |||
("rss" | |||
:base-directory "~/work/nicolas-petton.fr/blog/" | |||
:base-extension "org" | |||
:publishing-directory "~/Public/nicolas-petton.fr/blog/" | |||
:publishing-function (org-rss-publish-to-rss) | |||
:section-numbers nil | |||
:table-of-contents nil | |||
:html-link-home "http://nicolas-petton.fr/blog/" | |||
:rss-image-url "http://nicolas-petton.fr/images/nicolas-petton.png" | |||
:html-link-use-abs-url t) | |||
("website" :components ("org" "blog" "rss" "ressource")))) | |||
(provide 'init-org-publish) |
@ -0,0 +1,197 @@ | |||
(require 'org) | |||
(require 'org-element) | |||
(require 'org-pomodoro) | |||
(require 'org-contacts) | |||
(require 'org-jira-protocol) | |||
(require 'org-gogs-protocol) | |||
(require 'org-sip-protocol) | |||
(require 'org-debbugs-protocol) | |||
(require 'org-bullets) | |||
(require 'ob-js) | |||
(require 'avy) | |||