forked from MobileNativeFoundation/rules_xcodeproj
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBUILD
68 lines (58 loc) · 1.26 KB
/
BUILD
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
load("@buildifier_prebuilt//:rules.bzl", "buildifier")
# Release
# TODO: Use rules_pkg
genrule(
name = "release",
srcs = [":release_files"],
outs = [
"release.tar.gz",
"release.tar.gz.sha256",
],
cmd = """\
set -euo pipefail
outs=($(OUTS))
COPYFILE_DISABLE=1 tar czvfh "$${outs[0]}" \
--exclude .DS_Store \
--exclude **/*.xcodeproj \
--exclude ^bazel-out/ \
--exclude ^external/ \
*
shasum -a 256 "$${outs[0]}" > "$${outs[1]}"
""",
tags = ["manual"],
)
filegroup(
name = "release_files",
srcs = [
"LICENSE",
"//third_party:release_files",
"//tools:release_files",
"//xcodeproj:release_files",
],
)
# Buildifier
_BUILDIFIER_EXCLUDE_PATTERNS = [
"./.git/*",
"**/bazel-output-base/*",
"**/*.xcodeproj/*",
]
_BUILDIFIER_WARNINGS = [
"all",
"-native-cc",
]
buildifier(
name = "buildifier.check",
exclude_patterns = _BUILDIFIER_EXCLUDE_PATTERNS,
lint_mode = "warn",
lint_warnings = _BUILDIFIER_WARNINGS,
mode = "diff",
tags = ["manual"],
)
buildifier(
name = "buildifier.fix",
exclude_patterns = _BUILDIFIER_EXCLUDE_PATTERNS,
lint_mode = "fix",
lint_warnings = _BUILDIFIER_WARNINGS,
mode = "fix",
tags = ["manual"],
)