aboutsummaryrefslogtreecommitdiffstats
path: root/emacs
diff options
context:
space:
mode:
authorGravatar Tom Willemse2019-01-28 01:14:43 -0800
committerGravatar Tom Willemse2019-01-28 01:14:43 -0800
commit79ff6f374930c7545b23fe00dd70fad2de179855 (patch)
tree22b37741ebe8b83c4cc1cd7187b1788762a71c34 /emacs
parent85c7e13a83aba43e5c3d9b1a37d9a513f78b6732 (diff)
downloadnew-dotfiles-79ff6f374930c7545b23fe00dd70fad2de179855.tar.gz
new-dotfiles-79ff6f374930c7545b23fe00dd70fad2de179855.zip
Revert "Move stuff to other config files"
This reverts commit 6d01ebceb9e88975daf96f518c24a55c46b44729.
Diffstat (limited to 'emacs')
-rw-r--r--emacs/.emacs.d/init.el49
1 files changed, 38 insertions, 11 deletions
diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el
index a0aa803..c0be1b9 100644
--- a/emacs/.emacs.d/init.el
+++ b/emacs/.emacs.d/init.el
@@ -46,19 +46,25 @@
(require 'package)
(eval-and-compile
- ;; ;; Add MELPA because it's the biggest package repository for Emacs.
- ;; (add-to-list 'package-archives
- ;; '("melpa" . "https://melpa.org/packages/"))
- ;; ;; Add the Org package archive to be able to install the bleeding
- ;; ;; edge Org mode.
- ;; (add-to-list 'package-archives
- ;; '("org" . "http://orgmode.org/elpa/"))
- ;; ;; Add my personal package archive so I can upload custom libraries
- ;; ;; and stuff there.
- ;; (add-to-list 'package-archives
- ;; '("oni" . "https://ryuslash.org/elpa/"))
+ ;; Add MELPA because it's the biggest package repository for Emacs.
+ (add-to-list 'package-archives
+ '("melpa" . "https://melpa.org/packages/"))
+ ;; Add the Org package archive to be able to install the bleeding
+ ;; edge Org mode.
+ (add-to-list 'package-archives
+ '("org" . "http://orgmode.org/elpa/"))
+ ;; Add my personal package archive so I can upload custom libraries
+ ;; and stuff there.
+ (add-to-list 'package-archives
+ '("oni" . "https://ryuslash.org/elpa/"))
(package-initialize))
+;;; Highlight the line the cursor is on in the Packages menu for
+;;; better visibility.
+(add-hook 'package-menu-mode-hook 'hl-line-mode)
+
+(with-eval-after-load 'package (require 'oni-package-x))
+
;;;; Dependencies
(require 'counsel)
@@ -72,6 +78,19 @@
;;;; Settings
+;;; Put backup and auto save files in their own directories so they
+;;; don't clutter the rest of the filesystem.
+(setq backup-directory-alist
+ `((".*" . ,(concat user-emacs-directory "data/backup-files"))))
+
+(add-to-list
+ 'auto-save-file-name-transforms
+ `(".*" ,(concat user-emacs-directory "data/auto-save-files/") t)
+ :append)
+
+(setq auto-save-list-file-prefix
+ (concat user-emacs-directory "data/" "auto-save-list/.saves-"))
+
(setq delete-old-versions t)
(setq kept-new-versions 20)
(setq kept-old-versions 20)
@@ -119,6 +138,8 @@
(diminish 'counsel-mode)
(eval-when-compile (require 'bookmark))
+(setq bookmark-default-file
+ (concat user-emacs-directory "data/bookmarks"))
(setq user-full-name "Tom Willemse"
user-mail-address "tom@ryuslash.org")
@@ -166,6 +187,9 @@ ORIG-FUN is the function being wrapped, ARGS are the arguments specified"
(add-function :around (symbol-function 'diff-hl-changes-buffer)
#'oni:with-diff-hl-p4-args))
+(setq projectile-known-projects-file
+ (concat user-emacs-directory "data/projectile-bookmarks.eld"))
+
(with-eval-after-load 'projectile
(setq projectile-mode-line
'(:eval
@@ -176,6 +200,9 @@ ORIG-FUN is the function being wrapped, ARGS are the arguments specified"
""
(format " P[%s]" name)))))))
+(setq projectile-cache-file
+ (concat user-emacs-directory "data/projectile.cache"))
+
(projectile-mode)
(define-key projectile-mode-map (kbd "C-c p") 'projectile-command-map)