]> git.friedersdorff.com Git - max/dotfiles.git/commitdiff
Merge branch 'master' of git.friedersdorff.com:max/dotfiles
authorMaximilian Friedersdorff <max@friedersdorff.com>
Tue, 15 Nov 2016 19:21:43 +0000 (19:21 +0000)
committerMaximilian Friedersdorff <max@friedersdorff.com>
Tue, 15 Nov 2016 19:21:43 +0000 (19:21 +0000)
X/.xinitrc
bash/.bash_aliases
bash/.bash_profile
bash/.bashrc
emacs/.emacs
offline_mail/.mbsync/aber.mbsync
offline_mail/.mbsync/personal-gmail.mbsync
offline_mail/.mbsync/personal.mbsync
vimperator/.vimperatorrc

index a031825e5dcc5703b8da221fef55f1fa27537748..17e58e923fb7ff769472f8003de709a2652e938b 100644 (file)
@@ -21,12 +21,18 @@ fi
 
 # Set keyboard layout
 case $HOSTNAME in
-    palladium|beryllium)
+    palladium)
        setxkbmap -variant colemak gb
        xmodmap -e "keycode 66 = Control_L Control_L Control_L Control_L"
        xmodmap -e "keycode 135 = Control_R Control_R Control_R Control_R"
        xmodmap -e "add Control = Control_L Control_R"
        ;;
+    beryllium)
+       setxkbmap -variant colemak us
+       xmodmap -e "keycode 66 = Control_L Control_L Control_L Control_L"
+       xmodmap -e "keycode 135 = Control_R Control_R Control_R Control_R"
+       xmodmap -e "add Control = Control_L Control_R"
+       ;;
     *)
 esac
 
@@ -44,6 +50,8 @@ export _JAVA_OPTIONS="-Dawt.useSystemAAFontSettings=on"
 
 feh --bg-scale ~/Pictures/background.jpg&
 
+twmnd&
+
 xset -b
 
 exec /usr/bin/ratpoison
index 36e02d4dfdcb6bc659acc78c08415933a9fbfe5f..0bab62d6bfee2521bee9a74d7e77947efa7fcb1b 100644 (file)
@@ -1,3 +1,5 @@
+#!/bin/bash
+
 if [ -x /usr/bin/dircolors ]; then
     test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
     alias ls='ls --color=auto'
@@ -9,5 +11,13 @@ if [ -x /usr/bin/dircolors ]; then
     alias egrep='egrep --color=auto'
 fi
 
-alias la='ls -lah'
+function la {
+    ls_out=$(\ls -lah --color=always "$@")
+    let "allowed_lines = $(tput lines) - 3"
+    if [ $(echo "$ls_out" | wc -l) -le $allowed_lines ]; then
+       echo "$ls_out"
+    else
+       echo "$ls_out" | less -r
+    fi
+}
 alias tmux='TERM=xterm-256color tmux'
index c408f2d146db1de4a9dd6ba4cc36447cdf9cda5c..d1982c4e1314cba6d6a61c99f3b2a9970cc11c4e 100644 (file)
@@ -14,6 +14,3 @@ if [ -f /etc/bash_completion ]; then
 fi
 
 export TMPDIR="/home/max/.local/tmp"
-
-gpg-agent --daemon --enable-ssh-support \
-  --write-env-file "${HOME}/.gpg-agent-info"
index a90c1772bfcd263c3f4303cc074baaab312d58b3..8d4422e7df195a31597f62d59f02678de5f5547c 100644 (file)
@@ -123,13 +123,17 @@ function __prompt_command()
 }
 PROMPT_COMMAND=__prompt_command
 
-
-if [ -f "${HOME}/.gpg-agent-info" ]; then
-  . "${HOME}/.gpg-agent-info"
-  export GPG_AGENT_INFO
-  export SSH_AUTH_SOCK
+if ! pgrep -x -u "${USER}" gpg-agent >/dev/null 2>&1; then
+    gpg-connect-agent /bye >/dev/null 2>&1
 fi
 
