Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add runfiles helpers needed for rules_js #3

Merged
merged 2 commits into from
Nov 10, 2021
Merged

feat: add runfiles helpers needed for rules_js #3

merged 2 commits into from
Nov 10, 2021

Conversation

alexeagle
Copy link
Collaborator

No description provided.

lib/utils.bzl Outdated
@@ -7,3 +7,62 @@ glob_directories = utils.glob_directories
path_to_workspace_root = utils.path_to_workspace_root
propagate_well_known_tags = utils.propagate_well_known_tags
to_label = utils.to_label

BATCH_RLOCATION_FUNCTION = r"""
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some suggestions:

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, that's where it came from. Making a windows specific file SGTM, we'll have other helpers to go there.
(I'm assuming we'll have to refactor the organization here a bit as we add more code)

It will only be used in downstream rules (rules_js to start). Testing is hard because we don't have windows executors on GitHub actions yet.

lib/utils.bzl Outdated
:: End of rlocation
"""

BASH_RLOCATION_FUNCTION = r"""
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same suggestions as above, but additionally:

  • Since there's not much commentary going on here, it's a little hard to understand what it's doing or why it's needed.
  • As this was copy pasted, would you be able to link to the source?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good suggestions thanks :)

@@ -42,6 +42,28 @@ def _relative_file(to_file, frm_file):
)
)

#
#
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: empty comment lines

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants