source: projects/specs/trunk/e/emacs/site-start.el.emacs23 @ 1273

Revision 1273, 2.9 KB checked in by munepi, 14 years ago (diff)

updated emacs and merged some patches and files

Line 
1;;; Emacs default settings for Vine Linux
2(defcustom emacs-ime (getenv "EMACS_IME")
3  "A variable of default Input Method Editor"
4  :type 'string)
5(if (null emacs-ime)
6    (setq emacs-ime "scim"))
7
8(defcustom vine-default t
9  "A boolean for all Vine Linux default settings"
10  :type 'boolean)
11(if (equal (getenv "LOGNAME") "root")
12    (setq vine-default nil))
13
14(defcustom vine-default-base t
15  "A boolean for vine-default-base"
16  :type 'boolean)
17
18(defcustom vine-default-faces t
19  "A boolean for vine-default-faces"
20  :type 'boolean)
21
22;; (defcustom vine-default-mouse t
23;;   "A boolean for vine-default-mouse"
24;;   :type 'boolean)
25
26;; (defcustom vine-default-misc t
27;;   "A boolean for vine-default-misc"
28;;   :type 'boolean)
29
30(defvar vine-default-setup-hook nil
31  "*List of functions to be called at vine-default-setup")
32
33(defvar after-vine-default-setup-hook nil
34  "*List of functions to be called at the end of vine-default-setup")
35
36(defun vine-default-setup ()
37  "a function for setup to default configurations of Vine Linux."
38  (if vine-default
39      (progn
40        (if vine-default-base (require 'vine-default-base))
41        (if vine-default-faces (require 'vine-default-faces))
42        ;; (if vine-default-mouse (require 'vine-default-mouse))
43        ;; (if vine-default-misc (require 'vine-default-misc))
44        (run-hooks 'vine-default-setup-hook)
45        (run-hooks 'after-vine-default-setup-hook)
46        )
47    )
48  )
49
50(add-hook 'after-init-hook 'vine-default-setup)
51
52
53(defun show-vine-default ()
54  (interactive)
55  (let ((command nil) (version nil)
56        (major (number-to-string emacs-major-version))
57        (minor (number-to-string emacs-minor-version)))
58    (setq version (concat major "." minor))
59    (setq command (concat "showvdefaultemacs " version))
60    (shell-command command)
61    )
62  )
63
64;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
65
66
67;; Aspell is a replacement for ispell
68;;(setq-default ispell-program-name "aspell")
69
70;; Add python support
71;(require 'python-mode)
72;(setq auto-mode-alist
73;      (cons '("\\.py$" . python-mode) auto-mode-alist))
74;(setq interpreter-mode-alist
75;      (cons '("python" . python-mode) interpreter-mode-alist))
76
77;; run functions from the /usr/share/emacs/site-lisp/site-start.d directory
78;; Files in this directory ending with ".el" are run on startup
79
80;(mapc 'load (directory-files "/usr/share/emacs/site-lisp/site-start.d" t "\\.el\\'"))
81(mapc 'load (directory-files "/etc/emacs-EMACS_VERSION/site-start.d" t "\\.el\\'"))
82
83;; Use the rpm-spec-mode for spec files
84;(require 'rpm-spec-mode)
85;(setq auto-mode-alist
86;      (cons '("\\.spec$" . rpm-spec-mode) auto-mode-alist))
87
88
89;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
90;;; load local settings at the end of site-start.el for local system
91(if (file-exists-p (expand-file-name "/etc/emacs/emacs-23-local.el"))
92    (load (expand-file-name "/etc/emacs/emacs-23-local.el") nil t nil))
93
94;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
95
96;; Local Variables:
97;; mode: emacs-lisp
98;; End:
Note: See TracBrowser for help on using the repository browser.