-
-# Set GPG TTY
+export GPG_AGENT_INFO="${GNUPGHOME:-${HOME}/.gnupg}/S.gpg-agent:-1:1"
 export GPG_TTY=$(tty)
+
+# Use gpg-agent for SSH
+unset SSH_AGENT_PID
+if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then
+    export SSH_AUTH_SOCK="/run/user/$UID/gnupg/S.gpg-agent.ssh"
+fi
+
+gpg-connect-agent udatestartuptty /bye >/dev/null
index f0348c8bace0ab80ebb6e96df9a793b64ec5593f..9628a42e56d4231027151aa20a29fd33b3a36bdd 100644 (file)
@@ -22,7 +22,7 @@
     ("#CC9393" "#DFAF8F" "#F0DFAF" "#7F9F7F" "#BFEBBF" "#93E0E3" "#94BFF3" "#DC8CC3")))
  '(package-selected-packages
    (quote
-    (yaml-mode minimap js2-mode editorconfig wanderlust evil-magit evil-leader evil-org molokai-theme org-evil flycheck-mypy jinja2 jinja2-mode highlight-indent-guides projectile helm-projectile zenburn-theme helm helm-config use-package flycheck company-jedi company org evil)))
+    (mu4e-alert yaml-mode minimap js2-mode editorconfig wanderlust evil-magit evil-leader evil-org molokai-theme org-evil flycheck-mypy jinja2 jinja2-mode highlight-indent-guides projectile helm-projectile zenburn-theme helm helm-config use-package flycheck company-jedi company org evil)))
  '(pdf-view-midnight-colors (quote ("#DCDCCC" . "#383838")))
  '(vc-annotate-background "#2B2B2B")
  '(vc-annotate-color-map
           "/usr/bin/mbsync -c /home/max/.mbsync/personal-gmail.mbsync -a &&"
           "/usr/bin/mbsync -c /home/max/.mbsync/aber.mbsync -a")
    mu4e-update-interval 60)
+  ; Force mu4e to rename file on moving
+  (setq mu4e-change-filenames-when-moving t)
   (setq
    message-send-mail-function 'smtpmail-send-it
    smtpmail-default-smtp-server "mail.friedersdorff.com"
    smtpmail-auth-credentials (expand-file-name "~/.authinfo.gpg"))
