Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
  • 2 commits
  • 8 files changed
  • 0 comments
  • 1 contributor
2  .gitignore
... ...
@@ -1,3 +1,3 @@
1 1
 auto-save-list
2 2
 tramp
3  
-backups
  3
+elpa
30  init.el
... ...
@@ -1,28 +1,32 @@
1  
-;;;; Initial Configuration for Emacs
  1
+;;;; Emacs configuration
2 2
 ;;;; Randy Morris <randy.morris@archlinux.us>
3 3
 
4  
-(defun user-cfg-path (path)
5  
-  "Return user-emacs-directory prepended to path"
6  
-  (format "%s/%s" user-emacs-directory path))
  4
+(add-to-list 'load-path user-emacs-directory)
7 5
 
8  
-(add-to-list 'load-path (user-cfg-path "configs"))
  6
+(when (require 'package)
  7
+  (load "rm/packages"))
  8
+
  9
+;; mode-specific settings
  10
+(load "rm/configs/ansi-term")
  11
+(load "rm/configs/ediff")
  12
+(load "rm/configs/python-mode")
  13
+(load "rm/configs/tramp")
  14
+(load "rm/configs/whitespace-mode")
9 15
 
10 16
 ;; behavior
11 17
 (setq inhibit-startup-screen t
12 18
       require-final-newline t
13 19
       scroll-conservatively 1
14  
-      backup-directory-alist `(("." . ,(user-cfg-path "backups"))))
  20
+      backup-inhibited t)
15 21
 
16 22
 ;; indentation
17 23
 (setq-default indent-tabs-mode nil
18 24
               tab-width 4)
19 25
 
20  
-;; mode-specific settings
21  
-(load "ansi-term-cfg")
22  
-(load "ediff-cfg")
23  
-(load "python-mode-cfg")
24  
-(load "tramp-cfg")
25  
-(load "whitespace-mode-cfg")
  26
+;; display
  27
+(tool-bar-mode -1)
  28
+(scroll-bar-mode -1)
  29
+(menu-bar-mode -1)
26 30
 
27 31
 ;; host-specific settings
28  
-(load-file (format "%s.el" (user-cfg-path system-name)))
  32
+(load (format "rm/configs/%s.el" system-name))
0  configs/ansi-term-cfg.el → rm/configs/ansi-term.el
File renamed without changes
0  configs/ediff-cfg.el → rm/configs/ediff.el
File renamed without changes
0  configs/python-mode-cfg.el → rm/configs/python-mode.el
File renamed without changes
0  configs/tramp-cfg.el → rm/configs/tramp.el
File renamed without changes
0  configs/whitespace-mode-cfg.el → rm/configs/whitespace-mode.el
File renamed without changes
23  rm/packages.el
... ...
@@ -0,0 +1,23 @@
  1
+;;;; Emacs configuration
  2
+;;;; Randy Morris <randy.morris@archlinux.us>
  3
+;;;;
  4
+;;;; package.el configuration
  5
+
  6
+(add-to-list 'package-archives
  7
+			 '("marmalade" . "http://marmalade-repo.org/packages/"))
  8
+(package-initialize)
  9
+
  10
+(defun rm/require-package (package)
  11
+  "Install PACKAGE when it's not already installed."
  12
+  (when (not (package-installed-p package))
  13
+	(message "Installing package: %s" package)
  14
+	(package-install package)))
  15
+
  16
+(defun rm/init-packages ()
  17
+  "Install packages that are not yet installed."
  18
+  (interactive)
  19
+  (package-refresh-contents)
  20
+  (rm/require-package 'expand-region)
  21
+  (rm/require-package 'python-mode)
  22
+  (rm/require-package 'yasnippet)
  23
+  (message "Packages installed."))

No commit comments for this range

Something went wrong with that request. Please try again.