Skip to content

fix(@angular/cli): add a flag to let assets outside of outDir #8123

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Nov 20, 2017

Conversation

hansl
Copy link
Contributor

@hansl hansl commented Oct 20, 2017

On top of #7778
Fixes #8122

Copy link
Contributor

@filipesilva filipesilva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WDYT of having the flag directly on the asset object definition? #8122 (comment)

Copy link
Contributor

@filipesilva filipesilva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a test that ensures this works?

Copy link
Contributor

@filipesilva filipesilva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hansl
Copy link
Contributor Author

hansl commented Nov 16, 2017

@filipesilva PTAL.

@hansl hansl merged commit 64c600d into angular:master Nov 20, 2017
@dzonatan
Copy link
Contributor

dzonatan commented Nov 23, 2017

So the whole project cannot be built outside anymore (using ../ in apps outDir)?
That's a breaking change. :/ At least add a note in release logs.

@BnSmth
Copy link

BnSmth commented Nov 23, 2017

@dzonatan, The change you are referring to occurred in #7778. This change adds a flag to .angular-cli.json to allow the original behavior (allowing assets to be output outside outDir).

@dzonatan
Copy link
Contributor

dzonatan commented Nov 23, 2017

@BnSmth, I'm not talking about assets. Instead about entire application. That change in #7778 only checks the asset paths against outDir. There is no limitation to use ../ in outDir.

Simple steps to reproduce:

  1. ng new example
  2. add ../ for apps[0].outDir in .angular-cli.json
  3. ng build

Do that with both cli versions and you will see in 1.5.3 it builds and in 1.5.4 doesn't.

If this was not intentional then I'll create an issue.

@guilhermejcgois
Copy link

@dzonatan I have created one #8613, this change caught us by surprise 😢

@BnSmth
Copy link

BnSmth commented Nov 23, 2017

@dzonatan Sorry, my bad. I misunderstood the issue and agree that a fix needs to be put in place. Also, as you said, given this is a breaking change, a note should have been added to the release.

@hansl hansl deleted the outdir-assets branch November 28, 2018 23:34
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 12, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow ng build to put files in the outdir and levels higher than the outdir
6 participants