Skip to content

Commit

Permalink
Merge pull request #516 from bloomberg/no_header
Browse files Browse the repository at this point in the history
remove version header for annoying diffs, it is already versionized b…
  • Loading branch information
bobzhang committed Jul 13, 2016
2 parents 17d4427 + abcbf57 commit 8150db8
Show file tree
Hide file tree
Showing 390 changed files with 36 additions and 392 deletions.
21 changes: 17 additions & 4 deletions jscomp/bin/compiler.ml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
(** Bundled by ocaml_pack 07/11-22:15 *)
(** Bundled by ocaml_pack 07/13-10:03 *)
module String_map : sig
#1 "string_map.mli"
(* Copyright (C) 2015-2016 Bloomberg Finance L.P.
Expand Down Expand Up @@ -1867,6 +1867,11 @@ val query_package_infos :
module_system ->
info_query


(** set/get header *)
val no_version_header : bool ref


(** return [package_name] and [path] *)
val get_current_package_name_and_path :
module_system -> info_query
Expand Down Expand Up @@ -2028,7 +2033,7 @@ let get_package_name () =
| Empty | Browser -> None
| NonBrowser(n,_) -> Some n


let no_version_header = ref false

let set_package_name name =
match !packages_info with
Expand Down Expand Up @@ -18011,8 +18016,11 @@ let pp_deps_program
(kind : [Lam_module_ident.system | `Browser])
(program : J.deps_program) (f : Ext_pp.t) =
begin
P.string f bs_header;
P.newline f;
if not !Js_config.no_version_header then
begin
P.string f bs_header;
P.newline f
end ;
P.string f L.strict_directive;
P.newline f ;
ignore (match kind with
Expand Down Expand Up @@ -30522,6 +30530,11 @@ let buckle_script_flags =
("-bs-package-name",
Arg.String Js_config.set_package_name,
" set package name, useful when you want to produce npm packages")
::
("-bs-no-version-header",
Arg.Set Js_config.no_version_header,
" Don't print version header"
)
::
("-bs-package-output",
Arg.String Js_config.set_npm_package_path,
Expand Down
2 changes: 1 addition & 1 deletion jscomp/common/js_config.ml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ let get_package_name () =
| Empty | Browser -> None
| NonBrowser(n,_) -> Some n


let no_version_header = ref false

let set_package_name name =
match !packages_info with
Expand Down
5 changes: 5 additions & 0 deletions jscomp/common/js_config.mli
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,11 @@ val query_package_infos :
module_system ->
info_query


(** set/get header *)
val no_version_header : bool ref


(** return [package_name] and [path] *)
val get_current_package_name_and_path :
module_system -> info_query
Expand Down
7 changes: 5 additions & 2 deletions jscomp/js_dump.ml
Original file line number Diff line number Diff line change
Expand Up @@ -1658,8 +1658,11 @@ let pp_deps_program
(kind : [Lam_module_ident.system | `Browser])
(program : J.deps_program) (f : Ext_pp.t) =
begin
P.string f bs_header;
P.newline f;
if not !Js_config.no_version_header then
begin
P.string f bs_header;
P.newline f
end ;
P.string f L.strict_directive;
P.newline f ;
ignore (match kind with
Expand Down
5 changes: 5 additions & 0 deletions jscomp/js_main.ml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,11 @@ let buckle_script_flags =
("-bs-package-name",
Arg.String Js_config.set_package_name,
" set package name, useful when you want to produce npm packages")
::
("-bs-no-version-header",
Arg.Set Js_config.no_version_header,
" Don't print version header"
)
::
("-bs-package-output",
Arg.String Js_config.set_npm_package_path,
Expand Down
2 changes: 1 addition & 1 deletion jscomp/runtime/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ $(addsuffix .cmi, $(OTHERS)): js.cmi

RUNTIME := $(addsuffix .cmj, $(SOURCE_LIST))

BS_COMMON_FLAGS= -bs-diagnose -bs-no-check-div-by-zero -bs-cross-module-opt -bs-package-name $(npm_package_name)
BS_COMMON_FLAGS= -bs-no-version-header -bs-diagnose -bs-no-check-div-by-zero -bs-cross-module-opt -bs-package-name $(npm_package_name)

ifdef BS_RELEASE_BUILD
BS_FLAGS= $(BS_COMMON_FLAGS) -bs-package-output lib/js -bs-package-output goog:lib/goog -bs-package-output amdjs:lib/amdjs
Expand Down
2 changes: 1 addition & 1 deletion jscomp/stdlib/Makefile.shared
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ CAMLC=$(CAMLRUN) $(COMPILER)

#COMPFLAGS=-strict-sequence -w +33..39 -g -warn-error A -bin-annot -nostdlib \
# -safe-string
BS_COMMON_FLAGS= -bs-no-builtin-ppx-ml -bs-no-builtin-ppx-mli -bs-diagnose -bs-no-check-div-by-zero -bs-cross-module-opt -bs-package-name $(npm_package_name)
BS_COMMON_FLAGS= -bs-no-version-header -bs-no-builtin-ppx-ml -bs-no-builtin-ppx-mli -bs-diagnose -bs-no-check-div-by-zero -bs-cross-module-opt -bs-package-name $(npm_package_name)

ifdef BS_RELEASE_BUILD
BS_FLAGS= $(BS_COMMON_FLAGS) -bs-package-output lib/js -bs-package-output goog:lib/goog -bs-package-output amdjs:lib/amdjs
Expand Down
2 changes: 1 addition & 1 deletion jscomp/test/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ $(addsuffix .cmi, $(SOURCE_LIST)): ../runtime/js.cmi


COMPFLAGS+= $(MODULE_FLAGS) -w -40
COMPFLAGS+= -bs-diagnose -bs-cross-module-opt -bs-package-name $(npm_package_name) -bs-package-output lib/js/test/
COMPFLAGS+= -bs-no-version-header -bs-diagnose -bs-cross-module-opt -bs-package-name $(npm_package_name) -bs-package-output lib/js/test/


$(TESTS): $(CAMLC)
Expand Down
1 change: 0 additions & 1 deletion lib/js/arg.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_obj = require("./caml_obj");
Expand Down
1 change: 0 additions & 1 deletion lib/js/array.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/arrayLabels.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var $$Array = require("./array");
Expand Down
1 change: 0 additions & 1 deletion lib/js/bigarray.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/block.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/buffer.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Bytes = require("./bytes");
Expand Down
1 change: 0 additions & 1 deletion lib/js/bytes.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/bytesLabels.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Bytes = require("./bytes");
Expand Down
1 change: 0 additions & 1 deletion lib/js/callback.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Obj = require("./obj");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_array.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_backtrace.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_basic.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_builtin_exceptions.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_exceptions.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_float.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_format.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_int64 = require("./caml_int64");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_gc.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_hash.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_int32.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_int64.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_io.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_lexer.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_md5.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_module.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_obj.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_oo.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_parser.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_primitive.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_queue.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_string.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_sys.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_utils.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/caml_weak.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_obj = require("./caml_obj");
Expand Down
1 change: 0 additions & 1 deletion lib/js/camlinternalFormat.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Bytes = require("./bytes");
Expand Down
1 change: 0 additions & 1 deletion lib/js/camlinternalFormatBasics.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Block = require("./block");
Expand Down
1 change: 0 additions & 1 deletion lib/js/camlinternalLazy.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Obj = require("./obj");
Expand Down
1 change: 0 additions & 1 deletion lib/js/camlinternalMod.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/camlinternalOO.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_obj = require("./caml_obj");
Expand Down
1 change: 0 additions & 1 deletion lib/js/char.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/complex.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/curry.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_oo = require("./caml_oo");
Expand Down
1 change: 0 additions & 1 deletion lib/js/digest.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/filename.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_builtin_exceptions = require("./caml_builtin_exceptions");
Expand Down
1 change: 0 additions & 1 deletion lib/js/format.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_obj = require("./caml_obj");
Expand Down
1 change: 0 additions & 1 deletion lib/js/gc.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Block = require("./block");
Expand Down
1 change: 0 additions & 1 deletion lib/js/genlex.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Bytes = require("./bytes");
Expand Down
1 change: 0 additions & 1 deletion lib/js/hashtbl.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Bytes = require("./bytes");
Expand Down
1 change: 0 additions & 1 deletion lib/js/int32.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_obj = require("./caml_obj");
Expand Down
1 change: 0 additions & 1 deletion lib/js/int64.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';

var Caml_int64 = require("./caml_int64");
Expand Down
1 change: 0 additions & 1 deletion lib/js/js.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/js_float.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/js_int.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/js_int64.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down
1 change: 0 additions & 1 deletion lib/js/js_nativeint.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// GENERATED CODE BY BUCKLESCRIPT VERSION 0.8.1 , PLEASE EDIT WITH CARE
'use strict';


Expand Down

0 comments on commit 8150db8

Please sign in to comment.