Skip to content
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

Add support for an expand option? #25

Open
micahblu opened this issue Oct 30, 2014 · 7 comments
Open

Add support for an expand option? #25

micahblu opened this issue Oct 30, 2014 · 7 comments

Comments

@micahblu
Copy link

It be very nice to maintain the directory structure from src wildcard matches.

For example let's say I have:

replace: {
  html: {
    src: ['src/**/*.html'],
    dest: 'dist/'
    // the rest
  }
}

In this case the dist gets a flattened version of the src files, losing directories and possibly overwriting files, for example a directory with index.html would overwrite the root index.html. It'd be nice to have an expand option that would build the directories as needed.

@fantapop
Copy link

fantapop commented Jan 7, 2015

I agree this would be nice. A work around would be to copy the tree to your new location and then run the replace on the files in place.

@micahblu
Copy link
Author

micahblu commented Jan 7, 2015

I actually have a detached fork where I implemented the feature: https://github.com/micahblu/grunt-replace-text

@fantapop
Copy link

fantapop commented Jan 7, 2015

okay, no pull request?

@micahblu
Copy link
Author

micahblu commented Jan 7, 2015

I did, but he didn't reply in time and I needed an updated git repo for dev deployments at work

@micahblu
Copy link
Author

micahblu commented Jan 7, 2015

I'll do another pull request, I believe he did eventually reply.

@fantapop
Copy link

fantapop commented Jan 7, 2015

That would be appreciated. Thank you!

On Tue, Jan 6, 2015 at 11:08 PM, Micah Blu [email protected] wrote:

I'll do another pull request, I believe he did eventually reply.


Reply to this email directly or view it on GitHub
#25 (comment)
.

@micahblu
Copy link
Author

I've submitted a pull request that should do the trick

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants