Adds uglify to Makefile and minified version of the library.
This commit is contained in:
parent
fc5e22ac29
commit
6deea8bca2
|
@ -1,6 +1,8 @@
|
|||
node_modules
|
||||
libs
|
||||
lib-jitsi-meet.js
|
||||
lib-jitsi-meet.min.js
|
||||
lib-jitsi-meet.js.map
|
||||
doc
|
||||
|
||||
|
||||
|
|
16
Makefile
16
Makefile
|
@ -1,14 +1,16 @@
|
|||
BROWSERIFY = ./node_modules/.bin/browserify
|
||||
UGLIFYJS = ./node_modules/.bin/uglifyjs
|
||||
EXORCIST = ./node_modules/.bin/exorcist
|
||||
GLOBAL_FLAGS =
|
||||
OUTPUT_DIR = .
|
||||
DEPLOY_DIR = ../../jitsi-meet
|
||||
|
||||
all: compile deploy
|
||||
all: compile uglify deploy
|
||||
|
||||
compile:FLAGS = $(GLOBAL_FLAGS)
|
||||
compile: app
|
||||
|
||||
debug: compile-debug deploy
|
||||
debug: compile-debug source-maps uglify-debug deploy
|
||||
|
||||
compile-debug:FLAGS = -d $(GLOBAL_FLAGS)
|
||||
compile-debug: app
|
||||
|
@ -16,6 +18,16 @@ compile-debug: app
|
|||
app:
|
||||
$(BROWSERIFY) $(FLAGS) JitsiMeetJS.js -s JitsiMeetJS -o $(OUTPUT_DIR)/lib-jitsi-meet.js
|
||||
|
||||
source-maps:
|
||||
cat $(OUTPUT_DIR)/lib-jitsi-meet.js | $(EXORCIST) $(OUTPUT_DIR)/lib-jitsi-meet.js.map
|
||||
|
||||
uglify:SOURCE_MAPS=
|
||||
uglify:
|
||||
$(UGLIFYJS) -p relative $(OUTPUT_DIR)/lib-jitsi-meet.js -o $(OUTPUT_DIR)/lib-jitsi-meet.min.js $(SOURCE_MAPS)
|
||||
|
||||
uglify-debug:SOURCE_MAPS=--source-map $(OUTPUT_DIR)/lib-jitsi-meet.min.map --in-source-map $(OUTPUT_DIR)/lib-jitsi-meet.js.map
|
||||
uglify-debug: uglify
|
||||
|
||||
clean:
|
||||
rm -f $(OUTPUT_DIR)/lib-jitsi-meet.js
|
||||
|
||||
|
|
1346
lib-jitsi-meet.js
1346
lib-jitsi-meet.js
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -29,7 +29,9 @@
|
|||
"devDependencies": {
|
||||
"browserify": "11.1.x",
|
||||
"jshint": "^2.8.0",
|
||||
"precommit-hook": "^3.0.0"
|
||||
"precommit-hook": "^3.0.0",
|
||||
"exorcist": "*",
|
||||
"uglify-js": "2.4.24"
|
||||
},
|
||||
"scripts": {
|
||||
"lint": "./node_modules/.bin/jshint .",
|
||||
|
|
Loading…
Reference in New Issue