From 5572b3e4b636b0620441d0e888077192e2c5698f Mon Sep 17 00:00:00 2001 From: Valentin Gehrke Date: Tue, 26 Sep 2017 17:57:55 +0200 Subject: [PATCH] More work configuration --- emacs/.emacs | 28 +++++++++++-------- .../.emacs.d/snippets/cperl-mode/Shebang Perl | 6 ++++ 2 files changed, 23 insertions(+), 11 deletions(-) create mode 100644 emacs/.emacs.d/snippets/cperl-mode/Shebang Perl diff --git a/emacs/.emacs b/emacs/.emacs index a0433d4..ab3e03a 100644 --- a/emacs/.emacs +++ b/emacs/.emacs @@ -12,7 +12,6 @@ ;; Set frame title (setq frame-title-format "[%m] %f") -(setq-default indent-tabs-mode nil) ;; Default frame size (setq initial-frame-alist @@ -45,29 +44,32 @@ '(ansi-color-names-vector ["#242424" "#e5786d" "#95e454" "#cae682" "#8ac6f2" "#333366" "#ccaa8f" "#f6f3e8"]) '(blink-cursor-mode nil) + '(cperl-close-paren-offset -2) + '(cperl-electric-parens nil) + '(cperl-indent-level 2) + '(cperl-indent-parens-as-block t) '(custom-enabled-themes (quote (heroku))) '(custom-safe-themes (quote - ("4f2ede02b3324c2f788f4e0bad77f7ebc1874eff7971d2a2c9b9724a50fb3f65" default))) + ("4f2ede02b3324c2f788f4e0bad77f7ebc1874eff7971d2a2c9b9724a50fb3f65" default))) '(global-evil-surround-mode t) + '(indent-tabs-mode nil) '(inhibit-startup-screen t) '(menu-bar-mode nil) '(package-selected-packages (quote - (terminal-here shell-pop swiper neotree centered-cursor-mode ivy avy heroku-theme auto-complete use-package yasnippet evil-surround org evil-magit magit makefile-runner evil))) + (terminal-here shell-pop swiper neotree centered-cursor-mode ivy avy heroku-theme auto-complete use-package yasnippet evil-surround org evil-magit magit makefile-runner evil))) '(scroll-bar-mode nil) '(shell-pop-shell-type (quote - ("ansi-term" "*ansi-term*" - (lambda nil - (ansi-term shell-pop-term-shell))))) + ("ansi-term" "*ansi-term*" + (lambda nil + (ansi-term shell-pop-term-shell))))) '(shell-pop-window-position "top") '(shell-pop-window-size 20) '(tool-bar-mode nil) - '(cperl-indent-level 2) - '(cperl-close-paren-offset -2) - '(cperl-indent-parens-as-block t) - '(cperl-electric-parens nil)) + '(dired-listing-switches "-lh") + '(ac-ignore-case nil)) (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. @@ -248,9 +250,10 @@ ;; (setq-default shell-pop-term-shell my/default-shell)) ;; tabbing (doesn't really work yet) -(setq-default indent-tabs-mode t) (setq-default tab-width 4) (setq-default LateX-indent-level 4) +(add-hook 'latex-mode-hook (progn + (setq indent-tabs-mode t))) ;; Activate line numbers (global-linum-mode t) @@ -294,6 +297,9 @@ (global-set-key (kbd "") 'windmove-left) (global-set-key (kbd "") 'windmove-right) +; Whitespace mode toggle +(global-set-key (kbd "C-c C-l") 'whitespace-mode) + (defun cycle-window () "cycles windows" (interactive) diff --git a/emacs/.emacs.d/snippets/cperl-mode/Shebang Perl b/emacs/.emacs.d/snippets/cperl-mode/Shebang Perl new file mode 100644 index 0000000..c509f15 --- /dev/null +++ b/emacs/.emacs.d/snippets/cperl-mode/Shebang Perl @@ -0,0 +1,6 @@ +# -*- mode: snippet -*- +# name: Shebang Perl +# key: #! +# -- +#!/usr/bin/perl +$0