2018-03-12 11:12:38 -07:00
|
|
|
workspace(name = "angular_material")
|
2017-11-15 11:47:56 -08:00
|
|
|
|
2018-10-04 20:52:59 +02:00
|
|
|
# Add NodeJS rules (explicitly used for sass bundle rules)
|
2018-03-22 14:21:04 -07:00
|
|
|
http_archive(
|
2017-11-15 11:47:56 -08:00
|
|
|
name = "build_bazel_rules_nodejs",
|
2018-10-04 20:52:59 +02:00
|
|
|
url = "https://github.com/bazelbuild/rules_nodejs/archive/0.14.2.zip",
|
|
|
|
|
strip_prefix = "rules_nodejs-0.14.2",
|
|
|
|
|
sha256 = "af481421c9e74f754a693a8bf5e9409484e38cf7be6f73f85879bdc7ed1b1d82",
|
2017-11-15 11:47:56 -08:00
|
|
|
)
|
|
|
|
|
|
2018-09-27 16:44:49 +02:00
|
|
|
# Add TypeScript rules
|
|
|
|
|
http_archive(
|
|
|
|
|
name = "build_bazel_rules_typescript",
|
2018-10-04 20:52:59 +02:00
|
|
|
url = "https://github.com/bazelbuild/rules_typescript/archive/0.19.1.zip",
|
|
|
|
|
strip_prefix = "rules_typescript-0.19.1",
|
|
|
|
|
sha256 = "91a03623a03a463ffd62cea3f7a384c2f298af6438d5d153fc4d69aa5665b53d",
|
2018-09-27 16:44:49 +02:00
|
|
|
)
|
2018-03-22 14:21:04 -07:00
|
|
|
|
2018-09-27 16:44:49 +02:00
|
|
|
# Fetch transient dependencies of the TypeScript bazel rules.
|
|
|
|
|
load("@build_bazel_rules_typescript//:package.bzl", "rules_typescript_dependencies")
|
|
|
|
|
rules_typescript_dependencies()
|
2017-11-15 11:47:56 -08:00
|
|
|
|
|
|
|
|
# Add sass rules
|
2018-06-06 22:54:28 -07:00
|
|
|
http_archive(
|
2017-11-15 11:47:56 -08:00
|
|
|
name = "io_bazel_rules_sass",
|
2018-09-27 16:44:49 +02:00
|
|
|
url = "https://github.com/bazelbuild/rules_sass/archive/1.13.4.zip",
|
|
|
|
|
strip_prefix = "rules_sass-1.13.4",
|
|
|
|
|
sha256 = "5ddde0d3df96978fa537f76e766538c031dee4d29f91a895f4b1345b5e3f9b16",
|
2017-11-15 11:47:56 -08:00
|
|
|
)
|
|
|
|
|
|
2018-06-06 22:54:28 -07:00
|
|
|
load("@io_bazel_rules_sass//sass:sass_repositories.bzl", "sass_repositories")
|
2017-11-15 11:47:56 -08:00
|
|
|
sass_repositories()
|
|
|
|
|
|
2018-09-27 16:44:49 +02:00
|
|
|
# NOTE: this rule installs nodejs, npm, and yarn, but does NOT install
|
|
|
|
|
# your npm dependencies. You must still run the package manager.
|
2018-10-04 20:52:59 +02:00
|
|
|
load("@build_bazel_rules_nodejs//:defs.bzl", "node_repositories", "npm_install")
|
2018-09-27 16:44:49 +02:00
|
|
|
node_repositories()
|
|
|
|
|
|
|
|
|
|
# Use Bazel managed node modules. See more below:
|
|
|
|
|
# https://github.com/bazelbuild/rules_nodejs#bazel-managed-vs-self-managed-dependencies
|
|
|
|
|
npm_install(
|
|
|
|
|
name = "npm",
|
|
|
|
|
package_json = "//:package.json",
|
|
|
|
|
package_lock_json = "//:package-lock.json",
|
2017-11-15 11:47:56 -08:00
|
|
|
)
|
|
|
|
|
|
2018-01-08 18:30:14 +01:00
|
|
|
# Setup TypeScript Bazel workspace
|
2018-02-09 23:19:44 +01:00
|
|
|
load("@build_bazel_rules_typescript//:defs.bzl", "ts_setup_workspace")
|
2018-01-08 18:30:14 +01:00
|
|
|
ts_setup_workspace()
|
2017-12-07 14:34:09 -08:00
|
|
|
|
2017-11-15 11:47:56 -08:00
|
|
|
# Add Angular rules
|
|
|
|
|
local_repository(
|
|
|
|
|
name = "angular",
|
|
|
|
|
path = "node_modules/@angular/bazel",
|
|
|
|
|
)
|
2017-12-07 14:34:09 -08:00
|
|
|
|
2017-12-19 17:12:39 -08:00
|
|
|
# Add rxjs
|
2017-12-07 14:34:09 -08:00
|
|
|
local_repository(
|
|
|
|
|
name = "rxjs",
|
|
|
|
|
path = "node_modules/rxjs/src",
|
|
|
|
|
)
|