Skip to content

Commit 445fbf8

Browse files
refactor(devtools): bring the angular devtools directory into the root bazel workspace
Previously devtools used a nested workspace for its bazel configurations. This meant framework dependencies were consumed via npm. Now devtools is part of the root bazel directory that all other files in this codebase fall under. This allows us to build devtools using local angular packages, removing the need to consume these dependencies with npn. This is useful because we no longer have to update these dependencies with an automated tool like renovate, and our CI tests will always run against the most up to date framework packages.
1 parent 7ed57f2 commit 445fbf8

File tree

190 files changed

+3282
-15979
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

190 files changed

+3282
-15979
lines changed

.bazelignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ dist
88
aio/content
99
aio/node_modules
1010
aio/tools/examples/shared/node_modules
11-
devtools/node_modules
1211
packages/bazel/node_modules
1312

1413
# All integration test node_modules folders

.circleci/config.yml

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -277,6 +277,7 @@ jobs:
277277
paths:
278278
- ./ng
279279
- ./bazel_repository_cache
280+
- .cache/Cypress
280281

281282
lint:
282283
executor: default-executor
@@ -312,7 +313,7 @@ jobs:
312313
# We need to explicitly specify the --symlink_prefix option because otherwise we would
313314
# not be able to easily find the output bin directory when uploading artifacts for size
314315
# measurements.
315-
command: yarn test --symlink_prefix=dist/ -- //...
316+
command: yarn test:ci
316317
no_output_timeout: 20m
317318
# Publish bundle artifacts which will be used to calculate the size change. **Note**: Make
318319
# sure that the size plugin from the Angular robot fetches the artifacts from this CircleCI
@@ -738,18 +739,15 @@ jobs:
738739
steps:
739740
- custom_attach_workspace
740741
- init_environment
741-
- run:
742-
name: Install DevTools dependencies
743-
command: yarn --cwd devtools install --frozen-lockfile --non-interactive --cache-folder ~/.cache/yarn
744742
- run:
745743
name: Run unit tests
746-
command: yarn --cwd devtools test:ci
744+
command: yarn devtools:test
747745
- run:
748746
name: Test production build
749-
command: yarn --cwd devtools build:chrome:ci
747+
command: yarn devtools:build:chrome
750748
- run:
751749
name: Run e2e tests
752-
command: yarn --cwd devtools cy:ci
750+
command: yarn devtools:e2e
753751

754752
workflows:
755753
version: 2

WORKSPACE

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,17 @@ cldr_data_repository(
7979
},
8080
)
8181

82-
local_repository(
83-
name = "devtools",
84-
path = "devtools",
82+
# sass rules
83+
http_archive(
84+
name = "io_bazel_rules_sass",
85+
sha256 = "435efe759f1c8baffadc320ecc1830454da181fa790aa83bb4326f07e903a0f4",
86+
strip_prefix = "rules_sass-1.41.0",
87+
urls = [
88+
"https://github.com/bazelbuild/rules_sass/archive/1.41.0.zip",
89+
],
8590
)
91+
92+
# Setup the rules_sass toolchain
93+
load("@io_bazel_rules_sass//sass:sass_repositories.bzl", "sass_repositories")
94+
95+
sass_repositories()

devtools/.bazelignore

Lines changed: 0 additions & 16 deletions
This file was deleted.

devtools/.bazelrc

Lines changed: 0 additions & 6 deletions
This file was deleted.

devtools/.bazelversion

Lines changed: 0 additions & 1 deletion
This file was deleted.

devtools/.browserslistrc

Lines changed: 0 additions & 12 deletions
This file was deleted.

devtools/.npmrc

Lines changed: 0 additions & 1 deletion
This file was deleted.

devtools/BUILD.bazel

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,6 @@ ts_config(
1111
name = "tsconfig_spec",
1212
src = "tsconfig.spec.json",
1313
deps = [
14-
"//:tsconfig.json",
14+
"//devtools:tsconfig.json",
1515
],
1616
)

devtools/CODE_OF_CONDUCT.md

Lines changed: 0 additions & 12 deletions
This file was deleted.

0 commit comments

Comments
 (0)