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

Suggestion: Added command -- Batchedit #29

Open
pbmarklf opened this issue May 17, 2012 · 5 comments
Open

Suggestion: Added command -- Batchedit #29

pbmarklf opened this issue May 17, 2012 · 5 comments

Comments

@pbmarklf
Copy link
Contributor

I've written and tested an additional command -- Batchedit.

Batchedit is like Edit, only it is suitable for use in a shell script / batch file for when you need to change a lot of content at once.

Usage is like:
wgd batchedit
'--pattern=.META.http.equiv..Pragma..content..no.cache..'
'--string='
home

--pattern is the pattern you want to match. Please note that the pattern match will use the modifiers 'xms'.

--string is the replacement string.

Like Edit, it will take either a URL or an assetId.

wgd with Batchedit passes the 'dzil test' tests and builds with 'dzil build'.

Given this, what should be my next step?

@haarg
Copy link
Owner

haarg commented May 18, 2012

The current edit command allows you to specify --command, and that could be used to run a perl oneliner to do something similar to this. However, having this as dedicated option does make sense to me. Having either a separate command like you've implemented it, or possibly just additional parameters to the edit command would work.

Aside from that though, the best thing to do is create a fork of this repo and commit and push your change to it. Then either create a push request or just post about it on this issue and I can pick up the changes and push out a new version.

@pbmarklf
Copy link
Contributor Author

(Assuming that I did everything correctly..) I've pushed my fork out to https://github.com/pbmarklf/wgdev.

@haarg
Copy link
Owner

haarg commented May 21, 2012

Your git author configuration isn't set up correctly, so the attribution is listed as '--global'. You should fix that:
$ git config --global user.name "Mark Leighton Fisher"
$ git config --global user.email "mark@plainblack.com"

I'm going to pull this in and fix the attribution myself, since that's probably easier.

@pbmarklf
Copy link
Contributor Author

Thanks.

Sorry for the broken author configuration -- I tried about 3 different times, and thought I had fixed it correctly the 3rd time. Oh well, I guess the 4th times' the charm...

@pbmarklf
Copy link
Contributor Author

FYI -- wgdev/.git/config was wrong from my earlier tries, and finally getting user.name & user.email right in ~/.gitconfig did not update wgdev/.git/config. Now both are OK after manually editing wgdev/.git/config.

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