88 Commits

Author SHA1 Message Date
Hans Larsen
988835d024 feat(@angular-devkit/core): add a reuse JobStrategy
It allows a job to be reused if it's still running. This includes redirecting
the inputs to the new job.
2019-02-07 15:57:48 -08:00
Hans Larsen
4571197326 feat(@angular-devkit/core): add a fallback registry
Its get method goes through an array of registries and return the first
one found.
2019-02-07 15:57:48 -08:00
Hans Larsen
c461ed5960 feat(@angular-devkit/core): createJobFactory does not have to have options
It matches the other factories.
2019-02-07 15:57:48 -08:00
Hans Larsen
0e6384b8c4 fix(@angular-devkit/core): Properly subscribe/unsubscribe to observables
This has been a source of headaches when debugging the Architect jobs.
We keep all subscriptions now and unsubscribe them when the result is
done.
2019-02-07 15:57:48 -08:00
Hans Larsen
ef93ff8c78 refactor(@angular-devkit/core): Type JobHandlerContext properly
The input field is not an unknown JsonValue, the type is part of the
generic. It's validated by the scheduler.
2019-02-07 15:57:48 -08:00
Hans Larsen
ca31640505 refactor(@angular-devkit/core): change the job context scheduler to generic
That scheduler is really an any scheduler and would need to be typed
appropriately. There could be multiple schedulers that this job is
part of and it is impossible to ensure the scheduler is a more specific
type than unknown.

Note: This was wrongly typed before.

