mirror of https://github.com/k3s-io/k3s
workspace mirror: add trailing newline to urls list
parent
8bf47d7237
commit
b9efd1f467
|
@ -39,7 +39,11 @@ def export_urls_impl(repo_ctx):
|
|||
repo_ctx.file(repo_ctx.path("BUILD.bazel"), """
|
||||
exports_files(glob(["**"]), visibility=["//visibility:public"])
|
||||
""")
|
||||
repo_ctx.file(repo_ctx.path("urls.txt"), content = "\n".join(repo_ctx.attr.urls))
|
||||
repo_ctx.file(
|
||||
repo_ctx.path("urls.txt"),
|
||||
# Add a trailing newline, since the "while read" loop needs it
|
||||
content = ("\n".join(repo_ctx.attr.urls) + "\n"),
|
||||
)
|
||||
|
||||
_export_urls = repository_rule(
|
||||
attrs = {
|
||||
|
|
|
@ -19,7 +19,7 @@ set -o nounset
|
|||
set -o pipefail
|
||||
|
||||
if [[ $# -ne 1 ]]; then
|
||||
echo 'use "bazel run //build:update-mirror"'
|
||||
echo 'use "bazel run //hack:update-mirror"'
|
||||
echo "(usage: $0 <file with list of URLs to mirror>)"
|
||||
exit 1
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue