1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54
|
;;
;; /etc/emacs/site-start.d/50dpkg-dev-el.el
;;
;; Copyright (C) 1997, Klee Dienes <klee@mit.edu>
;; I hereby release this program into the public domain.
;;
;; Copyright (C) 2000, 2001 Roland Mas <lolando@debian.org>,
;; Peter S Galbraith <psg@debian.org>
;; We also release this program into the public domain.
(if (fboundp 'debian-pkg-add-load-path-item)
(setq load-path (debian-pkg-add-load-path-item
(concat "/usr/share/"
(symbol-name flavor)
"/site-lisp/dpkg-dev-el")) )
(setq load-path (cons (concat "/usr/share/"
(symbol-name flavor)
"/site-lisp/dpkg-dev-el") load-path)) )
(autoload 'debian-changelog-mode "debian-changelog-mode"
"Major mode for editing Debian-style change logs." t)
(autoload 'debian-changelog-web-bug "debian-changelog-mode"
"Browse the BTS for a bug report number via browse-url." t)
(autoload 'debian-changelog-web-bugs "debian-changelog-mode"
"Browse the BTS for this package via browse-url." t)
(autoload 'debian-changelog-web-package "debian-changelog-mode"
"Search Debian web page in ARCHIVE for this package via browse-url." t)
(autoload 'debian-changelog-web-packages "debian-changelog-mode"
"Search Debian web page for this package via browse-url." t)
(autoload 'debian-changelog-web-this-bug "debian-changelog-mode"
"Browse the BTS via browse-url for the bug report number under point." t)
(autoload 'debian-control-mode "debian-control-mode"
"Major mode for editing Debian control files (i.e. debian/control)." t)
; Automatically set mode for debian/changelog and debian/rules files.
(setq auto-mode-alist
(append
'(("/debian/changelog\\'" . debian-changelog-mode)
("changelog.Debian" . debian-changelog-mode)
("changelog.Debian.gz" . debian-changelog-mode)
("/debian/control\\'" . debian-control-mode)
("/debian/[^/]*emacsen-startup\\'" . emacs-lisp-mode) )
auto-mode-alist ))
; Automatically set mode for files that are Debian chalgelogs,
; even if that can't be deduced from the file name.
(defun debian-changelog-find-file-hook ()
(if (looking-at
"\\S-+ +(\\([0-9]:\\)?[0-9][0-9a-zA-Z.+:]+\\(-\\([0-9a-zA-Z.+]+\\)\\)?) +[^;]+; urgency=[^\n]*")
(debian-changelog-mode)))
(add-hook 'find-file-hooks 'debian-changelog-find-file-hook t)
|