Skip to content

Commit

Permalink
Using underscore for better readability
Browse files Browse the repository at this point in the history
  • Loading branch information
Buzz-Lightyear authored and Srinivas Muthu committed Oct 9, 2024
1 parent 9ca14e9 commit acb6e24
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/bzlmod/go_deps.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ def _repo_name(importpath):

def _encode_case(c):
"""Repo names end up as directory names, therefore we can't rely on case to distinguish importpaths that only differ in case"""
return "1" + c.lower() if c.isupper() else c
return "_" + c.lower() if c.isupper() else c

return "".join([_encode_case(c) if c.isalnum() else "_" for c in candidate_name.elems()])

Expand Down

0 comments on commit acb6e24

Please sign in to comment.