Use <optgroup> tags to group branches and tags. Patch by James
Henstridge <james@daa.com.au>.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@848 8cb11bc2-c004-0410-86c3-e597b4017df7
(common_template_data): Expose request.pathtype as a generally
available template variable. (Have I mentioned today how much I
dislike per-template data dictionary items?)
* viewcvs/templates/log_table.ezt
* viewcvs/templates/log.ezt
Use the pathtype variable to determine whether or not to show
file-only stuff like diff and download options.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@847 8cb11bc2-c004-0410-86c3-e597b4017df7
Duh. Stop using filter_path and (failing at) translating between the
senses here.
* viewcvs/lib/vclib/svn_ra/__init__.py
(LogCollector.__init__): Drop the 'options', take explicit 'show_all_logs'.
(LogCollector.add_log): Update for new variables. Also, fix some
logic so this works when we aren't showing all logs, too.
(SubversionRepository.filelog): Parse the options here, and pass to
the LogCollector().
* viewcvs/lib/vclib/svn/__init__.py
(NodeHistory.__init__, NodeHistory.add_history, _get_history): Stop
using 'filter_path'; use 'show_all_logs' instead.
* viewcvs/lib/viewcvs.py
(view_log): Make showing all directory logs default to 0.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@846 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewcvs/lib/vclib/svn/__init__.py
(NodeHistory.add_history): Use subpools in this loop.
* viewcvs/lib/vclib/svn_ra/__init__.py
(LogCollector.add_log): Fix an off-by-one error. The path for this
revision is self.path *before* we find the previous path.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@845 8cb11bc2-c004-0410-86c3-e597b4017df7
(NodeHistory.add_history): Fixes for support for directory log
filtering. Don't filter out copy revisions.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@844 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewcvs/lib/viewcvs.py
(Request.get_link): Allow where == '' as a way to indicate that you
want to see the root directory (since None means "use self.where").
(common_template_data): Generate the right URL for changing roots.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@843 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewcvs/lib/viewcvs.py
(MarkupPipeWrapper): Rewrite this class so that it actually works.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@842 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewcvs/website/index.html
Say that we require 1.5.2, not 1.5 (which eliminates the need to
point out the MySQL dependency).
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@841 8cb11bc2-c004-0410-86c3-e597b4017df7
"don't show all dir logs") working the svn_ra layer. In fact, this
sucker is now more accurate as far as revision choices go than the
'svn' module.
* viewcvs/lib/vclib/svn_ra/__init__.py
(LogCollector.__init__): Deal with None paths, and ensure leading slashes.
(LogCollector.add_log): Uncomment and fix path filtering code.
(_fetch_log): Remove.
(SubversionRepository.filelog): Move contents of _fetch_log into
here, and then do something that in unheard of -- CALL
SVN_CLIENT_LOG WITH THE PARAMS IN THE RIGHT ORDER!
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@840 8cb11bc2-c004-0410-86c3-e597b4017df7
NOTE: This work is not yet finished for the 'svn_ra' vclib module.
* viewcvs/lib/vclib/svn/__init__.py
(NodeHistory.__init__): Add fs_ptr and filter_path arguments.
(NodeHistory.add_history): If filtering, only add the history item
if the path truly change in that revision.
(_get_history): Add 'options' argument, and use it to decide if we
need to filter out bubble-up-only directory logs, as well as
whether or not to cross copies.
(_fetch_log): Was fetch_log. Add 'options' argument, passed to
_get_history.
(SubversionRepository.filelog): Update call to _fetch_log.
* viewcvs/lib/vclib/svn_ra/__init__.py
(_compare_paths): New path comparison function (ported from
Subversion's C-composed svn_path_compare_paths)
(LogCollector): New class for doing what the old inline _log_cb
function did.
(_fetch_log): Was fetch_log. Add 'options' argument. Now use the
new LogCollector class.
(SubversionRepository.filelog): Update call to _fetch_log.
* viewcvs/lib/viewcvs.py
(Request.run_viewcvs): Don't set 'cross_copies' as an attribute of
the repository any more. We use the vclib interface options
params.
(view_log): Re-work this sucker to handle requests for directory
logs in Subversion. Also, pass the cross_copy option here.
(view_directory): Set the rev_href for Subversion directories to the
log view href.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@839 8cb11bc2-c004-0410-86c3-e597b4017df7
setup to test it at all. :-(
* viewcvs/lib/query.py
(main): Populate the 'docroot' data dictionary item.
* viewcvs/templates/query.ezt
Stop trying (and failing) to use the common header include ... I
don't have the energy to make this thing work with that right now.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@838 8cb11bc2-c004-0410-86c3-e597b4017df7
Re-add the "previous" and "next" buttons on the revision view.
Patch (mostly) by Guy Maor <guy@extreme-da.com>.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@837 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewcvs/templates/diff.ezt
Setup template defines before include header.ezt.
* viewcvs/lib/viewcvs.py
(view_revision_svn): Add 'rev' to the diff_href.
* viewcvs/templates/dir_alternate.ezt
Fix the filename links to go to the log view again (apparently I
accidentally clobbered these recently, though I must say, the
navigation seems entirely unintuitive to me this way...).
* viewcvs/templates/revision.ezt
Tweak the display of the log message a little big.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@836 8cb11bc2-c004-0410-86c3-e597b4017df7
by Dirk Lemstra <dirk.lemstra@atosorigin.com>. Also, add some stuff
to the generally-available-to-all-templates dataset. And finally,
re-work all the templates for consistent look and feel.
I can die now.
* viewcvs/lib/viewcvs.py
(common_template_data): Expose the 'where', 'roottype', and
'rootname' Request members, and the 'nav_path', to all views.
Also, do the root selection stuffs ('roots', 'change_root_action',
'change_root_hidden_values').
(nav_header_data): No longer explicitly add 'nav_path' to the data
dictionary.
(_dir_url): For Subversion, supply the revision number to the
generated links.
(view_directory): Include the revision when generating log view
URLs. Also, expose a 'tree_rev_href' data item for linking to the
revision view. No longer explicitly add 'roottype', 'where', and
'current_root' to the data dictionary. No longer do the root
selection stuff here, either.
(view_log): No longer explicitly add 'roottype', 'where', and
'current_root' to the data dictionary.
(human_readable_diff): No longer explicitly add 'where' to the data
dictionary.
(view_markup, view_revision): No longer explicitly add 'roottype' to
the data dictionary.
* viewcvs/website/upgrading.html
Document the changes.
* viewcvs/website/help_rootview.html
Add a missing "<br>".
* viewcvs/templates/annotate.ezt
* viewcvs/templates/graph.ezt
* viewcvs/templates/log.ezt
* viewcvs/templates/log_table.ezt
* viewcvs/templates/markup.ezt
* viewcvs/templates/query.ezt
* viewcvs/templates/revision.ezt
* viewcvs/templates/include/dir_header.ezt
* viewcvs/templates/include/footer.ezt
* viewcvs/templates/include/header.ezt
Beat the heck outta these templates until they all reference
header.ezt and footer.ezt (except for error.ezt), and they all
present a basically consistent interface across all views.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@835 8cb11bc2-c004-0410-86c3-e597b4017df7
Fix all instances of "if(!rv) { Py_DECREF(rv); }" mishap. We should
decrement the reference count for the value only if it is *not*
NULL. Erik Huelsmann oopsed. I oopsed more for not reviewing the
patch before application. James Henstridge <james@daa.com.au> wins
for paying attention.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@834 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewcvs/lib/viewcvs.py
(view_annotate): Now use blame.BlameSource() class for doing annotations.
* viewcvs/lib/blame.py
(BlameSource, BlameSequencingError): New classes.
(make_html): Re-work to use the use BlameSource code.
* viewcvs/lib/config.py
(Config.set_defaults): No longer set self.templates.footer.
* viewcvs/viewcvs.conf.dist
(templates.footer): Removed.
* viewcvs/templates/annotate.ezt
Re-work this template to make use of the newly exposed blame data,
and the fabulous new EZT assignment commands!
* viewcvs/website/upgrading.html
Document this change.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@833 8cb11bc2-c004-0410-86c3-e597b4017df7
construct. Patch by James Henstridge <james@daa.com.au>, tweaked to
conform with Greg Stein's review, and stripped of the template changes
that made use of the new functionality by C. Michael Pilato (that's me).
* viewcvs/lib/ezt.py
import cStringIO, and failing that, import StringIO.
(_block_cmd_specs): Add 'define' to the list of block specs.
(Template.generate): Init defines member.
(Template._parse): Don't prepare references for 'define' commands.
(Template._cmd_define): New.
(_get_value): Look for items in the defines dictionary before
falling back to the data dictionary.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@832 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewcvs/lib/viewcvs.py
(html_footer): Remove.
(view_annotate): Generate the footer data -- the only remaining
place where template usage is impure...
(retry_read): New.
(copy_stream): Rename 'fp' to 'src', and add an optional 'dst'
parameter. Move reading code into retry_read().
(markup_stream_default, markup_stream_enscript): Remove.
(markup_stream_python): Return a MarkupBuffer instance.
(markup_stream_python): Return a MarkupPHP instance.
(MarkupBuffer, MarkupPipeWrapper, MarkupEnscript, MarkupPHP): New
classes for implementing file-like markup objects.
(view_markup): Use new Markup classes.
(generate_tarball): Don't trap an unused status code.
* viewcvs/templates/markup.ezt
Reference the new [markup] dictionary object, and include the footer.ezt.
* viewcvs/templates/include/header.ezt
White background, please.
* viewcvs/website/upgrading.html
Note the new [markup] variable.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@830 8cb11bc2-c004-0410-86c3-e597b4017df7
Erik Huelsmann <e.huelsmann@gmx.net>.
* viewcvs/lib/vclib/ccvs/rcsparse/common.py
(Sink.set_expansion): New member function. Called to pass
default expansion mode.
(Sink.set_locking): New member function. Function is called
to signal strict locking.
(Sink.set_locker): New member function. Set locker for a given revision.
(_Parser.parse_rcs_admin): parse 'access', 'expand', 'locks' and
'strict' token values passing the result(s) into the sink.
* viewcvs/lib/vclib/ccvs/rcsparse/default.py
(Parser.parse_rcs_admin): parse 'access', 'expand', 'locks' and
'strict' token values passing the result(s) into the sink.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@828 8cb11bc2-c004-0410-86c3-e597b4017df7
PyObject_CallMethod. Patch by Erik Huelsmann <wiskid@gmx.net>.
* viewcvs/tparse/tparsemodule.cpp
Catch return value from PyObject_CallMethod and DECREF when appropriate.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@827 8cb11bc2-c004-0410-86c3-e597b4017df7
(footer): Update the default location for footer.ezt (now in the
include/ subdir).
* viewcvs/website/upgrading.html
Add a note about rearranged template locations.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@826 8cb11bc2-c004-0410-86c3-e597b4017df7
revision, authors), cleanup some unnecessary data dictionary cruft,
and rework the default directory templates a bit.
* viewcvs/lib/viewcvs.py
(view_directory): Do the Right Thing for Subversion directory log
messages. Merge the 'cvs' and 'state' data fields for CVS.
Populate rev_href for Subversion directories.
* viewcvs/templates/directory.ezt
* viewcvs/templates/dir_alternate.ezt
Track data dictionary changes, and tweak the templates to always
show name, rev, author, date -- now only log is conditional on
show_logs (go figure). Also, core the common header and footer
parts of these files into...
* viewcvs/templates/dir_header.ezt
* viewcvs/templates/dir_footer.ezt
...these new include files.
* viewcvs/website/upgrading.html
Update with notations about these changes.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@823 8cb11bc2-c004-0410-86c3-e597b4017df7
for whipping me into action.
* viewcvs/lib/viewcvs.py
(_strip_suffix): If the "suffix" is the whole last path component,
remove that component altogether (rather than leaving an
empty-string component after the strip)
(generate_tarball): Include timestamps for directories now. For
CVS, directory timestamps will be the youngest of the dates for
files in that directory. For Subversion, same routine except that
files and subdirs datestamps count.
(download_tarball): Don't include in a tarball all the empty
directories between the root of the repository at the directory
being tarballed. Just stick the tarballed directory into the top
of the tarball, either by its own name (if we know it) or by the
configured name of that repository root (if the top-most directory
is the to-be-tarballed directory).
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@822 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewcvs/tparse/tparse.h
* viewcvs/tparse/tparsemodule.cpp
* viewcvs/tparse/tparsemodule.h
Massive tparse reindenting, reformatting, and spacing /
capitalization fixes in messages. Patch by Max Bowsher
<maxb@ukf.net> (tweaked a little by cmpilato to ensure lines < 80
characters).
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@820 8cb11bc2-c004-0410-86c3-e597b4017df7
(Request.run_viewcvs): Look in the Attic/ for files in CVS URLs, and
redirect on a 'hit'.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@819 8cb11bc2-c004-0410-86c3-e597b4017df7
* tparse/tparse.cpp
(TokenParser::get): Write one less byte in case of
@-sign-is-last-byte-in-buffer: the byte will be transferred to the
start of the newly filled buffer.
(tparseParser::parse_rcs_tree): Use correct pointer when
constructing linked list.
* tparse/tparsemodule.cpp
(PythonSink::define_revision): Don't leak PyString objects.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@818 8cb11bc2-c004-0410-86c3-e597b4017df7
(view_revision_svn): Fix a missing assignment that rendered a call
to html_time() rather pointless. Noticed by Lele Gaifax.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@816 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewcvs/lib/viewcvs.py
(Request.run_viewcvs): Move the forbidden path check until after a
root-as-url-component redirect.
(view_directory): Break out the forbidden path
check so that Subversion and CVS paths get checked.
(generate_tarball): Break out the forbidden path
check so that Subversion and CVS paths get checked. Also, fix
usage of an uninstantiated variable.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@815 8cb11bc2-c004-0410-86c3-e597b4017df7
(_Parser.parse_rcs_tree): Support author which contain spaces. It's
a Windows CVS thing ... *shrug*.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@812 8cb11bc2-c004-0410-86c3-e597b4017df7
ViewCVS assume otherwise. Fix that (as best as can be expected).
Bug reported by Alejandro Ramirez <alejandro.ramirez@artmediacompany.com>.
* viewcvs/lib/vclib/svn/__init__.py
(_datestr_to_date): Protect against None datestrings by return "now"
when there's no valid to use.
* viewcvs/lib/vclib/svn_ra/__init__.py
(_datestr_to_date): New (copied from the 'svn' module).
(LastHistoryCollector._log_cb, get_logs): Use new _datestr_to_date()
* viewcvs/lib/viewcvs.py
(view_markup, view_directory, view_log, view_revision_svn,
view_diff, make_time_string): Watch out for missing dates.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@811 8cb11bc2-c004-0410-86c3-e597b4017df7
(SubversionRepository.__init__): Carefully track how stuff is
initialized so the __del__() method doesn't do bad stuff.
(SubversionRepository.__del__): Only de-init stuff that got init-ed.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@810 8cb11bc2-c004-0410-86c3-e597b4017df7
(view_log): Initialize the entry.branch_point and entry.next_main
values to None, common to all VC systems.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@809 8cb11bc2-c004-0410-86c3-e597b4017df7
resource. Reported by Roland Schwingel <Roland.Schwingel@onevision.de>.
* viewcvs/lib/viewcvs.py
(view_markup): Add the revision to the URL for image-type markup views.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@808 8cb11bc2-c004-0410-86c3-e597b4017df7
Patch mostly by Eike Bernhardt <eike-usenet@unorganized.net>.
* viewcvs/lib/viewcvs.py
(Request.get_link): Don't lose the rev= parameter when building
log-view URLs.
(view_log): Include the copyfrom revision in the copyfrom URL.
* viewcvs/templates/log_table.ezt
* viewcvs/templates/log.ezt
Don't tack on a revision bookmark to the copyfrom URL. It's not
likely to exist, and is now unnecessary anyway.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@807 8cb11bc2-c004-0410-86c3-e597b4017df7
Import LongType from types, too.
(_get_value): Handle conversion of LongType as well.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@806 8cb11bc2-c004-0410-86c3-e597b4017df7
(_re_validate_number): Add '~' as an acceptable character in a CVS
symbol. CVS, after all, does allow such things.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@804 8cb11bc2-c004-0410-86c3-e597b4017df7
* lib/vclib/bincvs/__init__.py
(fetch_log):
fix arg list
* lib/rlog.py
(GetRLogData)
take repository object as argument instead of cfg object
* lib/cvsdb.py
(GetCommitListFromRCSFile):
take repository object as argument instead of repository path
* tools/cvsdbadmin
(CommandUpdate, CommandRebuild)
create BinCVSRepository objects to pass to cvsdb functions
* tools/loginfo-handler
(CommitFromFileData, GetUnrecordedCommitList)
take repository object as arguments instead of repository path
(ProcessLoginfo)
create BinCVSRepository objects to pass to cvsdb functions
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@802 8cb11bc2-c004-0410-86c3-e597b4017df7