Skip to content

Commit

Permalink
Replacing commit URLs with edit link.
Browse files Browse the repository at this point in the history
  • Loading branch information
jacebrowning committed Feb 12, 2014
1 parent f94680c commit f3549fa
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 6 deletions.
4 changes: 2 additions & 2 deletions CHANGES.md
@@ -1,7 +1,7 @@
Changelog
=========

0.0.1 (2014/02/10)
0.1 (development)
-------------------

- Initial development release.
- Initial release.
1 change: 1 addition & 0 deletions README.md
Expand Up @@ -47,4 +47,5 @@ To update every flagged file with the current URL text, commit, and push:

curmit


**That's it!**
5 changes: 3 additions & 2 deletions curmit.py
Expand Up @@ -149,7 +149,8 @@ def _run(args, cwd, err): # pylint: disable=W0613
git('add', path, _dry=args.no_commit)
if git('diff', '--cached', '--exit-code'):
logging.info("committing {}...".format(path))
message = "curmit: {}".format(url)
message = "curmit: {}".format(url.replace("/pub?embedded=true",
'/edit'))
git('commit', '-m', message, _show=True, _dry=args.no_commit)
changes = True
else:
Expand Down Expand Up @@ -178,7 +179,7 @@ def flagged(cwd):
for filename in filenames:
path = os.path.join(root, filename)
try:
with open(path, 'r+') as infile:
with open(path, 'r') as infile:
url = None
header = []
for index, line in enumerate(infile, start=1):
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Expand Up @@ -17,7 +17,7 @@

setuptools.setup(
name=__project__,
version='0.0.1',
version='0.1',

description="Grabs text from a URL and commits it.",
url='http://github.com/jacebrowning/curmit',
Expand All @@ -31,7 +31,7 @@
long_description=(README + '\n' + CHANGES),
license='LGPL',
classifiers=[
'Development Status :: 3 - Alpha',
'Development Status :: 4 - Beta',
'Environment :: Console',
'License :: OSI Approved :: MIT License',
'Natural Language :: English',
Expand Down

0 comments on commit f3549fa

Please sign in to comment.