Преглед изворни кода

Version info and document update for 0.9

Matthew Wang пре 11 година
родитељ
комит
56eb7bce95
4 измењених фајлова са 14 додато и 7 уклоњено
  1. 6
    0
      CHANGES
  2. 1
    1
      Makefile
  3. 5
    4
      README.rst
  4. 2
    2
      cdiff.py

+ 6
- 0
CHANGES Прегледај датотеку

2
 Change log
2
 Change log
3
 ==========
3
 ==========
4
 
4
 
5
+Version 0.9 (2013-03-23)
6
+
7
+  - Supports reading context diff via ``filterdiff`` (patchutils)
8
+  - Fixed a diff parser bug which misread git commit message as common line
9
+  - Lots of code refactor
10
+
5
 Version 0.8 (2013-03-13)
11
 Version 0.8 (2013-03-13)
6
 
12
 
7
   - Parser is now robust enough to handle dangling headers and short patch
13
   - Parser is now robust enough to handle dangling headers and short patch

+ 1
- 1
Makefile Прегледај датотеку

46
 
46
 
47
 clean:
47
 clean:
48
 	rm -f MANIFEST profile*.tmp* .coverage
48
 	rm -f MANIFEST profile*.tmp* .coverage
49
-	rm -rf build/ cdiff.egg-info/ dist/ __pycache__/
49
+	rm -rf build/ cdiff.egg-info/ dist/ __pycache__/ htmlcov/
50
 
50
 
51
 build:
51
 build:
52
 	./setup.py build sdist
52
 	./setup.py build sdist

+ 5
- 4
README.rst Прегледај датотеку

73
       -s, --side-by-side  enable side-by-side mode
73
       -s, --side-by-side  enable side-by-side mode
74
       -w N, --width=N     set text width for side-by-side mode, default is 80
74
       -w N, --width=N     set text width for side-by-side mode, default is 80
75
       -l, --log           show log with changes from revision control
75
       -l, --log           show log with changes from revision control
76
-      -c X, --color=X     colorize mode 'auto' (default), 'always', or 'never'
76
+      -c M, --color=M     colorize mode 'auto' (default), 'always', or 'never'
77
 
77
 
78
 Read diff from local modification in a *Git/Mercurial/Svn* workspace (output
78
 Read diff from local modification in a *Git/Mercurial/Svn* workspace (output
79
 from e.g. ``git diff``, ``svn diff``):
79
 from e.g. ``git diff``, ``svn diff``):
113
 
113
 
114
     # View a patch file in unified or context format, the latter depends on
114
     # View a patch file in unified or context format, the latter depends on
115
     # command `filterdiff` from package `patchutils` which is available in
115
     # command `filterdiff` from package `patchutils` which is available in
116
-    # major Linux distros and MacPorts.  "cdiff < foo.path" works too.
116
+    # major Linux distros and MacPorts.
117
     #
117
     #
118
-    cat foo.patch | cdiff 
118
+    cdiff -s < foo.patch
119
 
119
 
120
 Redirect output to another patch file is safe:
120
 Redirect output to another patch file is safe:
121
 
121
 
136
 Pull requests are very welcome, please make sure your changes can pass unit
136
 Pull requests are very welcome, please make sure your changes can pass unit
137
 tests and regression tests by run ``make test`` (required tool *coverage* can
137
 tests and regression tests by run ``make test`` (required tool *coverage* can
138
 be installed with ``pip install coverage``).  Also watch out `travis build
138
 be installed with ``pip install coverage``).  Also watch out `travis build
139
-<https://travis-ci.org/ymattw/cdiff>`_ after push, make sure it passes as well.
139
+<https://travis-ci.org/ymattw/cdiff/pull_requests>`_ after push, make sure it
140
+passes as well.
140
 
141
 
141
 See also
142
 See also
142
 --------
143
 --------

+ 2
- 2
cdiff.py Прегледај датотеку

8
 """
8
 """
9
 
9
 
10
 META_INFO = {
10
 META_INFO = {
11
-    'version'     : '0.8',
11
+    'version'     : '0.9',
12
     'license'     : 'BSD-3',
12
     'license'     : 'BSD-3',
13
     'author'      : 'Matthew Wang',
13
     'author'      : 'Matthew Wang',
14
     'email'       : 'mattwyl(@)gmail(.)com',
14
     'email'       : 'mattwyl(@)gmail(.)com',
662
         '-l', '--log', action='store_true',
662
         '-l', '--log', action='store_true',
663
         help='show log with changes from revision control')
663
         help='show log with changes from revision control')
664
     parser.add_option(
664
     parser.add_option(
665
-        '-c', '--color', default='auto', metavar='X',
665
+        '-c', '--color', default='auto', metavar='M',
666
         help="""colorize mode 'auto' (default), 'always', or 'never'""")
666
         help="""colorize mode 'auto' (default), 'always', or 'never'""")
667
     opts, args = parser.parse_args()
667
     opts, args = parser.parse_args()
668
 
668