This bug occurred because whenever the "git blame" command detects
international character it outputs a string escaped character string in
the form "\ddd\ddd". Gitinspector didn't properly handle this. Python
offers a way to decode this using the decode function together with the
"string_escape" encoding.
The Outputable class is now the base class of all the classes that want to
output formatted text. This is more object oriented and cleaner solution
compared to the previous implementation.
This output is a good start and should work fine as a first template that
can be used when implementing HTML output in all other modules.
Once this is done we can work on adding some interactivity. However; it
might be a good idea to just release a version with some simple HTML
output before adding more complex stuff.
Changed from using the deprecated functions in the os module to using the
new ones in the subprocess module. All string reading now also uses the
string.decode() function, which seems to be recommended practice whenever
the input is a little "iffy".
The responsibilities module shows a maximum of 10 files, per author, that each
author is responsible for. This fucntionality can be enabled by supplying -r
or --responsibilities to gitinspector. The parameter is also enabled if
--tda367 is specified.
Filtering can be specified using an arbitrary number of -x (or --exclude)
parameters. The filtering works in a similar fashion to an inverted grep,
meaning that matched file names will be excluded from the generated
statistics.
To accommodate this modification, the changing of working directory (when
a repository is specified) has been moved from the system module to the
main gitinspector module. This enables us to change directory in one go
when gitinspector starts, thus removing the need for the previous system
module.
The following concurrency components control the implementation:
* A semaphore that limits the number of running blame instances to the
number of cores detected in the system.
* A lock that protects internal data structures inside the blame module.
The threading functionality is currently disabled because some additional
changes are needed in the system module before it can work correctly.
This was added because "git blame -C -C" really takes a lot of time and
something is needed to indicate that gitinspector is actually running during
this stage.
The progress text is not shown if stdout points to a non-terminal.
It should now be able to handle multi-line comments that are only on one line.
Furthermore, it should also handle multi-line comments from languages such as
python (where the identifiers for comment begining/end are identical).
If any missing files are detected during analysis, gitinspector reports them
in a list. If, on the other hand, the --checkout-missing option is supplied,
gitinspector will try to checkout any missing files instead.