| # Copyright © 2024 Apple Inc. and the Pkl project authors. All rights reserved. |
| # |
| # Licensed under the Apache License, Version 2.0 (the "License"); |
| # you may not use this file except in compliance with the License. |
| # You may obtain a copy of the License at |
| # |
| # https://www.apache.org/licenses/LICENSE-2.0 |
| # |
| # Unless required by applicable law or agreed to in writing, software |
| # distributed under the License is distributed on an "AS IS" BASIS, |
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| # See the License for the specific language governing permissions and |
| # limitations under the License. |
| """apple/rules_pkl""" |
| |
| module( |
| name = "rules_pkl", |
| version = "0.5.0", |
| bazel_compatibility = [">=7.0.0"], |
| compatibility_level = 1, |
| ) |
| |
| bazel_dep(name = "aspect_bazel_lib", version = "2.13.0") |
| bazel_dep(name = "bazel_skylib", version = "1.7.1") |
| bazel_dep(name = "platforms", version = "0.0.10") |
| bazel_dep(name = "rules_java", version = "8.6.1") |
| bazel_dep(name = "rules_jvm_external", version = "6.6") |
| |
| bazel_dep(name = "buildifier_prebuilt", version = "7.3.1", dev_dependency = True) |
| bazel_dep(name = "gazelle", version = "0.36.0", dev_dependency = True, repo_name = "bazel_gazelle") |
| bazel_dep(name = "rules_bazel_integration_test", version = "0.29.0", dev_dependency = True) |
| bazel_dep(name = "stardoc", version = "0.7.2", dev_dependency = True) |
| |
| pkl = use_extension("//pkl/extensions:pkl.bzl", "pkl") |
| use_repo( |
| pkl, |
| "pkl-cli-linux-aarch64", |
| "pkl-cli-linux-amd64", |
| "pkl-cli-macos-aarch64", |
| "pkl-cli-macos-amd64", |
| ) |
| |
| register_toolchains( |
| "@rules_pkl//pkl:pkl_toolchain_codegen_java", |
| "@rules_pkl//pkl:pkl_toolchain_linux_aarch64", |
| "@rules_pkl//pkl:pkl_toolchain_linux_amd64", |
| "@rules_pkl//pkl:pkl_toolchain_macos_aarch64", |
| "@rules_pkl//pkl:pkl_toolchain_macos_amd64", |
| ) |
| |
| maven = use_extension("@rules_jvm_external//:extensions.bzl", "maven") |
| maven.install( |
| name = "rules_pkl_deps", |
| artifacts = [ |
| "org.pkl-lang:pkl-tools:0.28.1", |
| "org.jetbrains.kotlin:kotlin-stdlib:2.0.21", |
| "com.google.code.gson:gson:2.12.1", |
| "org.junit.vintage:junit-vintage-engine:5.7.0", |
| ], |
| lock_file = "//pkl/private:pkl_deps_install.json", |
| repositories = [ |
| "https://repo1.maven.org/maven2/", |
| ], |
| ) |
| use_repo( |
| maven, |
| "rules_pkl_deps", |
| "unpinned_rules_pkl_deps", |
| ) |
| |
| bazel_binaries = use_extension( |
| "@rules_bazel_integration_test//:extensions.bzl", |
| "bazel_binaries", |
| dev_dependency = True, |
| ) |
| bazel_binaries.download(version = "7.4.1") |
| use_repo( |
| bazel_binaries, |
| "bazel_binaries", |
| "bazel_binaries_bazelisk", |
| "build_bazel_bazel_7_4_1", |
| ) |