[Pkg-javascript-commits] [node-unicode-loose-match] 02/06: Improve build rule

Bastien Roucariès rouca at moszumanska.debian.org
Fri Sep 8 15:03:10 UTC 2017


This is an automated email from the git hooks/post-receive script.

rouca pushed a commit to branch master
in repository node-unicode-loose-match.

commit 7fa9c92f693e174f3ede219e956362e3b57f4127
Author: Bastien ROUCARIÈS <roucaries.bastien at gmail.com>
Date:   Fri Sep 8 15:38:04 2017 +0200

    Improve build rule
---
 debian/rules     | 7 ++++++-
 scripts/build.js | 2 +-
 2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/debian/rules b/debian/rules
index 473846c..d0dfac8 100755
--- a/debian/rules
+++ b/debian/rules
@@ -3,9 +3,14 @@
 %:
 	dh $@
 
+dist/script/build.js: script/build.js
+	mkdir -p $(notdir $@)
+	sed -E -e "s,require('unicode-([[:digit:]]+([.])?)+'),require('../../debian/BinaryProperty'),g" $< > $@
+
 override_dh_auto_build:
 	mkdir -p dist/data
-	(cd dist && node ../scripts/build.js)
+	bash
+	(cd dist && node dist/scripts/build.js)
 
 override_dh_auto_clean:
 	rm -rf dist
diff --git a/scripts/build.js b/scripts/build.js
index 5f04028..3193217 100644
--- a/scripts/build.js
+++ b/scripts/build.js
@@ -1,6 +1,6 @@
 'use strict';
 
-const binaryProperties = require('unicode-9.0.0').Binary_Property;
+const binaryProperties = require('../debian/BinaryProperty');
 const propertyAliases = require('unicode-property-aliases');
 const valueAliases = require('unicode-property-value-aliases');
 const jsesc = require('jsesc');

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-unicode-loose-match.git



More information about the Pkg-javascript-commits mailing list