-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathWORKSPACE
51 lines (35 loc) · 1.24 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
workspace(name = "monorepo_tools")
load("@bazel_tools//tools/build_defs/repo:git.bzl", "git_repository")
# Sanity checks
git_repository(
name = "bazel_skylib",
remote = "https://github.com/bazelbuild/bazel-skylib",
tag = "1.0.2",
)
load("@bazel_skylib//lib:versions.bzl", "versions")
versions.check("0.29.0")
git_repository(
name = "rules_python",
commit = "94677401bc56ed5d756f50b441a6a5c7f735a6d4",
remote = "https://github.com/bazelbuild/rules_python.git",
)
# This call should always be present.
load("@rules_python//python:repositories.bzl", "py_repositories")
py_repositories()
# This one is only needed if you're using the packaging rules.
load("@rules_python//python:pip.bzl", "pip_repositories")
pip_repositories()
load("@rules_python//python:pip.bzl", "pip_import")
# This rule translates the specified requirements.txt into
# @my_deps//:requirements.bzl, which itself exposes a pip_install method.
pip_import(
name = "py_deps",
requirements = "//:requirements.txt",
)
# Load the pip_install symbol for my_deps, and create the dependencies'
# repositories.
load("@py_deps//:requirements.bzl", "pip_install")
pip_install()
# Linting
load("//internal:format.bzl", "format_repositories")
format_repositories()