Skip to content
This repository has been archived by the owner on May 25, 2019. It is now read-only.

Clean task does not remove dot files #37

Closed
alefteris opened this issue Mar 20, 2013 · 12 comments
Closed

Clean task does not remove dot files #37

alefteris opened this issue Mar 20, 2013 · 12 comments

Comments

@alefteris
Copy link
Contributor

  • Started with the files generated by webapp, I did a build
  • I removed the .htaccess, from my app folder and Gruntfile copy task config
  • After a build, .htaccess is still in the dist forder
@passy
Copy link
Member

passy commented Mar 20, 2013

This is deliberate to allow the dist folder to be its own git repository
for deployment purposes. You can still adjust the behavior in the
Gruntfileif you like.
On Mar 20, 2013 6:54 PM, "Thanos Lefteris" notifications@github.com wrote:

  • Started with the files generated by webapp I did a build
  • I removed the .htaccess, from my app folder and Gruntfile copy task
    config
  • After a build, .htaccess is still in the dist forder


Reply to this email directly or view it on GitHubhttps://github.com/yeoman/generator-webapp/issues/37
.

@alefteris
Copy link
Contributor Author

Could this be made more explicit, with a comment maybe? Or even better a rule to exclude just the .git dir/files?

Also what I will need to change in Gruntfile to remove the dotfiles? Thanks.

@passy
Copy link
Member

passy commented Mar 21, 2013

You could change the dist: ['.tmp', '<%= yeoman.dist %>/*'] to dist: ['.tmp', '<%= yeoman.dist %>'] for the clean task (removing just the whole dist directory instead of just the non-hidden files inside).

@sindresorhus Do you think a comment would be helpful here?

@sindresorhus
Copy link
Member

@passy I would rather find a way to clean out everything except for .git. Any ideas?

@passy
Copy link
Member

passy commented Mar 21, 2013

.gitignore would also be useful.
On Mar 22, 2013 12:49 AM, "Sindre Sorhus" notifications@github.com wrote:

@passy https://github.com/passy I would rather find a way to clean out
everything except for .git. Any ideas?


Reply to this email directly or view it on GitHubhttps://github.com/yeoman/generator-webapp/issues/37#issuecomment-15273576
.

@sindresorhus
Copy link
Member

yup

@kevva
Copy link
Member

kevva commented Mar 22, 2013

This works.

clean: {
  dist: {
    files: [{
      dot: true,
      src: [
        'dist/*',
        '!dist/.git*'
      ]
    }]
  }
}

@sindresorhus
Copy link
Member

@kevva feel free to do that update directly ;)

@kevva
Copy link
Member

kevva commented Mar 22, 2013

Yep, done :)))))).

@sindresorhus
Copy link
Member

@kevva awesome, thanks for doing this. Keep em coming :D

Tip: use fixes #ticketnumber in commits to close issues directly from the commit and create a reference between them.

Fixed in yeoman/generator-webapp@7616dc4

@sindresorhus
Copy link
Member

@kevva could you do the same on generator-angular?

@kevva
Copy link
Member

kevva commented Mar 22, 2013

@sindresorhus, I'm on it.

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

4 participants