[DRE-commits] r3139 - in packages/libhaml-ruby/trunk/debian: . patches

gwolf at alioth.debian.org gwolf at alioth.debian.org
Fri Dec 19 21:18:03 UTC 2008


Author: gwolf
Date: 2008-12-19 21:18:03 +0000 (Fri, 19 Dec 2008)
New Revision: 3139

Added:
   packages/libhaml-ruby/trunk/debian/haml-elisp.emacsen-install
   packages/libhaml-ruby/trunk/debian/haml-elisp.emacsen-remove
   packages/libhaml-ruby/trunk/debian/patches/supress_end_in_html_conversor
Modified:
   packages/libhaml-ruby/trunk/debian/changelog
   packages/libhaml-ruby/trunk/debian/control
   packages/libhaml-ruby/trunk/debian/patches/series
   packages/libhaml-ruby/trunk/debian/rules
Log:
Added emacs mode for Haml and Sass (in its own package); added a patch
for the HTML to Haml converter


Modified: packages/libhaml-ruby/trunk/debian/changelog
===================================================================
--- packages/libhaml-ruby/trunk/debian/changelog	2008-12-19 03:06:22 UTC (rev 3138)
+++ packages/libhaml-ruby/trunk/debian/changelog	2008-12-19 21:18:03 UTC (rev 3139)
@@ -1,3 +1,12 @@
+libhaml-ruby (2.0.6-2) unstable; urgency=low
+
+  * Added missing Homepage, Vcs-Svn, Vcs-Browser fields in debian/control
+  * Added the Sass and Haml Emacs modes in the haml-elisp binary package
+  * Patched lib/haml/html.rb to supress 'end' blocks in Haml generated
+    from RHTML, as the parser regars it as invalid
+
+ -- Gunnar Wolf <gwolf at debian.org>  Fri, 19 Dec 2008 15:12:11 -0600
+
 libhaml-ruby (2.0.6-1) unstable; urgency=low
 
   * Initial upload (Closes: #509159)

Modified: packages/libhaml-ruby/trunk/debian/control
===================================================================
--- packages/libhaml-ruby/trunk/debian/control	2008-12-19 03:06:22 UTC (rev 3138)
+++ packages/libhaml-ruby/trunk/debian/control	2008-12-19 21:18:03 UTC (rev 3139)
@@ -6,6 +6,9 @@
 Build-Depends: ruby-pkg-tools (>= 0.8), cdbs, debhelper (>= 7), libsetup-ruby1.8, graphviz, quilt
 Build-Depends-Indep: ruby1.8, rdoc
 Standards-Version: 3.8.0
+Homepage: http://haml.hamptoncatlin.com/
+Vcs-Svn: svn://svn.debian.org/pkg-ruby-extras/libhaml-ruby/trunk/
+Vcs-Browser: http://svn.debian.org/wsvn/pkg-ruby-extras/libhaml-ruby/trunk/
 
 Package: libhaml-ruby1.8
 Architecture: all
@@ -56,3 +59,12 @@
  .
  This is the documentation package, with upstream documentation, as well as
  generated rdoc.
+
+Package: haml-elisp
+Section: editors
+Architecture: all
+Depends: emacs | emacsen
+Recommends: libhaml-ruby
+Description: Haml (and Sass) modes for Emacsen
+ This package provides the emacs-lisp for syntax-highlighting Haml and
+ Sass modes. 

Added: packages/libhaml-ruby/trunk/debian/haml-elisp.emacsen-install
===================================================================
--- packages/libhaml-ruby/trunk/debian/haml-elisp.emacsen-install	                        (rev 0)
+++ packages/libhaml-ruby/trunk/debian/haml-elisp.emacsen-install	2008-12-19 21:18:03 UTC (rev 3139)
@@ -0,0 +1,29 @@
+#!/bin/sh 
+set -e
+FILES="haml-mode.el sass-mode.el"
+
+FLAVOR="$1"
+
+echo "install/haml-elisp: Handling install of emacsen flavor ${FLAVOR}"
+
+if [ "${FLAVOR}" != "emacs" ]; then
+  echo "install/haml-elisp: byte-compiling for ${FLAVOR}"
+  cd /usr/share/emacs/site-lisp/haml-elisp
+  mkdir -p /usr/share/${FLAVOR}/site-lisp/haml-elisp
+  cp $FILES /usr/share/${FLAVOR}/site-lisp/haml-elisp
+  cd /usr/share/${FLAVOR}/site-lisp/haml-elisp
+  cat <<EOF > path.el
+(setq load-path (cons "." load-path) byte-compile-warnings nil)
+EOF
+  FLAVORTEST=`echo $FLAVOR | cut -c-6`
+  if [ ${FLAVORTEST} = xemacs ] ; then
+    SITEFLAG="-no-site-file"
+  else
+    SITEFLAG="--no-site-file"
+  fi
+  ${FLAVOR} -q ${SITEFLAG} -batch -l path.el -f batch-byte-compile $FILES
+  rm path.el $FILES
+fi
+
+exit 0;
+

Added: packages/libhaml-ruby/trunk/debian/haml-elisp.emacsen-remove
===================================================================
--- packages/libhaml-ruby/trunk/debian/haml-elisp.emacsen-remove	                        (rev 0)
+++ packages/libhaml-ruby/trunk/debian/haml-elisp.emacsen-remove	2008-12-19 21:18:03 UTC (rev 3139)
@@ -0,0 +1,12 @@
+#!/bin/sh -e
+
+FLAVOR="$1"
+
+echo "install/haml-elisp: Handling removal of emacsen flavor ${FLAVOR}"
+
+if [ "${FLAVOR}" != "emacs" ]; then
+  echo "install/haml-elisp: purging byte-compiled files for ${FLAVOR}"
+  rm -rf /usr/share/${FLAVOR}/site-lisp/haml-elisp
+fi
+
+exit 0;

Modified: packages/libhaml-ruby/trunk/debian/patches/series
===================================================================
--- packages/libhaml-ruby/trunk/debian/patches/series	2008-12-19 03:06:22 UTC (rev 3138)
+++ packages/libhaml-ruby/trunk/debian/patches/series	2008-12-19 21:18:03 UTC (rev 3139)
@@ -1,2 +1,3 @@
+supress_end_in_html_conversor
 fix-hardcoded-gem-paths
 get-version-from-right-path

Added: packages/libhaml-ruby/trunk/debian/patches/supress_end_in_html_conversor
===================================================================
--- packages/libhaml-ruby/trunk/debian/patches/supress_end_in_html_conversor	                        (rev 0)
+++ packages/libhaml-ruby/trunk/debian/patches/supress_end_in_html_conversor	2008-12-19 21:18:03 UTC (rev 3139)
@@ -0,0 +1,17 @@
+# This patch has been sent to the upstream author; RHTML is usually
+# converted into Haml with spurious, invalid 'end' blocks. This fixes
+# it. 
+Index: libhaml-ruby-2.0.6/lib/haml/html.rb
+===================================================================
+--- libhaml-ruby-2.0.6.orig/lib/haml/html.rb	2008-12-19 15:11:14.000000000 -0600
++++ libhaml-ruby-2.0.6/lib/haml/html.rb	2008-12-19 15:11:58.000000000 -0600
+@@ -211,7 +211,8 @@
+     end
+ 
+     def self.haml_tag_silent(text)
+-      text.split("\n").map { |line| "- #{line.strip}\n" }.join
++      text.split("\n").map { |line| "- #{line.strip}\n" }.
++        reject {|line| line == "- end\n"}.join
+     end
+ 
+     private

Modified: packages/libhaml-ruby/trunk/debian/rules
===================================================================
--- packages/libhaml-ruby/trunk/debian/rules	2008-12-19 03:06:22 UTC (rev 3138)
+++ packages/libhaml-ruby/trunk/debian/rules	2008-12-19 21:18:03 UTC (rev 3139)
@@ -7,3 +7,7 @@
 install/libhaml-ruby1.8::
 	install -m 0644 VERSION ./debian/libhaml-ruby1.8/usr/lib/ruby/1.8/haml/
 	dh_installman debian/haml.1 debian/sass.1 debian/html2haml.1 debian/css2sass.1
+
+install/haml-elisp::
+	install -d ./debian/haml-elisp/usr/share/emacs/site-lisp/haml-elisp
+	install -m 0644 extra/haml-mode.el extra/sass-mode.el ./debian/haml-elisp/usr/share/emacs/site-lisp/haml-elisp/




More information about the Pkg-ruby-extras-commits mailing list