forked from ckaestne/toxicity-detector
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathWORKSPACE
106 lines (82 loc) · 2.83 KB
/
WORKSPACE
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
############
# For python
############
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "rules_python",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.1.0/rules_python-0.1.0.tar.gz",
sha256 = "b6d46438523a3ec0f3cead544190ee13223a52f6a6765a29eae7b7cc24cc83a0",
)
load("@rules_python//python:pip.bzl", "pip_install")
# Create a central repo that knows about the dependencies needed for
# requirements.txt.
pip_install(
name = "deps",
requirements = "//:requirements.txt",
)
#######
# for R
#######
http_archive(
name = "com_grail_rules_r",
strip_prefix = "rules_r-master",
urls = ["https://github.com/grailbio/rules_r/archive/master.tar.gz"],
)
load("@com_grail_rules_r//R:dependencies.bzl", "r_register_toolchains", "r_rules_dependencies")
r_rules_dependencies()
r_register_toolchains()
# R packages with standard sources.
load("@com_grail_rules_r//R:repositories.bzl", "r_repository", "r_repository_list")
r_repository_list(
name = "r_repositories_bzl",
package_list = "//:r_packages.csv",
remote_repos = {
"CREAB": "https://cloud.r-project.org",
},
)
# source: https://github.com/grailbio/rules_r/issues/38
load("@r_repositories_bzl//:r_repositories.bzl", "r_repositories")
r_repositories()
load("@com_grail_rules_r//R:dependencies.bzl", "r_coverage_dependencies")
r_coverage_dependencies()
# For python
############
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "rules_python",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.1.0/rules_python-0.1.0.tar.gz",
sha256 = "b6d46438523a3ec0f3cead544190ee13223a52f6a6765a29eae7b7cc24cc83a0",
)
load("@rules_python//python:pip.bzl", "pip_install")
# Create a central repo that knows about the dependencies needed for
# requirements.txt.
pip_install(
name = "deps",
requirements = "//:requirements.txt",
)
#######
# for R
#######
http_archive(
name = "com_grail_rules_r",
strip_prefix = "rules_r-master",
urls = ["https://github.com/grailbio/rules_r/archive/master.tar.gz"],
)
load("@com_grail_rules_r//R:dependencies.bzl", "r_register_toolchains", "r_rules_dependencies")
r_rules_dependencies()
r_register_toolchains()
# R packages with standard sources.
load("@com_grail_rules_r//R:repositories.bzl", "r_repository", "r_repository_list")
r_repository_list(
name = "r_repositories_bzl",
package_list = "//:r_packages.csv",
remote_repos = {
"BioCsoft": "https://bioconductor.org/packages/3.11/bioc",
"CREAB": "https://cloud.r-project.org",
},
)
# source: https://github.com/grailbio/rules_r/issues/38
load("@r_repositories_bzl//:r_repositories.bzl", "r_repositories")
r_repositories()
load("@com_grail_rules_r//R:dependencies.bzl", "r_coverage_dependencies")
r_coverage_dependencies()