File tree Expand file tree Collapse file tree 2 files changed +29
-30
lines changed Expand file tree Collapse file tree 2 files changed +29
-30
lines changed Original file line number Diff line number Diff line change 1
1
NAME = "com_googlesource_gerrit_bazlets"
2
2
3
3
def load_bazlets (
4
- commit = None ,
5
- local_path = None
6
- ):
7
- if not local_path :
8
- native .git_repository (
9
- name = NAME ,
10
- remote = "https://gerrit.googlesource.com/bazlets" ,
11
- commit = commit ,
12
- )
13
- else :
14
- native .local_repository (
15
- name = NAME ,
16
- path = local_path ,
17
- )
4
+ commit = None ,
5
+ local_path = None ):
6
+ if not local_path :
7
+ native .git_repository (
8
+ name = NAME ,
9
+ remote = "https://gerrit.googlesource.com/bazlets" ,
10
+ commit = commit ,
11
+ )
12
+ else :
13
+ native .local_repository (
14
+ name = NAME ,
15
+ path = local_path ,
16
+ )
Original file line number Diff line number Diff line change 2
2
load ("@com_googlesource_gerrit_bazlets//tools:genrule2.bzl" , "genrule2" )
3
3
4
4
def stamp (workspace , name ):
5
- # TODO(davido): Remove manual merge of manifest file when this feature
6
- # request is implemented: https://github.com/bazelbuild/bazel/issues/2009
7
- genrule2 (
8
- name = "%s-stamped" % name ,
9
- stamp = 1 ,
10
- srcs = [":%s" % name ],
11
- cmd = " && " .join ([
12
- "GEN_VERSION=$$(cat bazel-out/stable-status.txt | grep -w STABLE_BUILD_%s_LABEL | cut -d ' ' -f 2)" % workspace .upper (),
13
- "cd $$TMP" ,
14
- "unzip -q $$ROOT/$<" ,
15
- "echo \" Implementation-Version: $$GEN_VERSION\n $$(cat META-INF/MANIFEST.MF)\" > META-INF/MANIFEST.MF" ,
16
- "zip -qr $$ROOT/$@ ." ]) ,
17
- outs = [ "%s-stamped.jar" % name ] ,
18
- visibility = ["//visibility:public" ],
19
- )
20
-
5
+ # TODO(davido): Remove manual merge of manifest file when this feature
6
+ # request is implemented: https://github.com/bazelbuild/bazel/issues/2009
7
+ genrule2 (
8
+ name = "%s-stamped" % name ,
9
+ stamp = 1 ,
10
+ srcs = [":%s" % name ],
11
+ cmd = " && " .join ([
12
+ "GEN_VERSION=$$(cat bazel-out/stable-status.txt | grep -w STABLE_BUILD_%s_LABEL | cut -d ' ' -f 2)" % workspace .upper (),
13
+ "cd $$TMP" ,
14
+ "unzip -q $$ROOT/$<" ,
15
+ "echo \" Implementation-Version: $$GEN_VERSION\n $$(cat META-INF/MANIFEST.MF)\" > META-INF/MANIFEST.MF" ,
16
+ "zip -qr $$ROOT/$@ ." ,
17
+ ]) ,
18
+ outs = ["%s-stamped.jar" % name ],
19
+ visibility = [ "//visibility:public" ],
20
+ )
You can’t perform that action at this time.
0 commit comments