Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Perl rules

module(
name = "rules_perl",
version = "0.1.0",
version = "0.0.0",
)

bazel_dep(name = "platforms", version = "0.0.10")
Expand Down
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ The Perl Toolchain utilizes the [relocatable perl](https://github.com/skaji/relo

To import rules_perl in your project, you first need to add it to your `WORKSPACE` file:


If you are still using `WORKSPACE` to manage your dependencies:

```python
git_repository(
name = "rules_perl",
Expand Down Expand Up @@ -46,7 +49,7 @@ This repository provides a hermetic [Strawberry Perl](https://strawberryperl.com

## Using Perl Modules

This is the first stab at getting a more mature set of Perl rules for Bazel. Currenlty it is a manual process and, hopefully, it will be a map for automation later on.
This is the first stab at getting a more mature set of Perl rules for Bazel. Currently, it is a manual process and, hopefully, it will be a map for automation later on.

### Current Steps

Expand Down
14 changes: 12 additions & 2 deletions perl/extensions.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,25 @@

load("@rules_perl//perl:deps.bzl", "perl_repos", "perl_rules_dev_dependencies")

def _perl_repositories(_module_ctx):
def _perl_repositories(module_ctx):
perl_repos()
return module_ctx.extension_metadata(
reproducible = True,
root_module_direct_deps = "all",
root_module_direct_dev_deps = [],
)

perl_repositories = module_extension(
implementation = _perl_repositories,
)

def _perl_rules_dev_dependencies(_module_ctx):
def _perl_rules_dev_dependencies(module_ctx):
perl_rules_dev_dependencies()
return module_ctx.extension_metadata(
reproducible = True,
root_module_direct_deps = [],
root_module_direct_dev_deps = "all",
)

perl_dev_repositories = module_extension(
implementation = _perl_rules_dev_dependencies,
Expand Down