Skip to content

Commit

Permalink
chore: update to rules_js 0.10.0 (#40)
Browse files Browse the repository at this point in the history
  • Loading branch information
gregmagolan authored Jun 3, 2022
1 parent 70552b4 commit d73536a
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 16 deletions.
14 changes: 7 additions & 7 deletions swc/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
load("@aspect_bazel_lib//lib:write_source_files.bzl", "write_source_files")
load("@aspect_rules_js//js:defs.bzl", "link_js_package")
load("@aspect_rules_js//npm:defs.bzl", "link_npm_package")
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
load("@swc_cli//:defs.bzl", "link_js_packages")
load("@swc_cli//:defs.bzl", "link_all_npm_packages")
load("@swc_cli//swc/@swc/cli:package_json.bzl", swc_cli_bin = "bin")

write_source_files(
Expand All @@ -11,14 +11,14 @@ write_source_files(
},
)

link_js_package(
name = "link_core",
link_all_npm_packages(name = "node_modules")

link_npm_package(
name = "node_modules/@swc/core",
src = "@npm__at_swc_core__1.2.185//:jsp",
root_package = "swc",
)

link_js_packages()

# For stardoc to reference the files
exports_files(["defs.bzl"])

Expand All @@ -45,7 +45,7 @@ bzl_library(
swc_cli_bin.swc_binary(
name = "cli",
data = [
":link_core",
":node_modules/@swc/core",
],
visibility = ["//visibility:public"],
)
Expand Down
4 changes: 2 additions & 2 deletions swc/cli_repositories.bzl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
"@generated by @aspect_rules_js//js/private:translate_pnpm_lock.bzl from pnpm lock file @aspect_rules_swc@aspect_rules_swc//swc:pnpm-lock.yaml"
"@generated by @aspect_rules_js//npm/private:translate_pnpm_lock.bzl from pnpm lock file @aspect_rules_swc@aspect_rules_swc//swc:pnpm-lock.yaml"

load("@aspect_rules_js//js:npm_import.bzl", "npm_import")
load("@aspect_rules_js//npm:npm_import.bzl", "npm_import")

def npm_repositories():
"Generated npm_import repository rules corresponding to npm packages in @aspect_rules_swc@aspect_rules_swc//swc:pnpm-lock.yaml"
Expand Down
12 changes: 6 additions & 6 deletions swc/dependencies.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,15 @@ def rules_swc_dependencies():
maybe(
http_archive,
name = "aspect_bazel_lib",
sha256 = "a8b47eeaf3c1bd41c4f4b633ef4c959daf83fdee343379495098b50571d4b3b8",
strip_prefix = "bazel-lib-0.11.1",
url = "https://github.com/aspect-build/bazel-lib/archive/refs/tags/v0.11.1.tar.gz",
sha256 = "91aa7356b22ecdb87dcf5f1cc8a6a147e23a1ef425221bab75e5f857cd6b2716",
strip_prefix = "bazel-lib-0.12.1",
url = "https://github.com/aspect-build/bazel-lib/archive/refs/tags/v0.12.1.tar.gz",
)

maybe(
http_archive,
name = "aspect_rules_js",
sha256 = "f01010e1f6bd49a8da6f7350c60992b7eb2eb62058cfe7aa6abd9e416bc2158b",
strip_prefix = "rules_js-0.9.1",
url = "https://github.com/aspect-build/rules_js/archive/refs/tags/v0.9.1.tar.gz",
sha256 = "2db66bedabc30f2dfa87bd4845e42b0dbc80fa9344d2dfbaa2685cdced2f1e03",
strip_prefix = "rules_js-0.10.0",
url = "https://github.com/aspect-build/rules_js/archive/refs/tags/v0.10.0.tar.gz",
)
2 changes: 1 addition & 1 deletion swc/repositories.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ These are needed for local dev, and users must install them as well.
See https://docs.bazel.build/versions/main/skylark/deploying.html#dependencies
"""

load("@aspect_rules_js//js:npm_import.bzl", "npm_import", "translate_pnpm_lock")
load("@aspect_rules_js//npm:npm_import.bzl", "npm_import", "translate_pnpm_lock")
load("//swc/private:toolchains_repo.bzl", "PLATFORMS", "toolchains_repo")
load("//swc/private:versions.bzl", "TOOL_VERSIONS")
load("//swc:cli_repositories.bzl", _cli_repositories = "npm_repositories")
Expand Down

0 comments on commit d73536a

Please sign in to comment.