Skip to content

Commit

Permalink
updating init
Browse files Browse the repository at this point in the history
  • Loading branch information
DimitrisKyriakoudis committed Mar 11, 2018
1 parent ec1ee97 commit 5cf1bc9
Show file tree
Hide file tree
Showing 2 changed files with 118 additions and 127 deletions.
10 changes: 7 additions & 3 deletions init.el
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,15 @@
(eval-when-compile
(require 'use-package)
(setq use-package-always-ensure t))

(local-set-key [tab] 'tab-to-tab-stop)
;;unindent?

(global-set-key [tab] 'indent-for-tab-command)
;;unindent?

(global-set-key (kbd "C-w") 'kill-whole-line)

(org-babel-load-file (expand-file-name "~/.emacs.d/setup.org"))



(use-package elpy)
(elpy-enable)
235 changes: 111 additions & 124 deletions setup.org
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,12 @@
** Window
#+BEGIN_SRC emacs-lisp
(delete-selection-mode 1)

(line-number-mode 1)

(show-paren-mode 1)


(global-set-key (kbd "C-c p")
(lambda() (interactive)
(org-babel-load-file "~/.emacs.d/init.org")))
(global-set-key (kbd "C-c p")
(lambda() (interactive)
(org-babel-load-file "~/.emacs.d/init.org")))

(setq scroll-conservatively 100)
;;;;;; WINDOW
Expand Down Expand Up @@ -50,7 +47,6 @@
'("m" "#+begin_src emacs-lisp\n\n#+end_src" "<src lang=\"emacs-lisp\">\n\n</src>"))



(setq org-hide-leading-stars t)
(setq org-alphabetical-lists t)
(setq org-src-fontify-natively t) ;; you want this to activate coloring in blocks
Expand All @@ -60,16 +56,15 @@
#+END_SRC
*** Code
#+BEGIN_SRC emacs-lisp
(use-package haskell-mode)
(add-hook 'haskell-mode-hook 'interactive-haskell-mode)
(use-package paredit)
(use-package haskell-mode)
;;(use-package paredit)

(use-package magit)
(use-package ghc)

(use-package magit)
(use-package ghc)
(use-package intero
:config (intero-global-mode 1))

(use-package intero
:config
(intero-global-mode 1))
#+END_SRC
*** Navigation
**** Smartparens
Expand All @@ -78,8 +73,6 @@
:config (smartparens-global-mode 1))




#+END_SRC
**** Ido
#+BEGIN_SRC emacs-lisp
Expand All @@ -100,11 +93,6 @@
(global-unset-key (kbd "C-q"))

(use-package hydra)
;;(hydra-create "C-q"
;; '(("i" 'previous-line)
;; ("l" 'right-char)
;; ("k" 'next-line)
;; ("j" 'left-char)))
;; When C-q-(any of the following) is pressed, the letter navigation mode is enabled until another command is executed
;; (C-q doesn't have to remain pressed after the first toggle)
(defhydra hydra-move (global-map "C-q")
Expand All @@ -118,21 +106,21 @@
**** Ace-Window
#+BEGIN_SRC emacs-lisp

(use-package org)
(use-package avy
:bind ("M-s" . avy-goto-char))
(use-package smex
:init (smex-initialize)
:bind
("M-x" . smex))
;;(use-package org)
;;(use-package avy
;; :bind ("M-s" . avy-goto-char))
;;(use-package smex
;; :init (smex-initialize)
;; :bind
;; ("M-x" . smex))

(use-package rainbow-mode
:config (rainbow-mode 1))
;;(use-package rainbow-mode
;; :config (rainbow-mode 1))


(use-package company)
(use-package try)
(use-package ace-window)
;;(use-package company)
;;(use-package try)
;;(use-package ace-window)


;;(use-package intero)
Expand All @@ -159,13 +147,13 @@

**** Avy-Jump
#+BEGIN_SRC emacs-lisp
(use-package avy)
;;(use-package avy)

;;(ivy-mode 1)
;;(setq ivy-use-virtual-buffers t)
;;(setq enable-recursive-minibuffers t)
;;(global-set-key "\C-s" 'swiper)

(ivy-mode 1)
(setq ivy-use-virtual-buffers t)
(setq enable-recursive-minibuffers t)
(global-set-key "\C-s" 'swiper)

#+END_SRC

* Config
Expand All @@ -176,7 +164,6 @@
(global-unset-key (kbd "C-k"))
(global-unset-key (kbd "C-l"))


(global-unset-key (kbd "C-e"))
(global-unset-key (kbd "C-a"))
(global-set-key (kbd "C-u") 'beginning-of-line)
Expand All @@ -201,88 +188,88 @@
#+BEGIN_SRC emacs-lisp


;;;;;; QWERTY -> DVORAK while keeping all keybindngs the same
;; First row
(define-key key-translation-map (kbd "q") (kbd "'"))
(define-key key-translation-map (kbd "w") (kbd ","))
(define-key key-translation-map (kbd "e") (kbd "."))
(define-key key-translation-map (kbd "r") (kbd "p"))
(define-key key-translation-map (kbd "t") (kbd "y"))
(define-key key-translation-map (kbd "y") (kbd "f"))
(define-key key-translation-map (kbd "u") (kbd "g"))
(define-key key-translation-map (kbd "i") (kbd "c"))
(define-key key-translation-map (kbd "o") (kbd "r"))
(define-key key-translation-map (kbd "p") (kbd "l"))
(define-key key-translation-map (kbd "[") (kbd "/"))
(define-key key-translation-map (kbd "]") (kbd "="))

(define-key key-translation-map (kbd "Q") (kbd "\""))
(define-key key-translation-map (kbd "W") (kbd "<"))
(define-key key-translation-map (kbd "E") (kbd ">"))
(define-key key-translation-map (kbd "R") (kbd "P"))
(define-key key-translation-map (kbd "T") (kbd "Y"))
(define-key key-translation-map (kbd "Y") (kbd "F"))
(define-key key-translation-map (kbd "U") (kbd "G"))
(define-key key-translation-map (kbd "I") (kbd "C"))
(define-key key-translation-map (kbd "O") (kbd "R"))
(define-key key-translation-map (kbd "P") (kbd "L"))
(define-key key-translation-map (kbd "{") (kbd "?"))
(define-key key-translation-map (kbd "}") (kbd "+"))

;; Second row
(define-key key-translation-map (kbd "a") (kbd "a"))
(define-key key-translation-map (kbd "s") (kbd "o"))
(define-key key-translation-map (kbd "d") (kbd "e"))
(define-key key-translation-map (kbd "f") (kbd "u"))
(define-key key-translation-map (kbd "g") (kbd "i"))
(define-key key-translation-map (kbd "h") (kbd "d"))
(define-key key-translation-map (kbd "j") (kbd "h"))
(define-key key-translation-map (kbd "k") (kbd "t"))
(define-key key-translation-map (kbd "l") (kbd "n"))
(define-key key-translation-map (kbd ";") (kbd "s"))
(define-key key-translation-map (kbd "'") (kbd "-"))

(define-key key-translation-map (kbd "A") (kbd "A"))
(define-key key-translation-map (kbd "S") (kbd "O"))
(define-key key-translation-map (kbd "D") (kbd "E"))
(define-key key-translation-map (kbd "F") (kbd "U"))
(define-key key-translation-map (kbd "G") (kbd "I"))
(define-key key-translation-map (kbd "H") (kbd "D"))
(define-key key-translation-map (kbd "J") (kbd "H"))
(define-key key-translation-map (kbd "K") (kbd "T"))
(define-key key-translation-map (kbd "L") (kbd "N"))
(define-key key-translation-map (kbd ":") (kbd "S"))
(define-key key-translation-map (kbd "\"") (kbd "_"))

;; Third row
(define-key key-translation-map (kbd "z") (kbd ";"))
(define-key key-translation-map (kbd "x") (kbd "q"))
(define-key key-translation-map (kbd "c") (kbd "j"))
(define-key key-translation-map (kbd "v") (kbd "k"))
(define-key key-translation-map (kbd "b") (kbd "x"))
(define-key key-translation-map (kbd "n") (kbd "b"))
(define-key key-translation-map (kbd "m") (kbd "m"))
(define-key key-translation-map (kbd ",") (kbd "w"))
(define-key key-translation-map (kbd ".") (kbd "v"))
(define-key key-translation-map (kbd "/") (kbd "z"))

(define-key key-translation-map (kbd "Z") (kbd ":"))
(define-key key-translation-map (kbd "X") (kbd "Q"))
(define-key key-translation-map (kbd "C") (kbd "J"))
(define-key key-translation-map (kbd "V") (kbd "K"))
(define-key key-translation-map (kbd "B") (kbd "X"))
(define-key key-translation-map (kbd "N") (kbd "B"))
(define-key key-translation-map (kbd "M") (kbd "M"))
(define-key key-translation-map (kbd "<") (kbd "W"))
(define-key key-translation-map (kbd ">") (kbd "V"))
(define-key key-translation-map (kbd "?") (kbd "Z"))


;; Misc
(define-key key-translation-map (kbd "-") (kbd "["))
(define-key key-translation-map (kbd "=") (kbd "]"))

(define-key key-translation-map (kbd "_") (kbd "{"))
(define-key key-translation-map (kbd "+") (kbd "}"))
;;;;;; QWERTY -> DVORAK while keeping all keybindngs the same
;; First row
(define-key key-translation-map (kbd "q") (kbd "'"))
(define-key key-translation-map (kbd "w") (kbd ","))
(define-key key-translation-map (kbd "e") (kbd "."))
(define-key key-translation-map (kbd "r") (kbd "p"))
(define-key key-translation-map (kbd "t") (kbd "y"))
(define-key key-translation-map (kbd "y") (kbd "f"))
(define-key key-translation-map (kbd "u") (kbd "g"))
(define-key key-translation-map (kbd "i") (kbd "c"))
(define-key key-translation-map (kbd "o") (kbd "r"))
(define-key key-translation-map (kbd "p") (kbd "l"))
(define-key key-translation-map (kbd "[") (kbd "/"))
(define-key key-translation-map (kbd "]") (kbd "="))

(define-key key-translation-map (kbd "Q") (kbd "\""))
(define-key key-translation-map (kbd "W") (kbd "<"))
(define-key key-translation-map (kbd "E") (kbd ">"))
(define-key key-translation-map (kbd "R") (kbd "P"))
(define-key key-translation-map (kbd "T") (kbd "Y"))
(define-key key-translation-map (kbd "Y") (kbd "F"))
(define-key key-translation-map (kbd "U") (kbd "G"))
(define-key key-translation-map (kbd "I") (kbd "C"))
(define-key key-translation-map (kbd "O") (kbd "R"))
(define-key key-translation-map (kbd "P") (kbd "L"))
(define-key key-translation-map (kbd "{") (kbd "?"))
(define-key key-translation-map (kbd "}") (kbd "+"))

;; Second row
(define-key key-translation-map (kbd "a") (kbd "a"))
(define-key key-translation-map (kbd "s") (kbd "o"))
(define-key key-translation-map (kbd "d") (kbd "e"))
(define-key key-translation-map (kbd "f") (kbd "u"))
(define-key key-translation-map (kbd "g") (kbd "i"))
(define-key key-translation-map (kbd "h") (kbd "d"))
(define-key key-translation-map (kbd "j") (kbd "h"))
(define-key key-translation-map (kbd "k") (kbd "t"))
(define-key key-translation-map (kbd "l") (kbd "n"))
(define-key key-translation-map (kbd ";") (kbd "s"))
(define-key key-translation-map (kbd "'") (kbd "-"))

(define-key key-translation-map (kbd "A") (kbd "A"))
(define-key key-translation-map (kbd "S") (kbd "O"))
(define-key key-translation-map (kbd "D") (kbd "E"))
(define-key key-translation-map (kbd "F") (kbd "U"))
(define-key key-translation-map (kbd "G") (kbd "I"))
(define-key key-translation-map (kbd "H") (kbd "D"))
(define-key key-translation-map (kbd "J") (kbd "H"))
(define-key key-translation-map (kbd "K") (kbd "T"))
(define-key key-translation-map (kbd "L") (kbd "N"))
(define-key key-translation-map (kbd ":") (kbd "S"))
(define-key key-translation-map (kbd "\"") (kbd "_"))

;; Third row
(define-key key-translation-map (kbd "z") (kbd ";"))
(define-key key-translation-map (kbd "x") (kbd "q"))
(define-key key-translation-map (kbd "c") (kbd "j"))
(define-key key-translation-map (kbd "v") (kbd "k"))
(define-key key-translation-map (kbd "b") (kbd "x"))
(define-key key-translation-map (kbd "n") (kbd "b"))
(define-key key-translation-map (kbd "m") (kbd "m"))
(define-key key-translation-map (kbd ",") (kbd "w"))
(define-key key-translation-map (kbd ".") (kbd "v"))
(define-key key-translation-map (kbd "/") (kbd "z"))

(define-key key-translation-map (kbd "Z") (kbd ":"))
(define-key key-translation-map (kbd "X") (kbd "Q"))
(define-key key-translation-map (kbd "C") (kbd "J"))
(define-key key-translation-map (kbd "V") (kbd "K"))
(define-key key-translation-map (kbd "B") (kbd "X"))
(define-key key-translation-map (kbd "N") (kbd "B"))
(define-key key-translation-map (kbd "M") (kbd "M"))
(define-key key-translation-map (kbd "<") (kbd "W"))
(define-key key-translation-map (kbd ">") (kbd "V"))
(define-key key-translation-map (kbd "?") (kbd "Z"))


;; Misc
(define-key key-translation-map (kbd "-") (kbd "["))
(define-key key-translation-map (kbd "=") (kbd "]"))

(define-key key-translation-map (kbd "_") (kbd "{"))
(define-key key-translation-map (kbd "+") (kbd "}"))

#+END_SRC

0 comments on commit 5cf1bc9

Please sign in to comment.