Skip to content

Allow user to specify angular-cli.json file to be used #4495

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

Closed
tdawgy opened this issue Feb 7, 2017 · 6 comments
Closed

Allow user to specify angular-cli.json file to be used #4495

tdawgy opened this issue Feb 7, 2017 · 6 comments

Comments

@tdawgy
Copy link

tdawgy commented Feb 7, 2017

Please provide us with the following information:

OS?

Windows 7, 8 or 10. Linux (which distribution). Mac OSX (Yosemite? El Capitan?)
Windows 10

Versions.

Please run ng --version. If there's nothing outputted, please run in a Terminal: node --version and paste the result here:
node: v6.9.4
npm: 3.10.10
angular-cli: 1.0.0-beta.26

Repro steps.

Was this an app that wasn't created using the CLI? What change did you do on your code? etc.
This feature isn't currently available.

The log given by the failure.

Normally this include a stack trace and some more information.
Since multiple apps in a single angular-cli.json file are not currently supported. A simple workaround could be to specify the angular-cli.json configuration file that's being used. This could allow us to have a separate angular-cli.json file for each project and then specify which one we want used.

ng serve --config angular-cli.json.app1
ng serve --config angular-cli.json.app2

ng build --config angular-cli.json.app1
ng build --config angular-cli.json.app2

Mention any other details that might be useful.


Thanks! We'll be in touch soon.

@vovikdrg
Copy link
Contributor

But then how it suppose to work with ng generate? It would be better just to support multiple apps

@tdawgy
Copy link
Author

tdawgy commented Feb 13, 2017

The same way I'm proposing it would work for any other ng command. You'd specify the angular-cli config file to be used. For backwards compatibility we should probably default it to use angular-cli.json located at root and just use the --config argument as an override.

ng generate --config angular-cli.json.app1
ng generate --config angular-cli.json.app2

@filipesilva
Copy link
Contributor

We added support for multiple apps via #4754.

There's no plan to support multiple config files at this point.

@rtm
Copy link

rtm commented May 4, 2018

Under v6, is there now any way to specify a different config file?
In the past I was using "projects" and the -a option, but with v6 it seems it always builds all projects, which is not what I want...

The overwhelming majority of systems that use config files have ways to specify the one you want.

@vance
Copy link

vance commented Feb 21, 2019

This would be great so that we can use Ionic apps inside a nx-workspace. Problem I'm facing is that we only want one angular.json, but ionic commands can only be run from within the project, and there is no way to specify the location of the root level angular.json. Having to manage multiple angular configs is ugly. Or, even a way to extend and 'fix' paths when loading relative angular.json.

@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 9, 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

No branches or pull requests

5 participants