Skip to content

Commit

Permalink
fixup! Merge branch 'master' into feat/allow-anonymous-dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
chickenandpork committed Jan 6, 2025
1 parent cf91c3e commit 6911a89
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions synology/images.bzl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
def _images_impl(ctx):
out_collector = []
images_template = ctx.attr.images_template or "PACKAGE_ICON_{}.PNG".format(ctx.attr.name, "{}")
images_template = ctx.attr.images_template or "PACKAGE_ICON_{}.PNG"
for sz in ctx.attr.sizes:
target_name = images_template.format(sz)
target = ctx.actions.declare_file(target_name)
Expand Down Expand Up @@ -31,7 +31,7 @@ images = rule(
attrs = {
"sizes": attr.int_list(mandatory = False, default = [ 16, 24, 32, 48, 64, 72, 90, 120, 256 ], doc = "sizes to convert: use a list of ints, each of which is a desired size of a square bounding box."),
"src": attr.label(allow_single_file = True,mandatory = True, doc = "Initial source image to convert to various sizes."),
"images_template": attr.string(doc = "template for output files: use a string with a single {} that will be replaced with the size. The template should end with a suffix that determines the resulting format: .png, .jpg, etc. Note that Synology SPK packaging requires files of the form PACKAGE_ICON_<size>.PNG so changing this should ential converting the result back however desired for the payload of the SPK.", mandatory=False),
"images_template": attr.string(doc = "template for output files: use a string with a single {} that will be replaced with the size. The template should end with a suffix that determines the resulting format: .png, .jpg, .PNG, etc. Note that Synology SPK packaging requires files of the form PACKAGE_ICON_<size>.PNG so changing this should ential converting the result back however desired for the payload of the SPK.", mandatory=False),
"_resize": attr.label(
default=Label("//tools:resize"),
allow_single_file = True,
Expand Down

0 comments on commit 6911a89

Please sign in to comment.