Also return some lost files back, document 4intra.net modifications
in CHANGES and README files, remove 'union' authorizer and rewritehtml
as the similar functionality is already provided by the core.
Also fix diffs for non-bash (sh/ash/dash) shells.
USE SHELL!!!
The bug was probably somewhere in file descriptor cloning + Apache webserver
git-svn-id: svn://svn.office.custis.ru/3rdparty/viewvc.org/trunk@516 6955db30-a419-402b-8a0d-67ecbb4d7f56
processed by markup and annotate views"). This introduces a new
'max_filesize_kbytes' configuration option for limiting markup and
annotate operations on really big files (whose contents unfortunately
must be read fully into memory sometimes). By default, a 512-kilobyte
limit will be in place.
* lib/vclib/__init__.py
(Repository.filesize): New.
* lib/vclib/svn/svn_repos.py
(LocalSubversionRepository.filesize): New function.
* lib/vclib/svn/svn_ra.py
(RemoteSubversionRepository.filesize): New function.
* lib/vclib/ccvs/bincvs.py
(BaseCVSRepository.filesize): New function (returns -1 aka "not
implemented")
* conf/viewvc.conf.dist
(max_filesize_kbytes): New configuration option.
* lib/config.py
(Config.set_defaults): Set default value for new
'max_filesize_kbytes' configuration option.
* lib/viewvc.py
(assert_viewable_filesize): New helper function.
(markup_or_annotate): Use assert_viewable_filesize() and the new
repos.filesize() API to honor the new 'max_filesize_kbytes'
configuration option.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2866 8cb11bc2-c004-0410-86c3-e597b4017df7
### "annotate view without syntax coloration" codepath. ###
On the 'issue-495-dev' branch: Let vclib API consumers request that
annotation data come with or without the associated text.
* lib/vclib/__init__.py
(Repository.annotate): Add optional 'include_text' parameter.
* lib/vclib/svn/svn_ra.py
(RemoteSubversionRepository.annotate): Add 'include_text' parameter
and, if False, have the annotation callback drop the text on the floor.
* lib/vclib/svn/svn_repos.py
(BlameSource.__init__): Add 'include_text' param; squirrel away the value.
(BlameSource._blame_cb): Don't keep text we're asked not to keep.
(LocalSubversionRepository.annotate): Add 'include_text' parameter,
passed to BlameSource.__init__.
* lib/vclib/ccvs/bincvs.py
(BinCVSRepository.annotate): Add 'include_text' parameter, passed to
blame.BlameSource().
* lib/vclib/ccvs/ccvs.py
(CCVSRepository.annotate): Add 'include_text' parameter, passed to
blame.BlameSource().
* lib/vclib/ccvs/blame.py
(BlameSource.__init__): Add 'include_text' param; squirrel away the value.
(BlameSource.__getitem__): Don't keep text we're asked not to keep.
* lib/blame.py
(HTMLBlameSource.__init__): Update call to repos.annotate().
git-svn-id: http://viewvc.tigris.org/svn/viewvc/branches/issue-495-dev@2696 8cb11bc2-c004-0410-86c3-e597b4017df7
CVS-keywords"). This changes causes the checkout of CVS file
contents -- when used as part of the markup/annotate logic -- to not
expand keywords. This helps it to be consistent with the results of
the annotate information query.
* lib/vclib/__init__.py,
* lib/vclib/svn/svn_ra.py,
* lib/vclib/svn/svn_repos.py
* lib/vclib/ccvs/ccvs.py
(openfile): Add 'options' parameter (unused). Callers updated.
* lib/vclib/ccvs/bincvs.py
(openfile): Add 'options' parameter, and look for a 'cvs_oldkeywords'
option to govern the use of -kkv or -ko in the 'co' command.
Callers updated.
* lib/viewvc.py
(markup_or_annotate): Pass 'cvs_oldkeywords' option to repos.openfile().
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2545 8cb11bc2-c004-0410-86c3-e597b4017df7
of this is aimed at not paying the maintenance price of supporting
Python versions prior to 2.4 any longer, plus a little bit of just
getting dead code out of the way.
* lib/compat.py
Remove as unused.
* bin/cvsdbadmin,
* bin/loginfo-handler,
* bin/make-database,
* bin/svndbadmin,
* lib/accept.py,
* lib/blame.py,
* lib/cvsdb.py,
* lib/popen.py,
* lib/query.py,
* lib/sapi.py,
* lib/vcauth/forbidden/__init__.py
* lib/vcauth/forbiddenre/__init__.py,
* lib/vcauth/svnauthz/__init__.py,
* lib/vclib/__init__.py,
* lib/vclib/ccvs/blame.py,
* lib/win32popen.py,
* tests/timelog.py
Replace explicit import and use of the 'string' module with newer constructs.
* bin/standalone.py,
* lib/viewvc.py
No longer use 'compat' module. Replace explicit import and use of
the 'string' module with newer constructs.
* lib/dbi.py
Use calender.timegm() instead of compat.timegm().
* lib/vcauth/__init__.py
Lose unused module imports.
* lib/config.py,
Replace explicit import and use of the 'string' module with newer
constructs where possible. Lose old ConfigParser patch-up code for
Python 1.5.1.
* lib/vclib/ccvs/ccvs.py
Replace explicit import and use of the 'string' module with newer
constructs where possible. Import _path_join() from bincvs, and use
it instead of a bunch of copy-and-pasted string join() statements
throughout.
* lib/vclib/ccvs/__init__.py
(cvs_strptime): Moved here from the 'compat' module.
* lib/vclib/ccvs/bincvs.py
(): No longer use 'compat' module. Replace explicit import and use
of the 'string' module with newer constructs.
(_path_join): New, used now instead of a bunch of copy-and-pasted
string join() statements throughout.
* viewvc-install
Don't use the 'compat' module any more.
Also, so some rearranging of non-critical bits.
* misc/: New directory.
* misc/py2html.py: Moved from 'lib/py2html.py'.
* misc/PyFontify.py: Moved from 'lib/PyFontify.py'.
* misc/elemx/: Moved from 'elemx/'.
* misc/tparse/: Moved from 'tparse/'.
* tools/make-release
Omit 'misc' directory from releases, too.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2437 8cb11bc2-c004-0410-86c3-e597b4017df7
Subversion revision properties.
NOTE: The svn_ra logic attempts to do the right thing when
pre-Subversion 1.5 libraries are install, but I haven't had the
chance to actually test this out myself.
* templates/revision.ezt
Include the props.ezt property handler template fragment for use
with revision props. Also, minor markup change to a header.
* templates/docroot/styles.css
Lose some unnecessary stylation.
* lib/viewvc.py
(get_itemprops): Lose unused variable has_binary_props.
(view_revision): Handle new return value from repos.revinfo(),
processing extra revision props similarly to the way that file/dir
props are processed and passing them to the template data
dictionary.
* lib/vclib/svn/svn_ra.py
Import _split_revprops() from svn_repos.
(client_log): New compatibility wrapper.
(add_log): Reformat as an svn_log_entry_receiver_t callback.
(RemoteSubversionRepository.dirlogs, _date_from_rev): Track changes
to self.revinfo().
(RemoteSubversionRepository.itemlog): Now use client_log().
(RemoteSubversionRepository._revinfo_raw): Now use client_log() and
return revprops dict, too.
(_log_cb): Reformat as an svn_log_entry_receiver_t callback.
* lib/vclib/svn/svn_repos.py
(_split_revprops): New helper.
(_log_helper, LocalSubversionRepository.dirlogs, _date_from_rev):
Track changes to repos._revinfo().
(_revinfo): Use _split_revprops(), and now return revprops, too.
(_revinfo_helper): Now return revprops dict, too.
(_date_from_rev):
* lib/vclib/__init__.py
(Repository.revinfo): Update docstring to indicate that this
interface now returns a revprops dictionary, too.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2401 8cb11bc2-c004-0410-86c3-e597b4017df7
preserve executability.
* lib/vclib/__init__.py
(Repository.isexecutable): New.
* lib/vclib/ccvs/bincvs.py
(BaseCVSRepository.isexecutable): New.
* lib/vclib/svn/svn_repos.py
(LocalSubversionRepository.isexecutable): New.
* lib/vclib/svn/svn_ra.py
(RemoteSubversionRepository.isexecutable): New.
* lib/viewvc.py
(generate_tarball): Use repos.isexecutable() to get the executable
bit for file tarball members. (This loses old code which directly
consulted the ,v file in the CVS case.)
* CHANGES
Note this change.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1936 8cb11bc2-c004-0410-86c3-e597b4017df7
* lib/vclib/__init__.py
(Repository.dirlogs): Update comment.
(Revision.__init__): Add 'lockinfo' parameter, used to populate
similarly named class member.
* lib/vclib/svn/svn_repos.py
(Revision.__init__): Add 'lockinfo' parameter, and update call to
vclib.Revision().
(_log_helper): Update call to Revision(), and lose custom lockinfo handling.
(LocalSubversionRepository.dirlogs): Populate entry lockinfo with a
call to svn_fs_get_lock() for each entry.
* lib/vclib/svn/svn_ra.py
(LogCollector.__init__): Add 'lockinfo' parameter, used to populate
similarly named class member.
(LogCollector.add_log): Pass self.lockinfo to updated call to Revision().
(RemoteSubversionRepository.itemlog): Pass lock info to
LogCollector(), and lose custom lockinfo handling.
(RemoteSubversionRepository.itemtype, RemoteSubversionRepository.listdir):
Update expected return value from _get_dirents().
(RemoteSubversionRepository.dirlogs): Populate entry lockinfo from
updated return value from _get_dirents().
(RemoteSubversionRepository._get_dirents): Rework to trade in
dirents and locks instead of only dirents.
* lib/vclib/ccvs/bincvs.py
(Revision.__init__): Update call to vclib.Revision().
(_get_logs): Add 'lockinfo' member to DirEntry() items.
* lib/vclib/ccvs/ccvs.py
(InfoSink.__init__): Init lockinfo dictionary.
(InfoSink.set_locker): New.
(InfoSink.define_revision): Set lockinfo on Revision item.
(InfoSink.set_revision_info): Populate DirEntry lockinfo from
Revision lockinfo data.
* lib/viewvc.py
(view_directory): Populate entry lockinfo.
(common_template_data): Populate the 'lockinfo' data dictionary item.
* templates/directory.ezt,
* templates/dir_new.ezt
* templates/annotate.ezt,
* templates/markup.ezt
Tweak to show lock status.
* docs/template-authoring-guide.html
Note new data dictionary items.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1787 8cb11bc2-c004-0410-86c3-e597b4017df7
vclib.Repository interface, and adapt the Subversion vclib modules to
implement it.
* lib/vclib/__init__.py
(ADDED, DELETED, REPLACED, MODIFIED): New static variables.
(Repository.revinfo): New function.
(ChangedPath): New class.
(UnsupportedFeature): New exception type.
* lib/vclib/bincvs/__init__.py
(BinCVSRepository.revinfo): New (just raises vclib.UnsupportedFeature).
* lib/vclib/ccvs/__init__.py
(CCVSRepository.revinfo): New (just raises vclib.UnsupportedFeature).
* lib/vclib/svn/__init__.py
(SVNChangedPath): Was ChangedPath, now is a subclass of vclib.ChangedPath.
(SubversionRepository.revinfo): Was get_revision_info(). Rework to
use SVNChangedPath items.
* lib/vclib/svn_ra/__init__.py
(): Import SVNChangedPath instead of ChangedPath.
(LastHistoryCollector.add_history): Rework to use SVNChangedPath items.
(SubversionRepository.revinfo): Was get_revision_info().
* lib/viewvc.py
(view_revision): Rework this to use Repository.revinfo()
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1685 8cb11bc2-c004-0410-86c3-e597b4017df7
and type by forcing them to implement functions which query those
pieces of information.
* lib/vclib/__init__.py
(Repository.rootname, Repository.rootpath, Repository.roottype): New.
* lib/vclib/bincvs/__init__.py
(CVSRepository.rootname, CVSRepository.rootpath,
CVSRepository.roottype): New.
* lib/vclib/svn/__init__.py
(SubversionRepository.rootname, SubversionRepository.rootpath,
SubversionRepository.roottype): New.
* lib/vclib/svn_ra/__init__.py
(SubversionRepository.rootname, SubversionRepository.rootpath,
SubversionRepository.roottype): New.
* lib/viewvc.py
(Request.run_viewvc): Ask the Repository object for its roottype(),
and translate the vclib value into a string. (It would be nice to
use the vclib value throughout the codebase, but not today.)
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1654 8cb11bc2-c004-0410-86c3-e597b4017df7
* lib/vclib/__init__.py
(NonTextualFileContents): New Exception.
* lib/vclib/svn/__init__.py
(BlameSource.__init__): Translate the Subversion error
SVN_ERR_CLIENT_IS_BINARY_FILE in the new vclib.NonTextualFileContents
exception.
* lib/viewvc.py
(view_annotate): Catch the new vclib.NonTextualFileContents exception.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1514 8cb11bc2-c004-0410-86c3-e597b4017df7
having the Repository.annotate() implementations return lists of them
(instead of lists of those cool-but-overused-_item-thingies).
* lib/vclib/__init__.py
(Repository.annotate): Note that this interface now returns
Annotation objects.
(Annotation): New.
Also, do some docstring addition/modification elsewhere in this file.
* lib/vclib/ccvs/blame.py
(BlameSource.__getitem__): Return vclib.Annotation objects now.
(_item): Remove as unneeded.
* lib/vclib/svn/__init__.py
(BlameSource.__getitem__): Return vclib.Annotation objects now.
(_item): Remove as unneeded.
* lib/vclib/svn_ra/__init__.py
(SubversionRepository._blame_cb): Store vclib.Annotation objects now.
(_item): Remove as unneeded.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1427 8cb11bc2-c004-0410-86c3-e597b4017df7
creating a new section of the configuration file strictly for defining
the locations of these helper applications.
This closes issue #229 (configurable path to sed) and issue #62
(configurable path to diff), and perhaps others I failed to find.
* viewvc.conf.dist
Add a new "utilities" section for corraling all the various
tool-location configurations, and relocate (with some tweaks) a
bunch of options:
general.rcs_path => utilities.rcs_dir
general.cvsnt_ext_path = utilities.cvsnt
general.svn_path => utilities.svn
options.enscript_path => utilities.enscript
options.highlight_path => utilities.highlight
options.py2html_path => utilities.py2html_dir
options.php_exe => utilities.php
options.cvsgraph_path => utilities.cvsgraph
utilities.diff (new)
utilities.gzip (new)
utilities.sed (new)
options.use_py2html (new)
* lib/config.py
(_sections): Add 'utilities' section.
(Config.set_defaults): Reflect options tweaks made to
viewvc.conf.dist in the code here.
* lib/viewvc.py
(Request.run_viewvc): Track renamed utilities.svn option. Now pass
cfg.utilities into BinCVSRepository(), CCVSRepository(), and
SubversionRepository(). Collapse now-identical
SubversionRepository() calls.
(markup_stream_python): Return immediately if options.use_py2html
isn't set. Track renamed utilities.py2html_dir option.
(view_cvsgraph_image, view_cvsgraph): Track renamed
utilities.cvsgraph option.
(MarkupPHP.__init__): Track renamed utilities.php option, and allow
for 'php' as a fallback value.
(MarkupHighlight.__init__): Track renamed utilities.highlight option.
(MarkupEnscript.__init__): Track renamed utilities.enscript option,
and honor new utilities.sed option.
(download_tarball): Use new utilities.gzip option.
* lib/vclib/__init__.py
(_diff_fp.__init__): Add 'diff_cmd' parameter.
* lib/vclib/svn/__init__.py
(SubversionRepository.__init__): Drop 'svn_path' parameter, and now
accept 'utilities'.
(SubversionRepository.rawdiff): Pass self.diff_cmd to _diff_fp().
* lib/vclib/svn_ra/__init__.py
(SubversionRepository.rawdiff): Pass self.diff_cmd to _diff_fp().
* lib/vclib/ccvs/__init__.py
(CCVSRepository.rawdiff): Pass self.utilities.diff or 'diff' to _diff_fp().
* lib/vclib/bincvs/__init__.py
(CVSRepository.__init__): Add 'utilities' parameter.
(BinCVSRepository.__init__): Lose as no-longer-necessary.
(BinCVSRepository.rcs_popen): Track renamed options, and renamed
member variable that hold those options.
* docs/upgrading-howto.html
Note these options changes.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1407 8cb11bc2-c004-0410-86c3-e597b4017df7
Jacob Nevins (sourceforge user "jtn") in issue 153.
* lib/vclib/__init__.py
(_diff_args): perform full diff when "context" option is None
* lib/viewvc.py
(view_diff): add logic for full diffs
* templates/diff.ezt
* templates/include/diff_form.ezt
add option for full diffs
* viewvc.org/template-authoring-guide.html
* viewvc.org/url-reference.html
update documentation for "diff_format" template variable and url param
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1346 8cb11bc2-c004-0410-86c3-e597b4017df7
instead of a list of path parts. We seem to do that a few places in
the svn module.
* vclib/__init__.py
(ItemNotFound.__init__): accept path strings as arguments
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1284 8cb11bc2-c004-0410-86c3-e597b4017df7
* lib/vclib/bincvs/__init__.py
(BinCVSRepository.rawdiff): Stop being so picky about the diff
header sanity. Start looser, and we'll tighten up as we need to.
* lib/vclib/__init__.py
(_diff_fp.close): Add 'self' to the parameter list.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1170 8cb11bc2-c004-0410-86c3-e597b4017df7
using the system "diff" command like the svn and svn_ra modules. Factor
the diff code out of the svn and svn_ra modules so they can share
functionality with each other and ccvs. Thanks to C. Mike for getting me
to work on this.
* lib/vclib/__init__.py:
(_diff_fp):
new class, based on svn_ra.FileDiff, used by ccvs, svn, and svn_ra
modules
* lib/vclib/ccvs/__init__.py
(CCVSRepository.rawdiff):
implement in terms of openfile, itemlog, and _diff_fp
* lib/vclib/svn_ra/__init__.py
(FileDiff, do_diff, _escape_msvcrt_shell_command, _escape_msvcrt_shell_arg):
removed
(temp_checkout)
new function
(SubversionRepository.rawdiff):
change implementation to use temp_checkout and _diff_fp
* lib/vclib/svn/__init__.py
(do_diff):
removed
(temp_checkout):
new function, based on code from subversion's fs.py
(SubversionRepository.rawdiff
change implementation to use temp_checkout and _diff_fp
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1154 8cb11bc2-c004-0410-86c3-e597b4017df7
path parameters so it is possible to use a single Repository object
to request information about any path at any revision.
Note: I wasn't able to test the svn_ra.get_location function because
I only have subversion 1.2.3.
* lib/vclib/__init__.py
(Repository.itemtype, Repository.openfile, Repository.listdir,
Repository.dirlogs, Repository.itemlog, Repository.annotate):
add rev arguments, update docstrings
* lib/vclib/bincvs/__init__.py
(CVSRepository.itemtype, CVSRepository.listdir, BinCVSRepository.openfile,
BinCVSRepository.dirlogs, BinCVSRepository.itemlog):
same
* lib/vclib/ccvs/__init__.py
(CCVSRepository.dirlogs, CCVSRepository.itemlog):
same
* lib/vclib/svn/__init__.py
(SubversionRepository.__init__):
remove rev argument
(get_location, created_rev, _get_history, get_revision_info, _fetch_log,
_get_last_history_rev, get_logs, do_diff,
SubversionRepository.itemtype, SubversionRepository.openfile,
SubversionRepository.listdir, SubversionRepository.dirlogs,
SubversionRepository.itemlog, SubversionRepository.annotate):
add rev arguments, use new _getrev and _getroot functions to handle
all revision string parsing and revision_root creation
(SubversionRepository._getrev, SubversionRepository._getroot):
new functions
* lib/vclib/svn_ra/__init__.py
(_rev2optrev):
accept integers instead of strings, and eliminate head/unspecified
revision handling which is already taken care of by _getrev
(SubversionRepository.__init__):
remove rev argument
(get_location, created_rev, get_revision_info, get_logs,
SubversionRepository.itemtype, SubversionRepository.openfile,
SubversionRepository.listdir, SubversionRepository.dirlogs,
SubversionRepository.itemlog, SubversionRepository.annotate,
SubversionRepository.rawdiff, SubversionRepository._get_dirents):
add rev arguments, use new _getrev function to handle all revision
string parsing
(SubversionRepository._getrev):
new function
* lib/blame.py
(link_includes):
update call to repos.itemtype
* tools/cvsdbadmin
(RecurseUpdate):
update call to repos.listdir
* lib/viewcvs.py
(Request.run_viewcvs):
update calls to SubversionRepository constructors and _strip_suffix
(_strip_suffix):
add rev parameter, remove redundant where parameter
(_repos_pathtype, view_markup, search_files, _get_diff_path_parts,
generate_tarball):
update calls to vclib methods
(nav_path, view_directory, view_log, setup_diff, download_tarball,
view_revision):
explicitly read 'rev' query param instead of relying on
SubversionRepository.rev, and update vclib calls
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1144 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewcvs/lib/vclib/svn/__init__.py (SubversionRepository.rawdiff),
* viewcvs/lib/vclib/svn_ra/__init__.py (SubversionRepository.rawdiff),
* viewcvs/lib/vclib/ccvs/__init__.py (CCVSRepository.rawdiff),
* viewcvs/lib/vclib/bincvs/__init__.py (BinCVSRepository.rawdiff):
For clarity, replace uses of the term 'path' with 'path_parts' in the
Repository.rawdiff() stub and implementations.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1104 8cb11bc2-c004-0410-86c3-e597b4017df7
into the vclib providers.
* viewcvs/lib/vclib/__init__.py
(Repository.annotate): New interface.
* viewcvs/lib/vclib/ccvs/blame.py
New file, with contents cored from viewcvs/lib/blame.py, and
reworked a little bit to avoid data tainting, and to be independent
of the vclib implementation.
* viewcvs/lib/vclib/ccvs/__init__.py
(CCVSRepository.annotate): Implement Repository.annotate() by returning
a blame.BlameSource object.
* viewcvs/lib/vclib/bincvs/__init__.py
(BinCVSRepository.annotate) Implement by returning a
vclib.ccvs.blame.BlameSource object.
* viewcvs/lib/vclib/svn/__init__.py
* viewcvs/lib/vclib/svn_ra/__init__.py
(SubversionRepository.annotate): New. Return NotImplementedError.
* viewcvs/lib/viewcvs.py
(view_annotate): Use new blame.blame() function.
* viewcvs/lib/blame.py
Gut this sucker, moving most of the heavy lifting into the ccvs module.
(HTMLBlameSource): New wrapper for BlameSource objects to handle
HTML-izing and such.
(blame): New function, thin wrapper around
(make_html): Remove unused 'sticky' param. Tweak to use new
abstracted interface, but at the cost of diff_url support. I'll
probably come back to this (by adding a --diff-url option), but
does anyone really care?
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1098 8cb11bc2-c004-0410-86c3-e597b4017df7
(InvalidRevision.__init__): Make the revision argument optional, and
fix the exception strings up a bit.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1094 8cb11bc2-c004-0410-86c3-e597b4017df7
diff format. This also has the effect of simplifying the wrapping
code (which wasn't working anyway) a little bit. Also, restore
functionality lost in the last re-org of the diff functionality
(svn_ra). Finally, make the vclib.ccvs module's lack of diff
functionality a little more apparent to those who attempt to use it.
* viewcvs/lib/vclib/__init__.py
(Repository.rawdiff): Specify that returned diffs are expected to be
in GNU diff format.
* viewcvs/lib/vclib/bincvs/__init__.py
(BinCVSRepository.rawdiff): Eat up the rcsdiff header lines, not
exposing them to the caller. The goal is to expose consistent
diff output across vclib providers, so we'll shoot for GNU diff
compliance.
* viewcvs/lib/vclib/ccvs/__init__.py
(CCVSRepository.rawdiff): Implement this interface, though only to
raise an exception about how the functionality isn't implemented.
* viewcvs/lib/vclib/svn_ra/__init__.py
(do_diff): Sync with vclib.svn.do_diff().
(SubversionRepository.rawdiff): Implement this interface.
* viewcvs/lib/viewcvs.py
(diff_parse_headers): Lose the 'rootpath' argument. We've tuned the
vclib providers to stop exposing that stuff.
(view_diff): Update calls to diff_parse_headers().
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1091 8cb11bc2-c004-0410-86c3-e597b4017df7
* lib/vclib/__init__.py
(Repository.rawdiff, UNIFIED, CONTEXT, SIDE_BY_SIDE, _diff_args):
new
* lib/vclib/bincvs/__init__.py
(Repository.rawdiff):
new
* lib/vclib/svn/__init__.py
(Repository.rawdiff):
new
(do_diff):
move code that fixes diff headers here
* lib/viewcvs.py
(_path_parts):
new function to break a repository path into parts
(Request.run_viewcvs):
use _path_parts function
(view_diff):
use new Repository.rawdiff methods and _path_parts
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1086 8cb11bc2-c004-0410-86c3-e597b4017df7
supports logs on directories, too, ya know). And make some other
little documentation changes.
* viewcvs/lib/vclib/__init__.py
(Repository.itemlog): Was Repository.filelog().
(Revision.__init__): Document the input parameters.
* viewcvs/lib/vclib/bincvs/__init__.py
(BinCVSRepository.itemlog): Was BinCVSRepository.filelog().
* viewcvs/lib/vclib/ccvs/__init__.py
(CCVSRepository.itemlog): Was CCVSRepository.filelog().
* viewcvs/lib/vclib/svn/__init__.py
(SubversionRepository.itemlog): Was SubversionRepository.filelog().
* viewcvs/lib/vclib/svn_ra/__init__.py
(SubversionRepository.itemlog): Was SubversionRepository.filelog().
* viewcvs/lib/viewcvs.py
(view_markup, view_log): Update calls to Repository.itemlog() (from
Repository.filelog()).
* viewcvs/lib/cvsdb.py
(GetCommitListFromRCSFile): Update calls to Repository.itemlog()
(from Repository.filelog()).
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1050 8cb11bc2-c004-0410-86c3-e597b4017df7
* lib/vclib/__init__.py
(DirEntry.__init__):
set "errors" member instead of "verboten"
* lib/vclib/bincvs/__init__.py
(CVSRepository.listdir):
don't skip "Attic" and "CVS" entries if we're not sure if they are
directories
don't skip entries in Attic/ when we can't tell if they are files or
directories
(CVSDirEntry.__init__):
use "errors" argument instead of "verboten"
(_get_logs):
don't set "DirEntry.log_errors" member, use "errors"
(_log_path):
don't return file access errors here, they are returned by _check_path
(_check_path):
return error strings on file access errors instead of simple booleans
* lib/vclib/ccvs/__init__.py
(CCVSRepository.dirlogs):
don't set "DirEntry.log_errors" member, use "errors"
* lib/vclib/svn/__init__.py
* lib/vclib/svn_ra/__init__.py
(get_logs):
don't set "DirEntry.log_errors" member
* lib/viewcvs.py
(view_directory):
use "DirEntry.errors" member instead of "log_errors"
(generate_tarball):
use "DirEntry.errors" member instead of "verboten"
* tools/cvsdbadmin
(RecurseUpdate):
use "DirEntry.errors" member instead of "verboten"
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@978 8cb11bc2-c004-0410-86c3-e597b4017df7
* lib/vclib/bincvs/__init__.py
(BinCVSRepository.openfile, BinCVSRepository.filelog, fetch_log):
update calls to _parse_log_header
(_re_log_error, _re_cvsnt_error, _re_lineno):
update regular expressions for parsing rlog error messages
(_parse_log_header):
do a better job of parsing rlog error messages and return messages
to callers
(_get_logs):
set new DirEntry.log_errors property and deal with multiple rlog error
messages about the same file and cases where error messages precede
file information
(_log_path):
return error info
* lib/vclib/ccvs/__init__.py
(CCVSRepository.dirlogs):
set new DirEntry.log_errors property
* lib/vclib/svn/__init__.py
(get_logs):
set new DirEntry.log_errors property
* lib/vclib/svn_ra/__init__.py
(get_logs):
set new DirEntry.log_errors property
* lib/vclib/__init__.py
(Repository.dirlogs):
document new DirEntry.log_errors property
* lib/viewcvs.py
(view_directory):
set new template variables
* website/upgrading.html
document new template variables
* templates/include/dir_footer.ezt
get rid of confusing "One or more files were unreadable" message.
We display more specific error messages in the directory list.
add links to set selection criteria at the bottom of "There are
[num_files] files, but none match the current selection criteria"
message
* templates/directory.ezt
* templates/dir_alternate.ezt
simplify the way error messages are displayed
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@907 8cb11bc2-c004-0410-86c3-e597b4017df7
- Revision class is now defined in vclib
- DirEntry class has new log_error boolean member to replace use of
bincvs._FILE_HAD_ERROR constant.
- In CVS, DirEntry.state string member is replaced by boolean DirEntry.dead
* lib/vclib/__init__.py
(Repository.dirlogs):
add documentation
(Revision):
new class
* lib/vclib/bincvs/__init__.py
(Revision):
inherit from new vclib.Revision class
(get_logs, _FILE_HAD_ERROR):
stop using _FILE_HAD_ERROR constant
(parse_log_entry, get_logs):
use "dead" properties instead of "state" properties on Revision and
DirEntry objects
(_newest_file):
bugfix, call _check_path() to make sure returned file is accessible
* lib/rlog.py
(GetRLogData):
use Revision.dead member instead of Revision.state
* lib/vclib/svn/__init__.py
(Revision, LogEntry):
rename LogEntry class to Revision and inherit from vclib.Revision
(NodeHistory.add_history):
trim beginning slashes from subversion paths passed to this callback
(_log_helper):
call new Revision constructor
(fetch_log):
simplify return values
(get_logs):
set DirEntry.log_error member
(SubversionRepository.filelog):
update for changed fetch_log function, remove some kludges
* lib/viewcvs.py
(Request.run_viewcvs, bincvs):
import bincvs module as neccessary instead of importing globally
(view_markup, sort_file_data, view_directory, view_log,
generate_tarball):
update to deal with changed DirEntry and Revision members
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@796 8cb11bc2-c004-0410-86c3-e597b4017df7