| load("@npm//less:index.bzl", "lessc") |
| load("@npm//stylus:index.bzl", "stylus") |
| |
| package(default_visibility = ["//:__pkg__"]) |
| |
| lessc( |
| name = "base", |
| outs = [ |
| "base.css", |
| "base.css.map", |
| ], |
| args = [ |
| "$(location base.less)", |
| # Output paths must use $(location) since Bazel puts them in a platform-dependent output directory |
| "$(location base.css)", |
| "--silent", |
| "--source-map", |
| ], |
| data = [ |
| "base.less", |
| "variables.less", |
| ], |
| ) |
| |
| stylus( |
| name = "styles", |
| outs = [ |
| "test.css", |
| "test.css.map", |
| ], |
| args = [ |
| "$(location test.styl)", |
| "--out", |
| # Output paths must use $(location) since Bazel puts them in a platform-dependent output directory |
| "$(location test.css)", |
| "--compress", |
| "--sourcemap", |
| ], |
| data = ["test.styl"], |
| ) |