+  (setq mu4e-drafts-folder "/Drafts")
   (setq mu4e-contexts
        `( , (make-mu4e-context
              :name "Personal"
              :vars '((user-mail-address . "max@friedersdorff.com")
                      (user-full-name . "Maximilian Friedersdorff")
                      (mu4e-sent-folder . "/personal/Sent")
-                     (mu4e-drafts-folder . "/personal/Drafts")
                      (mu4e-trash-folder . "/personal/Trash")
                      (smtpmail-smtp-server . "mail.friedersdorff.com")
                      (smtpmail-smtp-service . 587))),
                     (user-full-name . "Maximilian Friedersdorff")
                     (mu4e-sent-folder . "/personal-gmail/Sent")
                     (mu4e-sent-messages-behaviour . 'delete)
-                    (mu4e-drafts-folder . "/personal-gmail/Drafts")
                     (smtpmail-smtp-server . "smtp.gmail.com")
                     (smtpmail-smtp-service . 587))),
            (make-mu4e-context
                           (when msg
                             (mu4e-message-contact-field-matches
                              msg (list :to :cc :bcc)
-                             "maf54\\+?.*@aber.ac.uk")))
+                             ".*@aber.ac.uk")))
             :vars '((user-mail-address . "maf54@aber.ac.uk")
                     (user-full-name . "Maximilian Friedersdorff")
                     (mu4e-sent-folder . "/aber/Sent")
-                    (mu4e-drafts-folder . "/aber/Drafts")
                     (mu4e-trash-folder . "/aber/Trash")
                     (smtpmail-smtp-server . "smtp.office365.com")
                     (smtpmail-smtp-service . 587))))
 
        mu4e-context-policy 'pick-first)
-  (setq mu4e-html2text-command "lynx -stdin -dump -force_html"))
+  (setq mu4e-html2text-command "lynx -stdin -dump -force_html")
+  (add-to-list 'mu4e-bookmarks
+              '((concatenate
+                 'string
+                 "flag:unread "
+                 "AND ( "
+                 "maildir:/personal/Inbox OR "
+                 "maildir:/personal/slackware OR "
+                 "maildir:/personal-gmail/Inbox OR "
+                 "maildir:/aber/Inbox "
+                 ")") "Unread Interesting Messages" ?i)
+              ))
+
+(use-package mu4e-alert
+  :ensure t
+  :config
+  (setq mu4e-alert-interesting-mail-query
+       (concatenate
+        'string
+        "flag:unread "
+        "AND ( "
+        "maildir:/personal/Inbox OR "
+        "maildir:/personal/slackware OR "
+        "maildir:/personal-gmail/Inbox OR "
+        "maildir:/aber/Inbox "
+        ")"))
+  (mu4e-alert-set-default-style 'notifications)
+  (add-hook 'after-init-hook #'mu4e-alert-enable-notifications))
 
 
 ;;;(global-company-mode)
index 5c62c22a1abdfd3d0133ea0c8c337dcbc5d9978f..1a996d57b5c5d56b62a7ad2e9dca4863bfe27b2d 100644 (file)
@@ -15,6 +15,6 @@ Inbox ~/mail/aber/Inbox
 Channel aber 
 Master :aber-remote:
 Slave :aber-local:
-Patterns "INBOX" "Drafts" "Sent" "Trash" "Junk E-Mail"
+Patterns "INBOX" "Sent" "Trash" "Junk E-Mail"
 Create Both
 SyncState *
index abc355eb487dfee001d12544cc4f46b343360fa5..7f47f38e820c2062504cf5b05b51dc819fd6d293 100644 (file)
@@ -24,12 +24,6 @@ Slave :gmail-local:"All Mail"
 SyncState *
 Create Slave
 
-Channel gmail-all-drafts
-Master :gmail-remote:"[Gmail]/Drafts"
-Slave :gmail-local:"Drafts"
-SyncState *
-Create Slave
-
 Channel gmail-all-spam
 Master :gmail-remote:"[Gmail]/Spam"
 Slave :gmail-local:"Spam"
@@ -47,3 +41,4 @@ Group gmail
 Channel gmail-default
 Channel gmail-sent
 Channel gmail-all-mail
+Channel gmail-all-spam
index e2e64724cebf49112276dda33560275873f44449..45a31035b3d5f27a7917f4a79b290d12e5b97820 100644 (file)
@@ -15,6 +15,6 @@ Inbox ~/mail/personal/Inbox
 Channel personal
 Master :personal-remote:
 Slave :personal-local:
-Patterns "INBOX" "Drafts" "Sent" "Spam" "Trash" "slackware" "quicknote" "todo"
+Patterns "INBOX" "Sent" "Spam" "Trash" "slackware" "quicknote" "todo"
 Create Both
 SyncState *
index 5d02f6fe42597971b158c106260ac0b2c8f28192..8befa56b1770eb2a0ba5251c37bbe4d9a8ade42d 100644 (file)
@@ -1,7 +1,12 @@
 "3.14.0 (created: 2016/06/07 23:58:16)
 
 set defsearch=duckduckgo
+set gui=noaddons,nobookmarks,nomenu,nonavigation,tabs
+
 js services.services.autoCompleteSearch.class_="@mozilla.org/autocomplete/search;1?name=unifiedcomplete"
+
+nnoremap k 3k
+nnoremap j 3j
 source! /home/max/.vimperatorrc.local
 
-" vim: set ft=vimperator:
+"vim: set ft=vimperator: