Skip to content

Commit 715e7f6

Browse files
committed
Merge pull request mozilla#814 from arturadib/build-ver
Macro for generating version information
2 parents 1d04bd2 + 5e0d704 commit 715e7f6

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ bundle: | $(BUILD_DIR)
6363
@cd src; \
6464
cat $(PDF_JS_FILES) > all_files.tmp; \
6565
sed '/PDFJSSCRIPT_INCLUDE_ALL/ r all_files.tmp' pdf.js > ../$(BUILD_TARGET); \
66+
sed -i '' "s/PDFJSSCRIPT_BUNDLE_VER/`git log --format="%H" -n 1`/" ../$(BUILD_TARGET); \
6667
rm -f *.tmp; \
6768
cd ..
6869

src/pdf.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,9 @@ var PDFJS = {};
77
// Use strict in our context only - users might not want it
88
'use strict';
99

10+
PDFJS.build = "PDFJSSCRIPT_BUNDLE_VER";
11+
1012
// Files are inserted below - see Makefile
1113
/* PDFJSSCRIPT_INCLUDE_ALL */
1214

1315
}).call((typeof window === 'undefined') ? this : window);
14-

0 commit comments

Comments
 (0)