From 9a98e486469b5682345816e09a0853abb35bc7e3 Mon Sep 17 00:00:00 2001 From: Valentin Boettcher Date: Mon, 21 Jan 2019 16:16:13 +0100 Subject: [PATCH] upd --- config.laptop-ext.sh | 11 + dots/fish/config.fish | 2 + dots/home/.emacs | 449 ++++++++++++++++++++++++---------------- dots/home/.xmodmaprc | 26 +++ dots/i3/config.template | 3 +- dots/scripts/xcape_it | 17 ++ tools/oomox-gtk-theme | 2 +- 7 files changed, 330 insertions(+), 180 deletions(-) create mode 100644 config.laptop-ext.sh create mode 100644 dots/home/.xmodmaprc create mode 100644 dots/scripts/xcape_it diff --git a/config.laptop-ext.sh b/config.laptop-ext.sh new file mode 100644 index 0000000..3468efc --- /dev/null +++ b/config.laptop-ext.sh @@ -0,0 +1,11 @@ +WIFI_DEV="wlp4s0" +ETH_DEV="enp0s31f6" + +MAIN_NET=$WIFI_DEV +BATTERIES=(BAT0 BAT1) +MAIN_FONT="Source Code Pro 8" +MAIN_MONITOR=HDMI-2 +MONITORS=(eDP-1) + +#MONITORS=(VGA-0 DVI-D-0) +BAR_POS="bottom" diff --git a/dots/fish/config.fish b/dots/fish/config.fish index 719070d..19f5a4c 100644 --- a/dots/fish/config.fish +++ b/dots/fish/config.fish @@ -2,3 +2,5 @@ set fish_greeting "" set -gx PATH $HOME/.scripts $PATH set -g theme_display_date no set -g fish_key_bindings fish_default_key_bindings + +alias mktargz "tar -zcvf" \ No newline at end of file diff --git a/dots/home/.emacs b/dots/home/.emacs index 8a6167c..96c09c8 100644 --- a/dots/home/.emacs +++ b/dots/home/.emacs @@ -11,11 +11,16 @@ ;;; Backup (setq backup-directory-alist '(("." . "~/.emacs.d/backup")) - backup-by-copying t ; Don't delink hardlinks - version-control t ; Use version numbers on backups - delete-old-versions t ; Automatically delete excess backups - kept-new-versions 20 ; how many of the newest versions to keep - kept-old-versions 5 ; and how many of the old + backup-by-copying + t ; Don't delink hardlinks + version-control + t ; Use version numbers on backups + delete-old-versions + t ; Automatically delete excess backups + kept-new-versions + 20 ; how many of the newest versions to keep + kept-old-versions + 5 ; and how many of the old ) ;;; Desktop @@ -25,22 +30,37 @@ (load (expand-file-name "~/.roswell/helper.el")) (defun close-all-buffers () (interactive) - (mapc 'kill-buffer (buffer-list))) + (mapc 'kill-buffer + (buffer-list))) (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. - '(custom-safe-themes - (quote - ("84d2f9eeb3f82d619ca4bfffe5f157282f4779732f48a5ac1484d94d5ff5b279" "a27c00821ccfd5a78b01e4f35dc056706dd9ede09a8b90c6955ae6a390eb1c1e" "8db4b03b9ae654d4a57804286eb3e332725c84d7cdab38463cb6b97d5762ad26" "065efdd71e6d1502877fd56 -21b984cded01717930639ded0e569e1724d058af8" default))) - '(package-selected-packages - (quote - (all-the-icons ivy-rich ansible sly-repl-ansi-color sly-quicklisp sly-macrostep sly ranger company-tabnine meson-mode counsel-notmuch circe-notifications circe pretty-mode lispy info-beamer auctex-latexmk indium ag js-doc yasnippet-classic-snippets yasnippet-snippets ivy-yasnippet counsel sage-shell-mode dummyparens magit-filenotify docker-compose-mode docker xref-js2 js2-refactor flycheck-rtags flycheck ivy-rtags rtags auctex magit flycheck-rust avy-flycheck company racer cargo rust-mode restart-emacs nix-mode json-mode multiple-cursors swiper ivy xresources-theme powerline))) + '(custom-safe-themes (quote ("4cf3221feff536e2b3385209e9b9dc4c2e0818a69a1cdb4b522756bcdf4e00a4" + "84d2f9eeb3f82d619ca4bfffe5f157282f4779732f48a5ac1484d94d5ff5b279" + "a27c00821ccfd5a78b01e4f35dc056706dd9ede09a8b90c6955ae6a390eb1c1e" + "8db4b03b9ae654d4a57804286eb3e332725c84d7cdab38463cb6b97d5762ad26" + "065efdd71e6d1502877fd56 +21b984cded01717930639ded0e569e1724d058af8" + default))) + '(package-selected-packages (quote (srefactor sly-repl-ansi-color sly-quicklisp + sly-macrostep sly ranger company-tabnine counsel-notmuch + circe-notifications circe pretty-mode lispy + info-beamer auctex-latexmk ag indium js-doc + yasnippet-classic-snippets yasnippet-snippets + ivy-yasnippet counsel sage-shell-mode dummyparens + magit-filenotify docker-compose-mode docker + xref-js2 js2-refactor flycheck-rtags flycheck + ivy-rtags rtags auctex magit flycheck-rust + avy-flycheck company racer cargo rust-mode + restart-emacs json-mode multiple-cursors swiper + ivy xresources-theme powerline))) '(safe-local-variable-values (quote ((TeX-master . t)))) '(show-paren-mode t) - '(tramp-syntax (quote default) nil (tramp))) + '(tramp-syntax (quote default) + nil + (tramp))) (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. @@ -54,29 +74,35 @@ (when mark-ring (let ((pos (marker-position (car (last mark-ring))))) (if (not (= (point) pos)) - (goto-char pos) - (setq mark-ring (cons (copy-marker (mark-marker)) mark-ring)) - (set-marker (mark-marker) pos) - (setq mark-ring (nbutlast mark-ring)) - (goto-char (marker-position (car (last mark-ring)))))))) -(global-set-key (kbd "C-c m c") 'mc/edit-lines) -(global-set-key (kbd "C-x ") 'mc/edit-lines) + (goto-char pos) + (setq mark-ring (cons (copy-marker (mark-marker)) mark-ring)) + (set-marker (mark-marker) + pos) + (setq mark-ring (nbutlast mark-ring)) + (goto-char (marker-position (car (last mark-ring)))))))) +(global-set-key (kbd "C-c m c") + 'mc/edit-lines) +(global-set-key (kbd "C-x ") + 'mc/edit-lines) ;;; Packages (require 'package) -(add-to-list 'package-archives '("melpa" . "http://melpa.org/packages/")) +(add-to-list 'package-archives + '("melpa" . "http://melpa.org/packages/")) (package-initialize) -; fetch the list of packages available + ; fetch the list of packages available (unless package-archive-contents (package-refresh-contents)) -; install the missing packages + ; install the missing packages (dolist (package package-selected-packages) (unless (package-installed-p package) (package-install package))) +(require 'srefactor) +(require 'srefactor-lisp) ;;;; Company (with-eval-after-load 'company ;; (add-to-list 'company-backends #'company-tabnine) @@ -84,35 +110,21 @@ (add-to-list 'company-backends #'company-tabnine) (setq company-show-numbers t) (setq company-idle-delay 0) - (global-set-key (kbd "") 'company-complete) + (global-set-key (kbd "") + 'company-complete) (define-key company-active-map (kbd "C-n") 'company-select-next-or-abort) (define-key company-active-map (kbd "C-p") 'company-select-previous-or-abort) (company-tng-configure-default) - (setq company-frontends - '(company-tng-frontend - company-pseudo-tooltip-frontend - company-echo-metadata-frontend))) + (setq company-frontends '(company-tng-frontend company-pseudo-tooltip-frontend + company-echo-metadata-frontend))) ;;;; Magit -(global-set-key (kbd "C-x g") 'magit-status) +(global-set-key (kbd "C-x g") + 'magit-status) ;;;; Sage (add-hook 'sage-shell-after-prompt-hook #'sage-shell-view-mode) -;;;; GDB -(setq - ;; use gdb-many-windows by default - gdb-many-windows t - - ;; Non-nil means display source file containing the main routine at startup - gdb-show-main t - ) - -(add-hook 'gud-mode-hook - '(lambda () - (global-set-key (kbd "") 'gud-next) - (global-set-key (kbd "") 'gud-step))) - ;;;; Rtags (setq rtags-autostart-diagnostics t) (setq rtags-completions-enabled t) @@ -126,29 +138,28 @@ "For use in `c++-mode-hook'." (rtags-start-process-unless-running) (company-mode) - (local-set-key (kbd "M-.") 'rtags-find-symbol-at-point) - (local-set-key (kbd "M-,") 'rtags-find-references-at-point) - (local-set-key (kbd "") 'rtags-location-stack-back) - (local-set-key (kbd "") 'rtags-location-stack-forward) - (local-set-key (kbd "") 'rtags-print-symbol-info) - (global-set-key (kbd "") 'ff-find-other-file) + (local-set-key (kbd "M-.") + 'rtags-find-symbol-at-point) + (local-set-key (kbd "M-,") + 'rtags-find-references-at-point) + (local-set-key (kbd "") + 'rtags-location-stack-back) + (local-set-key (kbd "") + 'rtags-location-stack-forward) + (local-set-key (kbd "") + 'rtags-print-symbol-info) + (global-set-key (kbd "") + 'ff-find-other-file) (rtags-enable-standard-keybindings) - (flycheck-select-checker 'rtags) (setq-local flycheck-highlighting-mode nil) ;; RTags creates more accurate overlays. - (setq-local flycheck-check-syntax-automatically nil) - (flycheck-mode) - ) + (setq-local flycheck-check-syntax-automatically + nil) + (flycheck-mode)) (add-hook 'c-mode-hook 'c++-config) (add-hook 'c++-mode-hook 'c++-config) -;;;; MC -(global-set-key (kbd "C-S-c C-S-c") 'mc/edit-lines) -(global-set-key (kbd "C->") 'mc/mark-next-like-this) -(global-set-key (kbd "C-<") 'mc/mark-previous-like-this) -(global-set-key (kbd "C-c C-<") 'mc/mark-all-like-this) - ;;;; Ivy (ivy-mode 1) (setq ivy-use-virtual-buffers t) @@ -158,8 +169,9 @@ ;;;; Rust (add-hook 'rust-mode-hook 'cargo-minor-mode) (add-hook 'rust-mode-hook - (lambda () - (local-set-key (kbd "C-c ") #'rust-format-buffer))) + (lambda () + (local-set-key (kbd "C-c ") + #'rust-format-buffer))) ;;;;; Racer (setq racer-cmd "racer") ;; Rustup binaries PATH @@ -178,7 +190,8 @@ (require 'js2-refactor) (require 'xref-js2)(add-hook 'js2-mode-hook #'js2-refactor-mode) -(add-to-list 'auto-mode-alist '("\\.js\\'" . js2-mode)) +(add-to-list 'auto-mode-alist + '("\\.js\\'" . js2-mode)) (add-hook 'js2-mode-hook #'js2-imenu-extras-mode) (js2r-add-keybindings-with-prefix "C-c C-r") @@ -188,13 +201,15 @@ ;; unbind it. (define-key js-mode-map (kbd "M-.") nil) -(add-hook 'js2-mode-hook (lambda () - (add-hook 'xref-backend-functions #'xref-js2-xref-backend nil t))) +(add-hook 'js2-mode-hook + (lambda () + (add-hook 'xref-backend-functions #'xref-js2-xref-backend + nil t))) (add-hook 'js2-mode-hook - #'(lambda () - (define-key js2-mode-map "\C-ci" 'js-doc-insert-function-doc) - (define-key js2-mode-map "@" 'js-doc-insert-tag))) + #'(lambda () + (define-key js2-mode-map "\C-ci" 'js-doc-insert-function-doc) + (define-key js2-mode-map "@" 'js-doc-insert-tag))) (define-key js2-mode-map (kbd "C-k") #'js2r-kill) @@ -228,7 +243,7 @@ ;; (match-end 0) ;; ,replacement) ;; nil)))))) - + ;; ,@(loop for mode in modes collect `(add-hook ,mode (quote ,fname))) ;; nil))) @@ -236,161 +251,241 @@ (defun my-add-to-multiple-hooks (function hooks) (mapc (lambda (hook) - (add-hook hook function)) - hooks)) + (add-hook hook function)) + hooks)) -(my-add-to-multiple-hooks - #'(lambda () - (mapc (lambda (pair) (push pair prettify-symbols-alist)) - '(;; Syntax - ("funcall" . #x2A10) - ("#'" . #x2358)))) - '(emacs-lisp-mode-hook - lisp-interaction-mode-hook)) +(my-add-to-multiple-hooks #'(lambda () + (mapc (lambda (pair) + (push pair prettify-symbols-alist)) + '( ;; Syntax + ("funcall" . #x2A10) + ("#'" . #x2358)))) + '(emacs-lisp-mode-hook lisp-interaction-mode-hook)) -(add-hook 'emacs-lisp-mode-hook #'lispy-mode) -(add-hook 'eval-expression-minibuffer-setup-hook #'lispy-mode) -(add-hook 'ielm-mode-hook #'lispy-mode) -(add-hook 'lisp-mode-hook #'lispy-mode) +(add-hook 'emacs-lisp-mode-hook #'lispy-mode) +(add-hook 'eval-expression-minibuffer-setup-hook + #'lispy-mode) +(add-hook 'ielm-mode-hook #'lispy-mode) +(add-hook 'lisp-mode-hook #'lispy-mode) (add-hook 'lisp-interaction-mode-hook #'lispy-mode) -(add-hook 'scheme-mode-hook #'lispy-mode) +(add-hook 'scheme-mode-hook #'lispy-mode) (with-eval-after-load 'lispy - (define-key lispy-mode-map (kbd "M-(") #'lispy-parens-auto-wrap)) + (define-key lispy-mode-map (kbd "M-(") #'lispy-parens-auto-wrap) + (setq lispy-use-sly t)) ;;; Org (require 'org-install) - (require 'org-habit) - - (require 'doc-view) - (setq doc-view-resolution 144) +(require 'org-habit) + +(require 'doc-view) +(setq doc-view-resolution 144) - (setq org-treat-S-cursor-todo-selection-as-state-change nil) - (setq org-todo-state-tags-triggers - (quote (("CANCELLED" ("CANCELLED" . t)) - ("WAITING" ("WAITING" . t)) - ("HOLD" ("WAITING") ("HOLD" . t)) - (done ("WAITING") ("HOLD")) - ("TODO" ("WAITING") ("CANCELLED") ("HOLD")) - ("NEXT" ("WAITING") ("CANCELLED") ("HOLD")) - ("DONE" ("WAITING") ("CANCELLED") ("HOLD"))))) +(setq org-treat-S-cursor-todo-selection-as-state-change + nil) +(setq org-todo-state-tags-triggers (quote (("CANCELLED" + ("CANCELLED" . t)) + ("WAITING" + ("WAITING" . t)) + ("HOLD" + ("WAITING") + ("HOLD" . t)) + (done ("WAITING") + ("HOLD")) + ("TODO" + ("WAITING") + ("CANCELLED") + ("HOLD")) + ("NEXT" + ("WAITING") + ("CANCELLED") + ("HOLD")) + ("DONE" + ("WAITING") + ("CANCELLED") + ("HOLD"))))) - (setq org-todo-keywords - '( - (sequence "TODO" "WAITING" "NEXT" "HOLD" "|" "DONE") - (sequence "BESORGEN" "WARTEN" "|" "BESORGT") - (sequence "OUTOFSTOCK" "|" "INSTOCK") - (sequence "RESOLVE" "ASK" "RESEARCH" "|" "RESOLVED") - (sequence "HOMEWORK" "ACTIVE" "|" "FINISHED")) - ) +(setq org-todo-keywords '((sequence "TODO" "WAITING" "NEXT" "HOLD" "|" + "DONE") + (sequence "BESORGEN" "WARTEN" "|" "BESORGT") + (sequence "OUTOFSTOCK" "|" "INSTOCK") + (sequence "RESOLVE" "ASK" "RESEARCH" "|" "RESOLVED") + (sequence "HOMEWORK" "ACTIVE" "|" "FINISHED"))) - (setq org-clock-persist 'history) - (org-clock-persistence-insinuate) - (setq org-directory "~/Documents/org") - (setq org-default-notes-file "~/Documents/org/refile.org") - - ;; I use C-c c to start capture mode - (global-set-key (kbd "C-c c") 'org-capture) +(setq org-clock-persist 'history) +(org-clock-persistence-insinuate) +(setq org-directory "~/Documents/org") +(setq org-default-notes-file "~/Documents/org/refile.org") - ;; Capture templates for: TODO tasks, Notes, appointments, phone calls, meetings, and org-protocol - (setq org-capture-templates - (quote (("t" "Todo" entry (file org-default-notes-file) - "* TODO %?\n%U\n%a\n") - ("n" "Note" entry (file org-default-notes-file) - "* %? :NOTE:\n%U\n%a\n") - ("q" "Question" entry (file "~/Documents/org/refile/questions.org") - "* RESOLVE %? :QUESTION:\n%U\n%a\n") - ("e" "Exercise" entry (file "~/Documents/org/refile/exercises.org") - "* HOMEWORK %? :EXERCISE:\n%a\n") - ("j" "Journal" entry (file+datetree "~/Documents/org/diary.org") - "**** %?\n%U\n") - ("m" "Meeting" entry (file org-default-notes-file) - "** %? :MEETING:\n" - )))) +;; I use C-c c to start capture mode +(global-set-key (kbd "C-c c") + 'org-capture) + +;; Capture templates for: TODO tasks, Notes, appointments, phone calls, meetings, and org-protocol +(setq org-capture-templates (quote (("t" "Todo" + entry + (file org-default-notes-file) + "* TODO %?\n%U\n%a\n") + ("n" "Note" + entry + (file org-default-notes-file) + "* %? :NOTE:\n%U\n%a\n") + ("q" "Question" + entry + (file "~/Documents/org/refile/questions.org") + "* RESOLVE %? :QUESTION:\n%U\n%a\n") + ("e" "Exercise" + entry + (file "~/Documents/org/refile/exercises.org") + "* HOMEWORK %? :EXERCISE:\n%a\n") + ("j" "Journal" + entry + (file+datetree "~/Documents/org/diary.org") + "**** %?\n%U\n") + ("m" "Meeting" + entry + (file org-default-notes-file) + "** %? :MEETING:\n")))) -(setq org-agenda-files (list "~/Documents/org/todo.org")) +(setq org-agenda-files (list "~/Documents/org/todo.org" "~/Documents/org/calendar.org")) ;Targets include this file and any file contributing to the agenda - up to 9 levels deep - (setq org-refile-targets (quote ((nil :maxlevel . 9) - (org-agenda-files :maxlevel . 9)))) +(setq org-refile-targets (quote ((nil :maxlevel . + 9) + (org-agenda-files :maxlevel . + 9)))) ; Use full outline paths for refile targets - we file directly with IDO - (setq org-refile-use-outline-path t) +(setq org-refile-use-outline-path t) ; Targets complete directly with IDO - (setq org-outline-path-complete-in-steps nil) +(setq org-outline-path-complete-in-steps nil) ; Allow refile to create parent tasks with confirmation - (setq org-refile-allow-creating-parent-nodes (quote confirm)) +(setq org-refile-allow-creating-parent-nodes (quote confirm)) ; Use the current window for indirect buffer display - (setq org-indirect-buffer-display 'current-window) +(setq org-indirect-buffer-display 'current-window) ;;;; Refile settings ; Exclude DONE state tasks from refile targets - (defun bh/verify-refile-target () - "Exclude todo keywords with a done state from refile targets" - (not (member (nth 2 (org-heading-components)) org-done-keywords))) +(defun bh/verify-refile-target () + "Exclude todo keywords with a done state from refile targets" + (not (member (nth 2 + (org-heading-components)) + org-done-keywords))) - (setq org-refile-target-verify-function 'bh/verify-refile-target) - (global-set-key (kbd "C-c a") 'org-agenda) - (setq org-agenda-custom-commands - '(("X" agenda "" nil ("~/Documents/org/out/agenda.html")) - ("n" "Notes" tags "NOTE" - ((org-agenda-overriding-header "Notes") - (org-tags-match-list-sublevels t)) - ("~/Documents/org/out/notes.html")) - ("s" "Next" todo "NEXT" - ((org-agenda-overriding-header "Next") - (org-tags-match-list-sublevels t)) - ("~/Documents/org/out/next.html")) - ("f" "Questions" tags "QUESTION" - ((org-agenda-overriding-header "Questions") - (org-tags-match-list-sublevels t)) - ("~/Documents/org/out/question.html")) - ("l" "Einkaufsliste" todo "OUTOFSTOCK" - ((org-agenda-overriding-header "Einkaufsliste") - (org-tags-match-list-sublevels t)) - ("~/Documents/org/out/einkaufsliste.html")) - )) +(setq org-refile-target-verify-function 'bh/verify-refile-target) +(setq org-refile-targets '((org-agenda-files :maxlevel . 3))) +(global-set-key (kbd "C-c a") + 'org-agenda) +;; (org-super-agenda--def-auto-group path "their path in the outline" +;; :key-form (org-super-agenda--when-with-marker-buffer (org-super-agenda--get-marker item) +;; (when (org-up-heading-safe) +;; (org-format-outline-path (org-get-outline-path t t)) +;; ))) +;; (setq org-super-agenda-groups +;; '(;; Each group has an implicit boolean OR operator between its selectors. +;; ;; (:auto-parent t) + + +;; (:name "NEXT" ; Optionally specify section name +;; ;; :auto-path t +;; :todo "NEXT") +;; (:name "TODO" ; Optionally specify section name +;; :todo "TODO") ; Items that have this TODO keyword +;; )) + +(setq org-agenda-custom-commands '(("X" agenda + "" + nil + ("~/Documents/org/out/agenda.html")) + ("n" "Notes" + tags + "NOTE" + ((org-agenda-overriding-header "Notes") + (org-tags-match-list-sublevels t)) + ("~/Documents/org/out/notes.html")) + ("s" "Next" + todo + "NEXT" + ((org-agenda-overriding-header "Next") + (org-tags-match-list-sublevels t)) + ("~/Documents/org/out/next.html")) + ("f" "Questions" + tags + "QUESTION" + ((org-agenda-overriding-header "Questions") + (org-tags-match-list-sublevels t)) + ("~/Documents/org/out/question.html")) + ("l" "Einkaufsliste" + todo + "OUTOFSTOCK" + ((org-agenda-overriding-header "Einkaufsliste") + (org-tags-match-list-sublevels t)) + ("~/Documents/org/out/einkaufsliste.html")))) ;;; Email ;;use org mode for eml files (useful for thunderbird plugin) -(add-to-list 'auto-mode-alist '("\\.eml\\'" . org-mode)) +(add-to-list 'auto-mode-alist + '("\\.eml\\'" . org-mode)) (global-prettify-symbols-mode 1) ;;; Ricing -;;(require 'xresources-theme) +;; (require 'xresources-theme) (load-theme 'solarized t) (powerline-default-theme) -(global-set-key (kbd "M-g w") 'avy-goto-word-1) +(global-set-key (kbd "M-g w") + 'avy-goto-word-1) (put 'upcase-region 'disabled nil) (global-pretty-mode t) -(pretty-activate-groups - '(:sub-and-superscripts :greek :arithmetic-nary :arrows :arithmetic)) +(pretty-activate-groups '(:sub-and-superscripts :greek :arithmetic-nary + :arrows :arithmetic)) ;;; Avy -(global-set-key (kbd "M-g w") 'avy-goto-word-1) -(global-set-key (kbd "M-g f") 'avy-goto-line) -(global-set-key (kbd "C-'") 'avy-goto-char-2) +(global-set-key (kbd "M-g w") + 'avy-goto-word-1) +(global-set-key (kbd "M-g f") + 'avy-goto-line) +(global-set-key (kbd "C-'") + 'avy-goto-char-2) ;;; IRC -(setq circe-network-options - '(("Freenode" - :tls t - :nick "hiro98" - :sasl-username "hiro98" - :sasl-password "valentin981" - :channels ("#emacs-circe") - ))) +(setq circe-network-options '(("Freenode" :tls t + :nick "hiro98" + :sasl-username "hiro98" + :sasl-password "valentin981" + :channels ("#emacs-circe")))) (eval-after-load "circe-notifications" - '(setq circe-notifications-watch-strings - '("drmeister" "hiro" "hiro98"))) + '(setq circe-notifications-watch-strings '("drmeister" "hiro" "hiro98"))) (add-hook 'circe-server-connected-hook 'enable-circe-notifications) + + +;;; Shortcuts +(move-text-default-bindings) + +;;;; MC +(global-set-key (kbd "C-S-c C-S-c") + 'mc/edit-lines) +(global-set-key (kbd "C->") + 'mc/mark-next-like-this) +(global-set-key (kbd "C-<") + 'mc/mark-previous-like-this) +(global-set-key (kbd "C-c C-<") + 'mc/mark-all-like-this) +(define-key mc/keymap (kbd "") nil) +(global-set-key (kbd "C-S-") 'mc/add-cursor-on-click) +(put 'narrow-to-region 'disabled nil) + +;; Keybindings +(progn + (define-key key-translation-map (kbd "H-3") (kbd "•")) ; bullet + (define-key key-translation-map (kbd "H-4") (kbd "◇")) ; white diamond + (define-key key-translation-map (kbd "H-5") (kbd "†"))) diff --git a/dots/home/.xmodmaprc b/dots/home/.xmodmaprc new file mode 100644 index 0000000..5dd576a --- /dev/null +++ b/dots/home/.xmodmaprc @@ -0,0 +1,26 @@ +!keycode 18 = 9 parenleft 9 parenleft +!keycode 19 = 0 parenright 0 parenright +keycode 18 = 9 bracketleft 9 bracketleft +keycode 19 = 0 bracketright 0 bracketright +!keycode 34 = bracketleft braceleft bracketleft braceleft +!keycode 35 = bracketright braceright bracketright braceright +keycode 34 = parenleft braceleft parenleft braceleft +keycode 35 = parenright braceright parenright braceright + + + +clear lock +clear control +clear mod1 +clear mod2 +clear mod3 +clear mod4 +clear mod5 +keycode 37 = Hyper_L +keycode 66 = Control_L +add control = Control_L Control_R +add mod1 = Alt_L Alt_R Meta_L +add mod2 = Num_Lock +add mod3 = Hyper_L +add mod4 = Super_L Super_R +add mod5 = Mode_switch ISO_Level3_Shift diff --git a/dots/i3/config.template b/dots/i3/config.template index 7796193..0a9647b 100644 --- a/dots/i3/config.template +++ b/dots/i3/config.template @@ -264,7 +264,6 @@ exec --no-startup-id udiskie exec --no-startup-id xfce4-clipman exec --no-startup-id udiskie exec --no-startup-id ~/.scripts ec -e '' -exec --no-startup-id setxkbmap -layout us -option ctrl:nocaps -exec --no-startup-id setxkbmap -option ctrl:nocaps exec --no-startup-id kdeconnect-indicator exec --no-startup-id xset dpms 600 +exec --no-startup-id xmodmap ~/.xmodmaprc diff --git a/dots/scripts/xcape_it b/dots/scripts/xcape_it new file mode 100644 index 0000000..1c401ef --- /dev/null +++ b/dots/scripts/xcape_it @@ -0,0 +1,17 @@ +#!/bin/bash +spare_modifier="255" + +# Map an unused modifier's keysym to the spacebar's keycode and make it a +# control modifier. It needs to be an existing key so that emacs won't +# spazz out when you press it. Hyper_L is a good candidate. + +xmodmap -e "keycode 65 = $spare_modifier" +#xmodmap -e "remove mod4 = $spare_modifier" # hyper_l is mod4 by default +#xmodmap -e "add Control = $spare_modifier" + +# Map space to an unused keycode (to keep it around for xcape to +# use). +xmodmap -e "keycode any = space" + +# Finally use xcape to cause the space bar to generate a space when tapped. +xcape -e "$spare_modifier=space" diff --git a/tools/oomox-gtk-theme b/tools/oomox-gtk-theme index fef5f8d..82ddbda 160000 --- a/tools/oomox-gtk-theme +++ b/tools/oomox-gtk-theme @@ -1 +1 @@ -Subproject commit fef5f8d74dd0a0bc0add311d32bb0682715266a9 +Subproject commit 82ddbda30f2eae3dfdbaa85545893b1aa841d496