Skip to content

ng init creates a styles.css  #2959

Closed
Closed

Description

@BenjaminHofstetter

OS?

Mac OSX El Capitan

Versions.

angular-cli: 1.0.0-beta.19-3
node: 6.9.1
os: darwin x64

Repro steps.

this is an angular cli project

The log given by the failure.

I did an update of angular cli

rm -rf node_modules dist tmp
npm install --save-dev angular-cli@latest
npm install
ng init

I am using a src/styles.scss instead of a src/styles.css. 'ng init' creates a new src/styles.css file. And I have to remove it manually every time I do an angular cli update.

Is it possible to check the app.styles array in angular-cli.json to avoid the creation of the src/styles.css during 'ng init'?

Activity

  1. Meligy commented on Oct 31, 2016

    @Meligy
    Contributor

    Did you tell it not to override angular-cli.json?

    If yes, then it can be considered a bug.

    It's probably by design though. I expect that it doesn't respect angular-cli.json because it generates it!

    I always run ng init --style=scss --routing when I'm upgrading Angular CLI. I even made it an NPM script, called it reset.

  2. BenjaminHofstetter commented on Oct 31, 2016

    @BenjaminHofstetter
    Author

    I told it not to override angular-cli.json.

  3. filipesilva commented on Nov 3, 2016

    @filipesilva
    Contributor

    It's a bug. We don't ready the current angular-cli.json when doing init.

  4. added
    P5
    on Nov 3, 2016
  5. sumitarora commented on May 11, 2017

    @sumitarora
    Contributor

    Closing as obsolete ng init is no longer available command.

  6. angular-automatic-lock-bot commented on Sep 7, 2019

    @angular-automatic-lock-bot

    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.

  7. locked and limited conversation to collaborators on Sep 7, 2019
  8. added a commit that references this issue on Aug 29, 2023
    98d7837
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P5type: bug/fix

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions