[Pkg-javascript-commits] [node-buble] 04/07: Switch from node-es6-module-transpiler to babel
Julien Puydt
julien.puydt at laposte.net
Sat Nov 4 16:04:57 UTC 2017
This is an automated email from the git hooks/post-receive script.
jpuydt-guest pushed a commit to branch master
in repository node-buble.
commit 607cb69e0e8b59758450b14e57658e5ba4d60bea
Author: Julien Puydt <julien.puydt at laposte.net>
Date: Sat Nov 4 09:53:01 2017 +0100
Switch from node-es6-module-transpiler to babel
---
debian/changelog | 2 +-
debian/control | 3 ++-
debian/links | 3 ++-
debian/rules | 19 +------------------
4 files changed, 6 insertions(+), 21 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 3036a34..f558f54 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,4 +2,4 @@ node-buble (0.15.2-1) unstable; urgency=low
* Initial release (Closes: #872638)
- -- Julien Puydt <julien.puydt at laposte.net> Sat, 09 Sep 2017 20:06:12 +0200
+ -- Julien Puydt <julien.puydt at laposte.net> Sat, 04 Nov 2017 09:52:16 +0100
diff --git a/debian/control b/debian/control
index 664ba99..e15e665 100644
--- a/debian/control
+++ b/debian/control
@@ -8,8 +8,9 @@ Build-Depends: debhelper (>= 10),
node-acorn-jsx (>= 3.0.1),
node-acorn-object-spread,
node-acorn-object-spread (>= 1.0.0),
+ node-babel-cli,
+ node-babel-preset-es2015,
node-chalk (>= 1.1.3),
- node-es6-module-transpiler,
node-magic-string (>= 0.14.0),
node-minimist (>= 1.2.0),
node-regexpu-core,
diff --git a/debian/links b/debian/links
index 40f963c..cf0d28f 100644
--- a/debian/links
+++ b/debian/links
@@ -1,3 +1,4 @@
usr/lib/nodejs/buble/bin/buble usr/bin/buble
-usr/lib/nodejs/buble/dist/index.js usr/lib/nodejs/buble/dist/buble.umd.js
+usr/lib/nodejs/buble/dist/index.js usr/lib/nodejs/buble/dist/buble.deps.js
usr/lib/nodejs/buble/dist/index.js usr/lib/nodejs/buble/dist/buble.js
+usr/lib/nodejs/buble/dist/index.js usr/lib/nodejs/buble/dist/buble.umd.js
diff --git a/debian/rules b/debian/rules
index f2cfc5b..28ad901 100755
--- a/debian/rules
+++ b/debian/rules
@@ -4,34 +4,17 @@ SOURCES = $(shell find src/ -name "*.js")
TARGETS = $(subst src, dist, $(SOURCES))
-COMPILE_MODULES = compile-modules convert -f commonjs
-
-ESCAPER = s/`\([^`]*\)`\([^`]*\)`\([^`]*\)`/`\1\\`\2\\`\3`/g
+COMPILE_MODULES = babeljs --presets=es2015
.PHONY: dist
%.js:
$(COMPILE_MODULES) $(subst dist, src, $@) > $@
- sed -i $@ -e "s/exports\[\"default\"\]/module.exports/g"
- sed -i $@ -e "s/\[\"default\"\]//g"
- sed -i $@ -e "s/string\")/string\").default/g"
- sed -i $@ -e "s/\\$$//g"
%:
dh $@
override_dh_auto_build: dist $(TARGETS)
- sed -i dist/program/types/index.js -e "s/\\$$//g"
- sed -i dist/index.js -e "s/acorn\([^ ]*\)\[\"default\"\]/acorn\1/g"
- sed -i dist/index.js -e "s|json\\$$\\$$.VERSION|json\\$$\\$$.version|g"
- # the next one moves the requires after the exports to break a loop
- sed -i dist/program/wrap.js -e '2{h;d};$${p;g}'
- sed -i bin/runBuble.js -e "s|../dist/buble.deps.js|../dist/index.js|"
- # the next ones fix issues with unescaped characters
- sed -i dist/program/types/ClassBody.js -e '123$(ESCAPER)'
- sed -i dist/program/types/ClassBody.js -e '157$(ESCAPER)'
- sed -i dist/program/types/ClassBody.js -e '162$(ESCAPER)'
- sed -i dist/program/types/ForStatement.js -e '31$(ESCAPER)'
dist:
mkdir -p dist/program/types/shared dist/utils
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-buble.git
More information about the Pkg-javascript-commits
mailing list