Skip to content

6.0.0-rc.0: Migration of asset configuration broken #10146

@bananer

Description

@bananer

Versions

Angular CLI: 6.0.0-rc.0
Node: 8.10.0
OS: linux x64
Angular: 6.0.0-rc.1
... animations, common, compiler, compiler-cli, core, forms
... http, language-service, platform-browser
... platform-browser-dynamic, router

@angular/cdk: 6.0.0-rc.0
@angular/cli: 6.0.0-rc.0
@angular/material: 6.0.0-rc.0
@angular-devkit/architect: 0.0.10
@angular-devkit/build-angular: 0.0.10
@angular-devkit/build-optimizer: 0.4.9
@angular-devkit/core: 0.4.9
@angular-devkit/schematics: 0.5.0
@ngtools/json-schema: 1.1.0
@ngtools/webpack: 6.0.0-beta.9
typescript: 2.7.2
webpack: 4.1.0

Repro steps

  • Have a project built with angular-cli 1.7 with an entry like this in .angular-cli.json:
	"apps": [
		{
			// …
			"assets": [
				"assets",
				"favicon.ico"
			]
		}
	]

(assets is a folder and favicon.ico is a file)

  • Upgrade to 6.0.0-rc.0
  • run ng update @angular/cli --migrate-only --from=1.7.1 as requested

Observed behavior

angular.json is created with entries like this under projects/my-project/architect/build/options:

            "assets": [
              {
                "glob": "assets",
                "input": "/src",
                "output": "/"
              },
              {
                "glob": "favicon.ico",
                "input": "/src",
                "output": "/"
              },

Which does not match the desired files in both cases

Desired behavior

I had to change it to this:

            "assets": [
              {
                "glob": "assets/**",
                "input": "src",
                "output": "/"
              },
              {
                "glob": "favicon.ico",
                "input": "src",
                "output": "/"
              },

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions