rules_zapp/example/WORKSPACE
Reid 'arrdem' McKenzie edd7dd0103 Get an interpreter from toolchains
This patch teaches Zapp how to read Python toolchains to get an
interpreter, rather than hard-coding "python3" somewhat opaquely. This
enables the use of hermetic or otherwise selected interpreters.

Fixes #2
2021-08-29 21:10:34 -06:00

51 lines
1.3 KiB
Python

# WORKSPACE
workspace(
name = "zapp_examples",
)
load(
"@bazel_tools//tools/build_defs/repo:git.bzl",
"git_repository",
)
####################################################################################################
# Skylib
####################################################################################################
git_repository(
name = "bazel_skylib",
remote = "https://github.com/bazelbuild/bazel-skylib.git",
tag = "1.0.3",
)
load("@bazel_skylib//:workspace.bzl", "bazel_skylib_workspace")
bazel_skylib_workspace()
####################################################################################################
# rules_python
####################################################################################################
git_repository(
name = "rules_python",
remote = "https://github.com/bazelbuild/rules_python.git",
tag = "0.3.0",
)
register_toolchains("//:python3_toolchain")
# git_repository(
# name = "rules_zapp",
# remote = "https://github.com/arrdem/rules_zapp.git",
# tag = "0.1.1",
# # branch = "trunk",
# )
local_repository(
name = "rules_zapp",
path = "../",
)
load("@rules_python//python:pip.bzl", "pip_install")
pip_install(
name = "my_deps",
requirements = "//:requirements.txt",
)