Context: JsonValue is the JSON equivalent of the unknown TS type.
2019-02-07 15:57:48 -08:00
Hans Larsen
5f73b17f7a refactor(@angular-devkit/core): add invalid argument exception class
Before we were (wrongly) using the InboundMessage exception class. This was
an oversight. This commit introduces a new InvalidArgument exception for this
special case.
2019-02-07 15:57:48 -08:00
Renovate Bot
be79d2a662 build: update chokidar to version 2.1.0 (#13599) 2019-02-07 08:24:05 -08:00
Renovate Bot
0496b514ad build: update ajv to version 6.8.1 (#13583) 2019-02-05 21:15:36 -08:00
Alan Agius
2ed1719eaa fix(@angular-devkit/core): remove colors for info messages
Rely on the terminal to provide the color for info messages

fixes #13497
2019-01-23 10:37:51 -08:00
Mikel Ward
7d15c5dd02 fix(@angular-devkit/core): Make default and info log messages use default colors
Previously, we set the color to white, which is (nearly) invisible on
terminals with a white background.

Fixes #13439.
2019-01-15 17:10:22 -08:00
Renovate Bot
83bbfec54b build: update ajv to version 6.7.0 2019-01-15 14:19:07 -08:00
Filipe Silva
5a847298e5 ci: use puppeteer 2019-01-14 12:57:13 -08:00
Filipe Silva
3a70eb73c4 ci: add windows buildkite 2019-01-14 12:57:13 -08:00
Renovate Bot
5a02a83d56 build: update ajv to version 6.6.2 2018-12-19 14:02:07 -08:00
Hans
a3a657f7e7 feat(@angular-devkit/core): Jobs API added
See the README for more details about usage.
2018-12-14 10:55:04 -08:00
Hans
c89a0420d5 feat(@angular-devkit/core): add DeepReadonly<> and Readwrite<> types
Readwrite removes readonly, while DeepReadonly recursively sets it. A ReadonlyArray
should be used if the type is an array, but that is too much of a change to our API
(JsonValue includes JsonArray but then we would need a ReadonlyJsonValue, and same
for object, which has deep roots in our API).

We should fix this in a further refactor at some point.
2018-12-14 10:55:04 -08:00
Hans
64781f64d7 refactor(@angular-devkit/core): UnknownException should still extend Base 2018-12-14 10:55:04 -08:00
Hans
3a28d4c142 feat(@angular-devkit/core): add a new JsonSchema type
A Schema is either an Object or a boolean. We could reduce JsonSchema scope further
by adding properties, but a schema is a really complex type so its not worth the
effort.
2018-12-14 10:55:04 -08:00
Hans
7567e8e6a0 feat(@angular-devkit/core): add next() to Logger
It allows to pass through LogEntry which was not possible before.
2018-12-14 10:55:04 -08:00
Hans
6bf80edf54 ci: add golden-api file for core/node
This is necessary as we introduce namespaces in jobs.
2018-12-14 10:55:04 -08:00
Michael O'Keefe
db0fc7759b feat(@angular/cli): Added support for multiselect list prompt (#13031)
* feat(@angular/cli): Added support for multiselect list prompt

* If multiselect option is true use the checkbox
   inquirer prompt type, otherwise use list.

* feat(@angular-devkit/core): Added support for multiselect list prompt

* Added multiselect to PromptDefinition interface and usages
2018-11-30 12:01:57 -08:00
Alan Agius
717b02f533 ci: add ts api guardian (#12010)
* refactor: fix `import` and `export` paths to work with classic resolution

`ts-api-guardian` only support classic module resolution which means that we need to specify `index` so that the resolution works.

* build: add `npm_package` to packages

* build: add ts-api-guardian to repo

* test: add api golden files

* refactor: use proper namespace instead of alias export

* refactor: use proper namspace einstead of alias export

* build: add `_golden_api` files

At the moment ts api guardian doesn't support aliased symbols as namespaces, this is a workaround to still have namespaced symbols in the final golden file.

* build: update angular archive for workspace

* test: fix reference to `TestHost` to use namespace

* refactor: create `fs` namespace instead of aliased export

* test: update api golden file for `@angular-devkit/core/node`
2018-11-30 11:53:54 -08:00
Alan Agius
a2aba2866c fix(@angular-devkit/core): handle drive only paths in windows
When normalized path will not have a trailing slash, and at the moment the RegExp for drive needs to match `\c\`

Fixes #12670
2018-11-14 12:42:13 -08:00
Alan Agius
bd4dc38359 refactor: use createConsoleLogger and remove duplicate code (#12787) 2018-11-08 10:30:41 -08:00
vikerman
df4ee8c491
fix(@angular-devkit/core): fix 'this' check (#12873) 2018-11-06 20:44:06 -08:00
Keen Yee Liau
d3e1149bdf build: add missing transitive deps for typescript (#12881)
add `strict_checks = False` for building inside Google.
2018-11-06 20:40:03 -08:00
Keen Yee Liau
db78228fc4 build: add external block for tsconfig in test targets (#12879) 2018-11-06 11:12:21 -08:00
Alan Agius
6e0b60df32 fix(@angular/cli): errors and warnings are hard to read in windows cmd (#12767)
* fix(@angular-devkit/core): errors and warnings are hard to read in windows cmd

Closes #12755

* fix(@angular/cli): errors and warnings are hard to read in windows cmd

Closes #12755
2018-10-31 21:03:03 -07:00
Keen Yee Liau
a3b05a0283 build: Use fine-grained node_module deps
This commit updates the BUILD files to specify fine-grained node_module deps
by replacing "@typings" comments with actual @npm node module.

Moved tools/bazel.rc -> .bazelrc

Removed "jasmine" typings from base tsconfig.json

Added @bazel/karma to devDependencies, needed for `ts_web_test`
2018-10-31 20:56:27 -07:00
Charles Lyding
2c6c398e6c refactor(@angular-devkit/core): allow promises for registry URI handlers 2018-10-31 14:53:56 -07:00
clydin
1747845dfa fix(@angular-devkit/core): make JSON schema required work with prompts (#12548) 2018-10-10 13:50:36 -07:00
Charles Lyding
9297eb5bf1 fix(@angular-devkit/core): record host should stat backing host 2018-10-05 15:01:46 -07:00
Hans
c13cbd467a refactor(@angular-devkit/core): add cache to normalize
And a benchmark to show the curve, more or less.
2018-10-03 16:31:27 -07:00
Charles Lyding
9a793494dc build: update rxjs to 6.3 2018-09-26 12:57:56 -04:00
Charles Lyding
1a3a117b48 refactor(@angular-devkit/core): adjust rxjs type usage
Required for upcoming upgraded to rxjs 6.3
2018-09-26 12:57:56 -04:00
Terry
b561657946 fix(@angular-devkit/core): fix cannot delete directory (#11574) 2018-09-25 16:51:46 -04:00
Hans
9648aa3ed9 feat(@angular-devkit/core): add enum support to getTypesOfSchema 2018-09-19 13:02:40 -07:00
Alan Agius
04ed3010b2 feat(@angular-devkit/core): createConsoleLogger now accepts 2 parameters to add custom stdout and stderr 2018-09-18 11:33:11 -07:00
Yi Qi
e36a259a45 fix(@angular/cli): fix issues in google3 2018-09-13 14:08:04 -07:00
Charles Lyding
d29701f978 fix(@angular-devkit/core): allow stat on record host 2018-09-10 12:30:49 -07:00
Alan Agius
b8b36ba339 refactor: pin down all direct dependencies
This is so that CLI users get the same direct dependency versions that were tested on the CI.
2018-09-07 11:01:50 -07:00
Alex Eagle
f7f1d139f4 release: v7.0.0-beta.2 2018-09-06 14:47:26 -07:00
Hans Larsen
fefef0271e refactor(@angular/cli): remove parseJsonFile and add options to parseJson instead 2018-09-06 07:37:48 -07:00
Hans
fd7bcd25fe fix(@angular-devkit/core): use architect key only if it exists
And if target didnt exist.
2018-09-06 07:37:48 -07:00
Hans
9517677158 feat(@angular-devkit/core): remove addUndefinedDefaults as default post transform
And various bug fixes.
2018-09-06 07:37:48 -07:00
Hans
fb99a490bf feat(@angular-devkit/core): add a parseJsonFile that shows file path on error 2018-09-06 07:37:48 -07:00
Hans
1b5c0082ef feat(@angular-devkit/core): add levenshtein distance utility 2018-09-06 07:37:48 -07:00
Hans
0b84c1d4b0 feat(@angular-devkit/core): move findTypes in utility and export 2018-09-06 07:37:48 -07:00
Hans Larsen
39b4cc030b build: fix RxJS invalid typings 2018-08-30 16:49:31 -07:00