annotate gui_ze/gui_ze.bzl @ 12:de54585a40f1

Adding bun and node modules.
author June Park <parkjune1995@gmail.com>
date Thu, 02 Oct 2025 14:39:48 -0700
parents 98f96b8032e5
children 2b9e75756825
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
8
98f96b8032e5 [GuiZe] Creating custom bazel rule to deploy to github easily.
June Park <parkjune1995@gmail.com>
parents:
diff changeset
1 def _foo_impl(ctx):
12
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
2 out = ctx.actions.declare_file(ctx.label.name)
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
3 ctx.actions.write(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
4 output = out,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
5 content = "Hello!\n",
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
6 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
7 return [DefaultInfo(files = depset([out]))]
8
98f96b8032e5 [GuiZe] Creating custom bazel rule to deploy to github easily.
June Park <parkjune1995@gmail.com>
parents:
diff changeset
8
98f96b8032e5 [GuiZe] Creating custom bazel rule to deploy to github easily.
June Park <parkjune1995@gmail.com>
parents:
diff changeset
9 foo_binary = rule(
98f96b8032e5 [GuiZe] Creating custom bazel rule to deploy to github easily.
June Park <parkjune1995@gmail.com>
parents:
diff changeset
10 implementation = _foo_impl,
98f96b8032e5 [GuiZe] Creating custom bazel rule to deploy to github easily.
June Park <parkjune1995@gmail.com>
parents:
diff changeset
11 )
98f96b8032e5 [GuiZe] Creating custom bazel rule to deploy to github easily.
June Park <parkjune1995@gmail.com>
parents:
diff changeset
12
12
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
13
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
14 def _bundle_impl(ctx):
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
15 """
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
16 bundle binary target into a folder which can later be used to make a post to github easily.
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
17 """
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
18 binary_target = ctx.attr.binary
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
19 binary = binary_target[DefaultInfo].files.to_list()[0] # First files are binary
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
20 runfiles_files = binary_target[DefaultInfo].default_runfiles.files.to_list()
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
21
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
22 # Name as output directory
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
23 out_dir = ctx.actions.declare_directory(ctx.label.name)
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
24
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
25 copy_cmd = []
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
26 copy_cmd.append("mkdir -p {}".format(out_dir.path))
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
27
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
28 for f in runfiles_files:
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
29 if f.path == binary.path:
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
30 continue
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
31 # Remove the first folder (output) and last file (actaul files that needed to be copied)
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
32 paths = "/".join(f.path.split("/")[:-1])
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
33 full_path = "{}/{}".format(out_dir.path, paths)
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
34 copy_cmd.append("mkdir -p {}".format(full_path))
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
35 copy_cmd.append("cp {} {}".format(f.path, full_path))
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
36
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
37 copy_cmd.append("cp {} {}".format(binary.path, out_dir.path))
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
38
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
39 ctx.actions.run_shell(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
40 inputs = runfiles_files,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
41 outputs = [out_dir],
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
42 command = " && ".join(copy_cmd),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
43 progress_message = "Bundling {}".format(ctx.label.name),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
44 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
45
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
46 print("[INFO] See {}".format(out_dir.path))
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
47
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
48 return [DefaultInfo(files = depset([out_dir]))]
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
49
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
50 bundle = rule(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
51 implementation = _bundle_impl,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
52 attrs = {
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
53 "binary": attr.label(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
54 doc = "The cc_binary target to bundle",
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
55 providers = [DefaultInfo],
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
56 ),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
57 },
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
58 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
59
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
60
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
61 def _bun_binary_impl(ctx):
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
62 out = ctx.actions.declare_file("bun")
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
63 ctx.actions.run_shell(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
64 inputs = ctx.files.srcs,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
65 outputs = [out],
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
66 command = """
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
67 mkdir -p {outdir}
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
68 unzip -j {src} {inner} -d {outdir}
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
69 chmod +x {outdir}/bun
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
70 mv {outdir}/bun {out}
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
71 """.format(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
72 outdir = out.dirname,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
73 src = ctx.files.srcs[0].path,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
74 inner = "bun-darwin-aarch64/bun",
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
75 out = out.path,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
76 ),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
77 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
78 return DefaultInfo(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
79 files = depset([out]),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
80 executable = out,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
81 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
82
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
83 bun_binary = rule(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
84 implementation = _bun_binary_impl,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
85 attrs = {
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
86 "srcs": attr.label_list(allow_files=True),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
87 },
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
88 executable = True,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
89 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
90
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
91 def _bun_build_impl(ctx):
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
92 out = ctx.actions.declare_file(ctx.label.name + ".js")
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
93 inputs = [ctx.file.src] + ctx.files.data
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
94
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
95 ctx.actions.run_shell(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
96 inputs = inputs,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
97 outputs = [out],
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
98 tools = [ctx.executable._bun] + inputs,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
99 command = """
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
100 cp -r third_party/bun/** . \
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
101 && cp -r playground/** . \
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
102 && {} build {} --outfile {}
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
103 """.format(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
104 ctx.executable._bun.path,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
105 ctx.file.src.path.split("/")[-1],
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
106 out.path,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
107 ),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
108 progress_message = "Bundling {} with Bun!\n\n".format(ctx.file.src.path),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
109 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
110
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
111 return [DefaultInfo(files=depset([out]))]
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
112
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
113 bun_build = rule(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
114 implementation = _bun_build_impl,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
115 attrs = {
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
116 "src": attr.label(allow_single_file = [".ts", ".tsx", ".js", ".jsx"]),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
117 "_bun": attr.label(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
118 default = Label("//third_party/bun:bun"),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
119 executable = True,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
120 cfg = "exec",
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
121 ),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
122 "data": attr.label_list(allow_files=True),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
123 },
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
124 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
125
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
126 def _move_files_into_dir_impl(ctx):
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
127 srcs = ctx.files.srcs
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
128 for src in srcs:
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
129 out = ctx.actions.declare_file(ctx.attr.dest + "/" + src.basename)
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
130 ctx.actions.symlink(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
131 output = out,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
132 target_file = src,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
133 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
134 return [DefaultInfo(files = depset([out]))]
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
135
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
136 move_files_into_dir = rule(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
137 implementation = _move_files_into_dir_impl,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
138 attrs = {
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
139 "srcs": attr.label_list(allow_files=True),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
140 "dest": attr.string(),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
141 },
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
142 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
143
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
144 def _move_to_directory_impl(ctx):
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
145 srcs = ctx.files.data
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
146 res = []
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
147 for src in srcs:
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
148 true = "/".join(src.path.split("/")[2:])
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
149 path = ctx.attr.dest + "/" + true if ctx.attr.dest != "" else true
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
150 out = ctx.actions.declare_file(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
151 path
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
152 );
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
153 ctx.actions.symlink(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
154 output = out,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
155 target_file = src,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
156 )
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
157 res.append(out)
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
158 return [DefaultInfo(files = depset(res))]
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
159
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
160 move_to_directory = rule(
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
161 implementation = _move_to_directory_impl,
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
162 attrs = {
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
163 "data": attr.label_list(allow_files=True),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
164 "dest": attr.string(),
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
165 },
de54585a40f1 Adding bun and node modules.
June Park <parkjune1995@gmail.com>
parents: 8
diff changeset
166 )