@@ -55,49 +55,20 @@ gazelle_dependencies()
55
55
56
56
# Remaining setup is for rules_python.
57
57
58
- # You do not want to use the following command when you are using a WORKSPACE file
59
- # that is outside of rules_python repository.
60
- # This command allows targets from a local directory to be bound.
61
- # Which allows bazel to use targets defined in base rules_python directory.
62
- # If you are using this example outside of the rules_python git repo,
63
- # use the http_archive command that is commented out below.
64
- # https://bazel.build/reference/be/workspace#local_repository
58
+ # DON'T COPY_PASTE THIS.
59
+ # Our example uses `local_repository` to point to the HEAD version of rules_python.
60
+ # Users should instead use the installation instructions from the release they use.
61
+ # See https://github.com/bazelbuild/rules_python/releases
65
62
local_repository (
66
63
name = "rules_python" ,
67
64
path = "../.." ,
68
65
)
69
66
70
- # When not using this example in the rules_python git repo you would load the python
71
- # ruleset using the following StarLark.
72
- # See https://github.com/bazelbuild/rules_python#getting-started for the latest
73
- # ruleset version.
74
- #
75
- # The following StarLark would replace the `local_repository` rule mentioned above.
76
- #
77
- # load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
78
- # http_archive(
79
- # name = "rules_python",
80
- # sha256 = "497ca47374f48c8b067d786b512ac10a276211810f4a580178ee9b9ad139323a",
81
- # strip_prefix = "rules_python-0.16.1",
82
- # url = "https://github.com/bazelbuild/rules_python/archive/refs/tags/0.16.1.tar.gz",
83
- # )
84
-
85
- # We import the repository-local rules_python_gazelle_plugin version in order to
86
- # be able to test development changes to the plugin.
87
67
local_repository (
88
68
name = "rules_python_gazelle_plugin" ,
89
69
path = "../../gazelle" ,
90
70
)
91
71
92
- # When loading the gazelle plugin outside this repo, use the http_archive rule as follows:
93
- #
94
- #http_archive(
95
- # name = "rules_python_gazelle_plugin",
96
- # sha256 = "497ca47374f48c8b067d786b512ac10a276211810f4a580178ee9b9ad139323a",
97
- # strip_prefix = "rules_python-0.16.1/gazelle",
98
- # url = "https://github.com/bazelbuild/rules_python/archive/refs/tags/0.16.1.tar.gz",
99
- #)
100
-
101
72
# Next we load the toolchain from rules_python.
102
73
load ("@rules_python//python:repositories.bzl" , "python_register_toolchains" )
103
74
0 commit comments