Browse Source

add html-helper-mode 2.19.1.1-5 files

git-svn-id: http://trac.vinelinux.org/repos/projects/specs@756 ec354946-7b23-47d6-9f5a-488ba84defc7
iwaim 14 years ago
parent
commit
b3bb6cfcbd

+ 13 - 0
h/html-helper-mode/HHM-MK

@@ -0,0 +1,13 @@
+;;; -*- Emacs-Lisp -*-
+;; for byte-compile html-helper-mode
+
+;;; Code
+(require 'bytecomp)
+
+(let ((load-path (cons default-directory load-path))
+      (compile-file-list '("./tempo.el"
+			   "./html-helper-mode.el")))
+  (message "Compiling -----")
+  (mapcar 'byte-compile-file compile-file-list))
+
+;;; ends here

+ 107 - 0
h/html-helper-mode/hhm.dot.emacs

@@ -0,0 +1,107 @@
+;;; html-helper-mode
+
+;; Initialization
+(autoload 'html-helper-mode "html-helper-mode" "Yay HTML" t)
+(setq auto-mode-alist (append
+		       '(
+			 ("\\.html" . html-helper-mode)
+			 ("\\.shtml" . html-helper-mode))
+		       auto-mode-alist))
+
+
+;; Set this to be whatever signature
+;; you want on the bottom of your pages. 
+;(setq html-helper-address-string "who@hoge.ne.jp")
+
+
+;; If not nil, then use the full HTML menu.
+;(setq html-helper-use-expert-menu nil) ;; Default
+
+
+;; If not nil,
+;; then modify `local-write-file-hooks' to do timestamps.
+;(setq html-helper-do-write-file-hooks t) ;; Default 
+
+
+;;If not nil,
+;; then insert `html-helper-new-buffer-strings' for new buffers.
+;(setq html-helper-build-new-buffer t) ;; Default
+
+
+;; Version of HTML DTD you're using.
+;(setq html-helper-htmldtd-version
+;      "<!DOCTYPE HTML PUBLIC \"-//IETF//DTD HTML//EN\">\n") ;; Default
+
+ 
+;; Extra items to put in the HTML expert menu.
+;; The value of this symbol is appended to the beginning of the expert
+;; menu that is handed off to easymenu for definition.
+;; It should be a list of vectors or lists
+;; which themselves are vectors (for submenus).
+;(setq html-helper-user-menu nil) ;; Default
+
+
+;; Basic indentation size used for list indentation
+;(setq html-helper-basic-offset 2) ;; Default
+
+
+;; Indentation of lines that follow a <li> item.
+;; Default is 4, the length of things like \"<li>\" and \"<dd>\".
+;(setq html-helper-item-continue-indent 4) ;; Default
+
+
+;; If not nil,
+;; the indentation code for html-helper is turned off.
+;(setq html-helper-never-indent nil) ;; Default
+
+
+;; Template for new buffers.
+;; Inserted by `html-helper-insert-new-buffer-strings'
+;; if `html-helper-build-new-buffer' is set to t
+;(setq html-helper-new-buffer-template
+;  '(html-helper-htmldtd-version
+;    "<html> <head>\n"
+;    "<title>" p "</title>\n</head>\n\n"
+;    "<body>\n"
+;    "<h1>" p "</h1>\n\n"
+;    p
+;    "\n\n<hr>\n"
+;    "<address>" html-helper-address-string "</address>\n"
+;    html-helper-timestamp-start
+;    html-helper-timestamp-end
+;    "\n</body> </html>\n")) ;; Default
+
+
+;; Start delimiter for timestamps.
+;; Everything between `html-helper-timestamp-start' and
+;; `html-helper-timestamp-end' will be deleted and
+;; replaced with the output of the functions `html-helper-timestamp-hook'
+;; if `html-helper-do-write-file-hooks' is t
+;(setq html-helper-timestamp-start "<!-- hhmts start -->\n") ;; Default
+
+
+;; End delimiter for timestamps.
+;; Everything between `html-helper-timestamp-start' and
+;; `html-helper-timestamp-end' will be deleted and
+;; replaced with the output of the function `html-helper-insert-timestamp'
+;; if `html-helper-do-write-file-hooks' is t
+;(setq html-helper-timestamp-end "<!-- hhmts end -->") ;; Default
+
+
+;; Change format and {start,end} delimiter for timestamps.
+;; if you will be use this,
+;; you should change `html-helper-new-buffer-template'. 
+;(setq html-helper-timestamp-start       "<META name=\"date\" content=\""
+;      html-helper-timestamp-end         "\">")
+;(defun TT:html-helper-insert-timestamp ()
+;  (let ((tz (car (current-time-zone)))
+;        (tzh) (tzm))
+;    (setq tzh (/ tz 3600)
+;          tz (- tz (* tzh 3600)))
+;    (setq tzm (/ tz 60)
+;          tz (- tz (* tzm 60)))
+;    (insert
+;     (concat
+;      (format-time-string "%Y-%m-%dT%H:%M:%S" (current-time))
+;      (format "%s%02d:%02d" (if (> tzh 0) "+" "-") tzh tzm)))))
+;(setq html-helper-timestamp-hook 'TT:html-helper-insert-timestamp)

+ 71 - 0
h/html-helper-mode/html-helper-mode-install.sh

@@ -0,0 +1,71 @@
+#! /bin/sh -e
+#  /usr/lib/emacsen-common/packages/install/foo
+# [ This particular script hasn't been tested, so be careful. ]
+
+set -e
+
+FLAVOR=$1
+PACKAGE="html-helper-mode"
+
+if [ "X${FLAVOR}" = "X" ]; then
+    echo Need argument to determin FLAVOR of emacs;
+    exit 1
+fi
+
+if [ "X${PACKAGE}" = "X" ]; then
+    echo Internal error: need package name;
+    exit 1;
+fi
+
+ELDIR=/usr/share/emacs/site-lisp/${PACKAGE}
+ELCDIR=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
+
+STARTDIR=/etc/${FLAVOR}/site-start.d
+STARTFILE="${PACKAGE}-init.el";
+
+SITELISP=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
+
+#EFLAGS="-batch -q"
+EFLAGS="-batch -l HHM-MK"
+COMPILE="-batch -q -f batch-byte-compile"
+
+case "${FLAVOR}" in
+	emacs|emacs19)
+	;;
+	*)
+
+	echo -n "install/${PACKAGE}: Byte-compiling for ${FLAVOR} ..."
+#	if [ "${FLAVOR}" = "mule2" ]; then
+#		if [ ! -d /usr/share/emacs/site-lisp/clime ]; then
+#		echo " exited."
+#		echo "W: Please install \`clime' package for mule2." ;
+#		exit 0;
+#		fi
+#	else
+#		if [ ! -d /usr/share/emacs/site-lisp/flim ]; then
+#		echo " exited."
+#		echo "W: Please install \`flim' package for ${FLAVOR}." ;
+#		exit 0;
+#		fi
+#	fi
+
+	rm -rf ${ELCDIR}
+    install -m 755 -d ${ELCDIR}
+
+    # Byte compile
+    (cd ${ELDIR}
+	${FLAVOR} ${EFLAGS}   > ${ELCDIR}/CompilationLog 2>&1
+	install -m0644 *.elc /usr/share/${FLAVOR}/site-lisp/${PACKAGE} \
+                              > ${ELCDIR}/CompilationLog 2>&1
+	rm -f *.elc           > ${ELCDIR}/CompilationLog 2>&1
+	rm -f ${ELCDIR}/*.el
+    )
+
+	gzip -9 ${ELCDIR}/CompilationLog
+
+	#cp -a ${ELDIR}/${STARTFILE} ${STARTDIR}/55${STARTFILE};
+	echo " done."
+	;;
+esac
+
+exit 0;

+ 38 - 0
h/html-helper-mode/html-helper-mode-remove.sh

@@ -0,0 +1,38 @@
+#!/bin/sh
+# /usr/lib/emacsen-common/packages/remove/foo
+# [ This particular script hasn't been tested either, so be careful. ]
+set -e
+
+FLAVOR=$1
+PACKAGE="html-helper-mode"
+
+if [ "X${FLAVOR}" = "X" ]; then
+    echo Need argument to determin FLAVOR of emacs;
+    exit 1
+fi
+
+if [ "X${PACKAGE}" = "X" ]; then
+    echo Internal error: need package name;
+    exit 1;
+fi
+
+ELDIR=/usr/share/emacs/site-lisp/${PACKAGE}
+ELCDIR=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
+STARTDIR=/etc/${FLAVOR}/site-start.d
+STARTFILE="${PACKAGE}-init.el";
+
+SITELISP=/usr/share/${FLAVOR}/site-lisp
+
+case "${FLAVOR}" in
+	emacs|emacs19)
+	;;
+	*)
+	echo -n "remove/${PACKAGE}: Handling removal of emacsen flavor ${FLAVOR} ..."
+	rm -rf ${ELCDIR}
+#	rm -f ${STARTDIR}/55${STARTFILE}*
+	echo " done."
+	;;
+    *)
+esac
+
+exit 0;

+ 22 - 33
h/html-helper-mode/html-helper-mode-vl.spec

@@ -2,14 +2,15 @@
 %define       prereq_ge()   %(LC_ALL="C" rpm -q --queryformat 'PreReq:%%{NAME} >= %%{VERSION}' %1| grep -v "is not")
 %define       origname      html-helper-mode
 %define       origver       2.19.1.1
-%define       release       5%{?_dist_release}
+%define       release       6%{?_dist_release}
+%define       emacsen_pkgdir /usr/lib/emacsen-common/packages
 
 # Main
 Summary: Major mode for editing HTML (for Emacsen)
 Name: %{origname}
 Version: %{origver}
 Release: %{release}
-License: GPL2
+License: GPLv2+
 Group: Applications/Editors/Emacs
 URL: http://www.santafe.edu/~nelson/tools/
 Source0: http://www.santafe.edu/~nelson/hhm-beta/html-helper-mode.el
@@ -23,6 +24,8 @@ Source7: hhm.dot.emacs
 Source8: HHM-MK
 Source9: html-helper-mode-install.sh
 Source10: html-helper-mode-remove.sh
+Source11: vine-default-%{origname}.el
+Source12: %{origname}-init.el
 Buildroot: %{_tmppath}/%{name}-root
 PreReq:       emacsen
 Requires:     emacsen
@@ -35,16 +38,6 @@ Vendor: Project Vine
 Distribution: Vine Linux
 
 %description
-NOTE:
-It require following,
-so please get and install them before to install it.
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
-Emacs:
-emacsen and emacsen-common
-=====================================================
-
-What's html-helper-mode
-========================
 html-helper-mode makes it easier to write HTML documents.
 This mode handles inserting HTML codes in a variety of ways
 (keybindings, completion in the buffer).
@@ -54,20 +47,10 @@ hilit19 patterns, and a variety of other things.
 Initialization
 ===============
 Please refer the following file:
-  "/usr/doc/%{name}-%{version}/hhm.dot.emacs"
-  "/usr/doc/%{name}-%{version}/*.html"
+  "%{_docdir}/%{name}-%{version}/hhm.dot.emacs"
+  "%{_docdir}/%{name}-%{version}/*.html"
 
 %description -l ja
-注意:
-以下が必要ですので、
-インストール前にそれらをインストールして下さい。
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
-Emacs:
-emacsen と emacsen-common
-================================================
-
-html-helper-mode とは
-======================
 html-helper-mode は、HTML ドキュメントの作成を簡単にします。
 このモードでは、HTML コードの挿入に多様な方法が使えます。
 また、INDENTATION、タイムスタンプ等をサポートします。
@@ -75,8 +58,8 @@ html-helper-mode は、HTML ドキュメントの作成を簡単にします。
 初期設定
 =========
 下記を参考にしてください:
-  "/usr/doc/%{name}-%{version}/hhm.dot.emacs"
-  "/usr/doc/%{name}-%{version}/*.html"
+  "%{_docdir}/%{name}-%{version}/hhm.dot.emacs"
+  "%{_docdir}/%{name}-%{version}/*.html"
 
 # '
 %prep
@@ -99,9 +82,9 @@ cp %SOURCE8 ./
 [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT}
 [ "${RPM_BUILD_ROOT}" != "/" ] && mkdir -p ${RPM_BUILD_ROOT}
 
-mkdir -p $RPM_BUILD_ROOT/%{_datadir}/emacs/site-lisp/%{origname}
-mkdir -p $RPM_BUILD_ROOT/%{_libdir}/emacsen-common/packages/install
-mkdir -p $RPM_BUILD_ROOT/%{_libdir}/emacsen-common/packages/remove
+mkdir -p %{buildroot}%{_datadir}/emacs/site-lisp/%{origname}/packages
+mkdir -p %{buildroot}%{emacsen_pkgdir}/install
+mkdir -p %{buildroot}%{emacsen_pkgdir}/remove
 
 #
 # install el files
@@ -150,12 +133,18 @@ rm -rf ${RPM_BUILD_DIR}/%{origname}-%{origver}
 %files 
 %defattr(-,root,root)
 %doc *.html hhm.dot.emacs
-%{_datadir}/emacs/site-lisp/%{origname}/
-/usr/lib/emacsen-common/packages/install/%{origname}
-/usr/lib/emacsen-common/packages/remove/%{origname}
-
+%{_datadir}/emacs/site-lisp/%{origname}
+%{emacsen_pkgdir}/install/%{origname}
+%{emacsen_pkgdir}/remove/%{origname}
 
 %changelog
+* Wed Apr  7 2010 IWAI, Masaharu <iwai@alib.jp> 2.19.1.1-6
+- apply vine-default
+ - add vine-default (Source11)
+ - add init.el (Source12)
+- using %%{emacsen_pkgdir} macro
+- update %%description
+
 * Wed May 06 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 2.19.1.1-5
 - spec in utf8
 - applied new versioning policy