Commit Graph

368 Commits (master)

Author SHA1 Message Date
cmpilato 9fdeff7fd0 * templates/docroot/images/logo.png
Tweak the logo to reflect the new project name.

git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1202 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-12-19 16:04:29 +00:00
rey4 b91146fee0 Work on issue 168, s/ViewCVS/ViewVC. This patch changes references to
ViewCVS in comments, strings, and documentation. References to ViewCVS
in filenames and urls still need to be fixed. Also, logo.png (the blimp)
needs to be updated or replaced.

This patch is by Gerard Gerritsen (sigcafe), the only change I've made is
to restore a reference to ViewCVS in a comment about backwards compatibility.

* windows/README
* viewcvs-install
* README
* templates/include/footer.ezt
* templates/include/header.ezt
* templates/error.ezt
* templates/query.ezt
* templates/docroot/help.css
* templates/docroot/help_query.html
* templates/docroot/help_dirview.html
* templates/docroot/help_rootview.html
* templates/docroot/styles.css
* templates/docroot/help_log.html
* templates/diff.ezt
* tools/make-release
* lib/sapi.py
* lib/dbi.py
* lib/accept.py
* lib/cvsdb.py
* lib/config.py
* lib/query.py
* lib/vclib/bincvs/__init__.py
* lib/vclib/svn/__init__.py
* lib/vclib/__init__.py
* lib/vclib/svn_ra/__init__.py
* lib/vclib/ccvs/rcsparse/common.py
* lib/vclib/ccvs/rcsparse/__init__.py
* lib/vclib/ccvs/rcsparse/default.py
* lib/vclib/ccvs/rcsparse/texttools.py
* lib/vclib/ccvs/rcsparse/debug.py
* lib/vclib/ccvs/__init__.py
* lib/vclib/ccvs/blame.py
* lib/blame.py
* lib/popen.py
* lib/compat.py
* lib/viewcvs.py
* lib/debug.py
* INSTALL
* bin/standalone.py
* bin/make-database
* bin/mod_python/query.py
* bin/mod_python/viewcvs.py
* bin/cgi/query.cgi
* bin/cgi/viewcvs.cgi
* bin/asp/query.asp
* bin/asp/viewcvs.asp
* bin/svndbadmin
* bin/loginfo-handler
* bin/cvsdbadmin
* viewcvs.conf.dist


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1200 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-12-17 17:19:28 +00:00
rey4 4f0805fcc1 Fix issue 172, typo in query results table header reported by
Paul Koning (pkoning). This is also issue 175.

* templates/query_results.ezt
    fix html-o


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1199 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-12-17 15:42:01 +00:00
rey4 d742c7fe32 Fix invalid variable reference in log_table template reported by
Gerard Gerritsen (sigcafe) in issue 164

* templates/log_table.ezt
    s/stick/pathrev/



git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1182 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-12-11 14:46:55 +00:00
rey4 754e9dbc30 Update template authoring guide and make template cleanups.
* lib/viewcvs.py
  (get_file_view_info):
    get rid of viewable return value

  (nav_header_data):
    get rid of "viewable" template variable

  (view_directory):
    rename "entries.viewable" variable to "entries.prefer_markup"
    rename "selection_form" variable to "search_re_form"
    rename "search_tag_action" variable to "search_action"
    rename "search_tag_hidden_values" variable to "search_re_hidden_values"

  (view_log):
    rename "entries.html_log" variable to "entries.log"
    restore value of "entries.next_main" variable to what it was in ViewCVS
      0.9.x
    get rid of "entries.viewable" template variable
    get rid of "viewable" template variable
    get rid of "tag_viewable" template variable

  (view_revision):
    rename "changes.filename" variable to "changes.path"
    rename "changes.base_path" variable to "changes.copy_path"
    rename "changes.base_rev" variable to "changes.copy_rev"

  (build_commit)
    rename "commits.desc" variable to "commits.log"
    get rid of "commits.rev_href" variable and replace with
      "commits.view_href", "commits.download_href", and
      "commits.prefer_markup"

* templates/include/dir_footer.ezt
* templates/include/file_header.ezt
* templates/dir_new.ezt
* templates/directory.ezt
* templates/log.ezt
* templates/log_table.ezt
* templates/query.ezt
* templates/query_results.ezt
* templates/revision.ezt
    update templates for changed variables

* CHANGES
    fix blurb about paging

* viewvc.org/upgrading.html
    update information about 0.9.x variables

* viewvc.org/template-authoring-guide.html
    fill it out


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1176 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-12-08 18:18:08 +00:00
cmpilato e4f868ffdc * templates/include/diff_form.ezt
Restore the diff_select FORM's NAME attribute so the JavaScript
  stuffs work.

git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1175 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-12-07 19:07:01 +00:00
rey4 baafc550a9 Check in another directory listing template following discussion that
started at

  http://mailman.lyra.org/pipermail/viewcvs-dev/2005-November/002139.html

The major differences from directory.ezt are:

  - there is a new column of icons providing links to most other views

  - revision, date, author, and log message columns are merged into a
    single "Last Change" column which is more compact and easier to
    decipher when reading from left to right. The fact that you can't
    do things like sort by log message or read down the author column
    shouldn't be a problem because in the most cases, doing these things
    doesn't make any sense.

Ideally everybody will fall in love with this template, and we'll be able
to make it the default, release ViewVC 1.0, and put these old UI issues to
rest. Otherwise we can tweak and butcher this template until we agree that
its good enough to be the default, and move on from there.

* templates/dir_new.ezt
    new template file

* lib/viewcvs.py
   (sort_file_data):
     when sorting in reverse, leave directories at the top and files
     with no revision information at the bottom. Also make sorting by
     revision number the same as sorting by date in cvs.

   (view_directory):
     add "row.revision_href" links for directory entries

* templates/docroot/images/annotate.png
    new icon for annotate view. image is "stock_people.png" from gnome

* templates/docroot/images/download.png
    new icon for download view. image is
    http://www.gentoo-portage.com/img/download.png

* templates/docroot/images/list.png
    new icon for directory listings. image is "stock_view-details.png"
    from gnome

* templates/docroot/images/log.png
    new icon for log view. image is "stock_list_enum.png" from gnome

* templates/docroot/images/view.png
    new icon for markup view. image is "stock_show-all.png" from gnome

* templates/dir_alternate.ezt
    removed, nobody seems to like it


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1174 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-12-06 19:22:41 +00:00
cmpilato 22a6e8b209 * templates/markup.ezt
Revert a change made in r1150, in which the markup template used the
  'viewable' data to avoid displaying binary files.  We'll let custom
  template writers do that if they wish, but will maintain our prior
  behavior.

git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1168 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-15 16:43:52 +00:00
cmpilato 4896268450 Re-add Russ Yanofsky's "last_rev" support, fine-tuned for performance
by myself.

NOTE: There are still some pool usage fixes to be made here.  Boy am I
looking forward to Subversion 1.3.0's (almost-)pool-free bindings...

* viewcvs/website/template-authoring-guide.html
  Restore definition of lastrev template item.

* viewcvs/templates/include/pathrev_form.ezt
  Expose the lastrev dictionary item.

* viewcvs/lib/vclib/svn/__init__.py
  (last_rev): New.

* viewcvs/lib/vclib/svn_ra/__init__.py
  (last_rev): New.

* viewcvs/lib/viewcvs.py
  (_last_rev): New wrapper around the svn provider's last_rev() functions.
  (pathrev_form, redirect_pathrev, view_log, view_directory): Use _last_rev().


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1159 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-10 22:08:48 +00:00
cmpilato 41975fa847 * viewcvs/templates/revision.ezt
Move the log message into the metadata table (this has been bugging
  me for some time), and don't force the table to 100% width.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1157 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-10 15:52:11 +00:00
rey4 af70f41740 * templates/docroot/help_rootview.html:
fix HTML error caught by Greg Stein


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1156 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-09 16:06:09 +00:00
rey4 8aa47a94e9 More documentation updates
* templates/docroot/help_rootview.html
* templates/docroot/help_dirview.html
* templates/docroot/help_log.html
    updated

* templates/docroot/help_logtable.html
    removed


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1155 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-09 15:34:25 +00:00
cmpilato e5f784525f Built-in help touch-ups.
* viewcvs/templates/docroot/help.css
  Added (a file from a recent patch by Marten Thavenius <martent@gmail.com>
  which I inadvertently failed to version when applying the patch).

* viewcvs/templates/docroot/help_rootview.html
  Update names of Fogel's CVS book and my (et al) Subversion book.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1153 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-08 14:33:04 +00:00
rey4 78c66dff21 Documentation updates.
* CHANGES
    add changes since last time we were going to release 1.0

* templates/docroot/help_rootview.html
    add better overview of ViewCVS. a little dry but more useful than
    "Directory entries end in slashes" and other stuff that shouldn't have
    to be pointed out.

    also remove outdated information about ViewCVS Project and
    replace it with a link to viewcvs.sourceforge.net


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1152 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-08 12:21:15 +00:00
rey4 b0d6bf328e Restore the sometimes checkout, sometimes markup behavior for
file links in the directory listing templates. Also make other
minor cleanups.

* templates/directory.ezt
    restore the file links and make the alt attribute for the
    parent direcotry icon the same as for the other icons

* templates/dir_alt.ezt
    restore the file links and add title attributes to all links

* website/upgrading.html
    update documentation for 0.9's rows.rev_href variable

----------------------------------------------------------------------


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1151 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-07 08:51:48 +00:00
cmpilato 0eab479ca0 Make the various file-related views available from the directory and
log views on a per-entry/revision basis.  Template authors can choose
to ignore the 'viewable'-ness of an item if they choose.  In the
process, this makes the directory view always link to the markup view
for files (instead of sometimes doing markup, sometimes checkout).
Consistent, predictable UI, folks ...

* viewcvs/lib/viewcvs.py
  (get_file_view_info): New.
  (nav_header_data, view_directory, view_log): Use new get_file_view_info to
    populate file navigation links.

* viewcvs/templates/markup.ezt
  If a file isn't viewable, show a warning instead of the markup.

* viewcvs/website/upgrading.html
  Track changes in the data dictionary.

* viewcvs/website/template-authoring-guide.html
  Track changes in the data dictionary, and fill in a few blanks here
  and there.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1150 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-04 19:20:55 +00:00
cmpilato 811b660e86 Restore performance by removing extremely expensive Subversion history
crawl.  Also, gracefully redirect old non-HEAD directory views.

* viewcvs/lib/viewcvs.py
  (Request.run_viewcvs): Redirect old DIRECTORY?rev=REV URLs to
    DIRECTORY?pathrev=REV ones.
  (_last_rev): Removed.
  (pathrev_form, redirect_pathrev, view_log): Lose the "lastrev" stuff.

* viewcvs/templates/include/pathrev_form.ezt,
* viewcvs/website/template-authoring-guide.html
  Track the loss of "lastrev".


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1149 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-04 13:16:24 +00:00
rey4 c002889dad Take some rough edges off the new sticky revision interface. Instead of
showing 404 errors when users try to jump to revisions where the path
being viewed doesn't exist, just redirect to the closest revision where
the path does exist.

Also, italicize the links which change the current 'pathrev' value
to make them stand out from links that stay within the current revision.

* lib/viewcvs.py
  (redirect_pathrev):
    new view that validates input from the pathrev form and redirects to
    the right revision

  (pathrev_form):
    new function that generates fields for pathrev form

  (_last_rev):
    new function for tracking subversion revisions

  (Request.run_viewcvs, Request.get_link, _legal_params, _views):
    add handling for redirect_pathrev view

  (Request.get_form):
    new function that wraps around get_link

  (view_directory, view_log):
    make use of new pathform_form and get_form functions

  (common_template_data, view_revision, view_queryform):
    make use of get_form function

  (view_directory, view_log):
    make use of pathrev_form

* templates/include/pathrev_form.ezt
    only show the "Clear" button when clearing won't cause a 404

* templates/annotate.ezt
* templates/log.ezt
* templates/log_table.ezt
* templates/markup.ezt
    italicize revision jumping links

* website/template-authoring-guide.html
    update


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1146 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-03 13:33:56 +00:00
rey4 01437d5937 New URL scheme for Subversion. The problem with the old scheme is it
doesn't have a concept of a "sticky" revision. So if you are looking
at version 10 of a directory, and click to view a file inside which
was last modified in version 6, the fact you were looking at version 10
of the parent directory is not recorded anywhere, and the "Parent Directory"
links on the markup page will take you to a version 6 directory listing
instead of the listing you came from. This problem exists all over
ViewCVS, not just in directory listings, and the result of it is that when
you browse a repository by following the provided links you get sent further
and further back into the history, all the while seeing incomplete log pages
and outdated directory listings which you never asked for.

The new URL scheme works by introducing a new 'pathrev' sticky variable and
is described in detail in a comment in the _orig_path function in
lib/viewcvs.py. The scheme is not backwards compatabile with all (or
maybe even most) old subversion URLs. Specifically, any old URL referring
to a path that no longer exists in the HEAD will not work. Other subversion
URLs will still work.

It is still possible to add backwards compatibility. We'd have to rename
the rev parameter to something else, so we could know that all URLs with
'rev' in them are old style URLs which need to be redirected. I don't know
if it's worth doing this though.

This is not an isolated change. I've tried to unite the Subversion "sticky
revision" with the present "only_with_tag" logic for CVS. And since I had
to go over viewcvs.py with a fine-toothed comb implementing these things,
there are also some miscellaneous cleanups there.

* lib/vclib/bincvs/__init__.py
  (_file_log):
    change filtering so when matching revisions to tag, includes all
    preceding revisions, not just tag revision itself

* lib/viewcvs.py
  (_sticky_vars):
    'only_with_tag' is gone, so change this back into a list with no
    span-roots values

  (request.run_viewcvs):
    read new 'pathrev' parameter and use it when calling repos.itemtype

  (request.get_link):
    add 'pathrev' parameter to urls, restore update _sticky_vars loop

  (_legal_params, prep_tags, build_commit):
    replace 'only_with_tag' with 'pathrev'

  (_orig_path):
    new function

  (nav_path, common_template_data):
    stop adding 'rev' parameters to links
    removed unused 'roots_href' template variable

  (nav_header_data):
    add new 'revision_href', 'orig_path', 'orig_href' template variables
    for use in markup and annotate views

  (view_markup, view_checkout, view_annotate, setup_diff, generate_tarball,
   download_tarball):
    use 'pathrev' when looking up file revision

  (view_directory):
    use 'pathrev' when looking up directory revisions instead of 'rev'.
    stop adding 'rev' to links.
    add template variables: pathrev, pathrev_action, pathrev_hidden_values.
    remove unused template variables: num_files, rev, view_tag, has_tags,
    main_href, jump_rev_action, jump_rev_hidden_values, row.show_log.

  (view_log):
    use 'pathrev' to retrieve log information instead of 'rev'.
    stop linking to original paths of copied files.
    add template variables: entry.orig_path, entry.orig_href, default_branch,
    pathrev, pathrev_action, pathrev_hidden_values, branch_tags, plain_tags.
    remove template variables: entry.filename, entry.prev_path,
    branch, path_selected, view_tag, branch_names, branch_select_action,
    branch_select_hidden_values.

  (view_cvsgraph):
    use common_template_data instead of nav_header_data, 'pathrev' instead
    of 'only_with tag'

  (view_diff):
    use common_template_data instead of nav_header_data
    add template variables: path_left, path_right

  (view_revision):
    use 'pathrev' instead of 'rev' in links

* templates/include/dir_header.ezt
    rearrange header and add sticky tag/revision row

* templates/include/dir_footer.ezt
    remove tag selector

* templates/include/pathrev_form.ezt
    new, sticky tag/revision selector form based on code from
    dir_footer.ezt

* templates/include/branch.ezt
* templates/include/branch_form.ezt
* templates/include/view_tag.ezt
    removed

* templates/include/log_header.ezt
    new, based on branch.ezt and view_tag.ezt

* templates/include/log_footer.ezt
    new

* templates/include/log.ezt
* templates/include/log_table.ezt
    include log_header.ezt and log_footer.ezt

* templates/include/annotate.ezt
* templates/include/diff.ezt
* templates/include/markup.ezt
    show original paths and add view_revision links

* cvsgraph.conf.dist
    replace only_with_tag parameter with pathrev

* website/template-authoring-guide.html
    update template variable information


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1145 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-11-03 13:31:02 +00:00
cmpilato 721b99609b More data dictionary consistency tweaks.
* viewcvs/lib/viewcvs.py
  (view_directory): Lose the initialization of the unused entries.href
    (accidentally overlooked a previous purge).  Rename entries.type
    to entries.pathtype.
  (view_revision): Recycle changes.pathtype (which just happens to
    work because the vclib file/dir constants are the same as those
    used for our EZT exposure) instead of setting a second
    changes.type variable.

* templates/directory.ezt,
* templates/dir_alternate.ezt,
* viewcvs/website/upgrading.html
  Track renamed and dropped variables.

* viewcvs/website/template-authoring-guide.html
  Fill in more of the directory view stuff, tracking the renamed and
  dropped variables.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1140 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-26 21:00:24 +00:00
cmpilato 203faae2d0 Consistify the datestamp variables to just 'date' (the timestamp) and
'ago' (the string describing how long ago that timestamp was from
"now").

* viewcvs/lib/viewcvs.py
  (view_directory): Expose entries.date variable, and rename
    entries.time to entries.ago.

* viewcvs/templates/dir_alternate.ezt,
* viewcvs/templates/directory.ezt
  Track renamed entries.time variable.

* viewcvs/website/upgrading.html,
* viewcvs/website/template-authoring-guide.html
  Track changes to the data dictionary.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1139 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-26 19:40:42 +00:00
cmpilato 010b3be03c Fix Bug #1332969 - small fix of markup warning on Repository Listing page
* viewcvs/templates/include/header.ezt
  Fix a markup warning which occurs when there's no nav_path.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1137 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-20 13:19:19 +00:00
cmpilato 8f79165d0c Move some logic that really UI-ish from the core code into the
templates.

* viewcvs/lib/viewcvs.py
  (view_log): Lose 'tr1' and 'tr2' dictionary items.

* viewcvs/templates/log.ezt,
* viewcvs/templates/log_table.ezt
  Calculate first and last revisions using EZT magic.

* viewcvs/templates/include/diff_form.ezt
  Choose default diff form values based on the 'rev_selected'
  dictionary item as well as the EZT-calculated first and last
  revisions.

* viewcvs/website/upgrading.html,
* viewcvs/website/template-authoring-guide.html
  Track removed variables, and add some missing punctuation.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1135 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-17 20:31:11 +00:00
cmpilato 2d37af8286 More template authoring guide; more dictionary tweaks as this exercise
points out more ugliness (which was its secondary goal, after all).

* viewcvs/lib/viewcvs.py
  (view_revision, view_markup, view_log): Use 'date' instead of
    'date_str' in data dictionary items.
  (view_directory): Use 'entries' instead of 'rows' in the data
    dictionary.  Remove redundant 'has_tags' dictionary init.

* viewcvs/templates/markup.ezt,
* viewcvs/templates/log.ezt,
* viewcvs/templates/revision.ezt,
* viewcvs/templates/log_table.ezt,
* templates/dir_alternate.ezt
* templates/directory.ezt
* viewcvs/website/upgrading.html
  Track variable renames.

* viewcvs/website/template-authoring-guide.html
  Track variable renames, and begin working on the directory view section.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1134 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-17 19:50:20 +00:00
cmpilato 99da769f25 Lose the poorly thunk 'makepatch' checkbox on the diff form. There
are probably whole volumes written about similar UI decisions and how
unintuitive they are.  Instead, abstract that work in a new patch
view.

NOTE:  While the new patch view supports the diff_format input
parameter, no template links or forms make use of it.  The code will
default to unified diff unless told to use context diff via the CGI
params or runtime config.

* viewcvs/lib/viewcvs.py
  (_legal_params): Lose 'makepatch'.  It was a good idea with a poor
    implementation choice.
  (_views): Add new 'patch' view, and tweak the alignment of this
    definition a bit.
  (get_link): Always copy the params dictionary instead of tainting
    the input dictionary.
  (view_patch): New.  Was the "if makepatch" section of view_diff().
  (view_diff): Abstract some setup stuff into setup_diff(), and the
    makepatch stuff into view_patch().

* viewcvs/templates/diff.ezt
* viewcvs/templates/include/diff_form.ezt
  Lose the 'makepatch' form checkbox.

* viewcvs/templates/include/file_header.ezt
  Add a patch view link.

* viewcvs/templates/docroot/images/diff.png
  New.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1132 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-14 21:35:58 +00:00
cmpilato 46a3ee4888 * viewcvs/templates/templates/docroot/images/broken.png,
* viewcvs/templates/templates/docroot/images/text.png
  Fix some transparency-related oddities in these images.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1131 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-14 21:32:41 +00:00
cmpilato 043995ce16 Tweak the diff view data dictionary for consistency.
* viewcvs/lib/viewcvs.py
  (DiffSource._flush_row): Make the 'have_left' and 'have_right'
    members of the change object be EZT booleans.
  (DiffSource._get_row): Rename 'extra' member to 'line_info_extra'.
  (view_diff): Rename some data dictionary variables:
    'rev1' => 'rev_left'
    'rev2' => 'rev_right'
    'tag1' => 'tag_left'
    'tag2' => 'tag_right'
    'date1' => 'date_left'
    'date2' => 'date_right'

* viewcvs/templates/diff.ezt
  Track renamed variables.

* viewcvs/website/upgrading.html
  Note the slight tweak to the way 'have_left' and 'have_right' work,
  not that I expect anyone to have really been testing for "yes".
  Also, note the renamed variables.

* viewcvs/website/template-authoring-guide.html
  Populate the annotate, graph, and diff sections, tracking the
  tweaked variables.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1130 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-14 20:29:16 +00:00
cmpilato f5ddba9443 Lose the unnecessary 'jump_rev' data dictionary item. It was used in
two views (directory and revision).  In the directory case, it was
renamed to just 'rev'; in the revision case, it was dropped as
redundant with with existing 'rev' variable.  Also, don't assume that
"is not a directory" implies "is a file" when looking at the common
'pathtype' variable.

* viewcvs/lib/viewcvs.py
  (common_template_data): Allow 'pathtype' to be None instead of
    'file' when the pathtype is neither a file nor a directory.
  (view_revision): Lose 'jump_rev'.
  (view_directory): Rename 'jump_rev' to just 'rev'.

* viewcvs/templates/revision.ezt
  Use 'rev' instead of 'jump_rev' throughout.

* viewcvs/templates/include/dir_header.ezt
  Stop using 'jump_rev' -- make 'youngest_rev' the default jump-to
  location.

* viewcvs/website/upgrading.html,
* viewcvs/website/template-authoring-guide.html
  Track the demise of 'jump_rev'.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1128 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-14 15:33:35 +00:00
cmpilato 30f1537eb7 * viewcvs/templates/revision.ezt
Add a trailing slash to directory paths.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1124 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-11 16:58:11 +00:00
cmpilato d9f6360681 Fix some bugs introduced yesterday that show up when using the
'svn_ra' module with the 'revision' view.

* viewcvs/lib/viewcvs.py
  (view_revision): Collapse some similar URL generation calls, but
    also trap the AssertionError thrown when using the 'svn_ra' backend
    (as it can't determine path types yet).

* viewcvs/lib/vclib/svn_ra/__init__.py
  (LastHistoryCollector.add_history): It's a long way from correct,
    but at least pass along copyfrom information correctly from this
    log handler.

* viewcvs/templates/revision.ezt
  Make the file/dir icons part of the filename links, too.  But don't
  make links where no valid hrefs exist.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1123 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-11 14:35:21 +00:00
cmpilato 997d65e926 Make some tweaks to the 'revision' view to differentiate between
'added' and 'replaced' items, and to make the fact that something was
or wasn't copied from elsewhere a first-class piece of data.

* viewcvs/lib/vclib/svn/__init__.py
  (_compare_paths): Move from the svn_ra module.
  (ChangedPath.__init__): Add 'is_copy' param, and stow it away.
  (ChangedPathSet): New.
  (get_revision_info): Use newer svn.repos.ChangeCollector() interface
    so we can hook the notification callback (using the new
    ChangedPathSet class) and get replacement information.

* viewcvs/lib/viewcvs.py
  (view_revision): Boolean-ify the new is_copy ChangedPath member.
    Expose change.log_href links to log views.
  (common_template_data): Expose log_href for Subversion directories.

* viewcvs/templates/docroot/styles.css
  (td, th, tr): Set vertical-align to 'top'.

* viewcvs/templates/revision.ezt
  Re-work this template into a different layout (still not happy it,
  but...)

* viewcvs/lib/vclib/svn_ra/__init__.py
  Import _compare_paths from the 'svn' module.
  (LastHistoryCollector.add_history): Tweak to recognize replaced
    items, and to pass the new 'is_copy' param to ChangedPath().
  (_compare_paths): Move to the 'svn' module.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1122 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-10 20:22:59 +00:00
cmpilato ef9e91dd20 * viewcvs/lib/viewcvs.py
(DiffSource._get_row): Rename 'line1' and 'line2' 'change' members to
    'line_info_left' and 'line_info_right', respectively.

* viewcvs/templates/diff.ezt
  Track renamed template variables.

* viewcvs/website/upgrading.html
  Document renamed variables.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1121 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-10 14:10:48 +00:00
cmpilato 0506513760 Expose "tip o' the branch" links from the log view.
* viewcvs/lib/viewcvs.py
  (view_log): Add new template variables: 'tag_view_href',
    'tag_download_href', 'tag_download_text_href', 'tag_annotate_href',

* viewcvs/templates/include/view_tag.ezt
  Expose links to the tip of a currently selected branch.

* viewcvs/website/upgrading.html
  Document new variables.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1116 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-03 22:23:35 +00:00
cmpilato 0881ded7c0 * templates/directory.ezt,
* templates/dir_alternate.ezt
  Lose unnecessary P tags which tend to oversize errorful rows.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1114 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-10-03 15:31:27 +00:00
cmpilato a16f40e0ac * viewcvs/templates/directory.ezt
Lose the alt-text on the row icons, and restore View/download distinction
  in title attributes.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1112 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-09-29 13:42:32 +00:00
cmpilato 97a07dc88e This patch (mostly by Marten Thavenius) upgrades ViewCVS to XHTML 1.0
Strict.  Changes have been made in the EZT templates, the CSS files,
HTML code embedded in the Python files as well as in the help
files. The original code structure and design is the very same.  No
other improvements have been made to the browser code and it still
uses the old layout tables to create the page grid.

Apart from the XHTML/CSS code changes, the patch adds an argument (-x
x) for CVSGraph in viewcvs.py in the view_cvsgraph function to tell
CVSGraph to generate XHTML code. For Mozilla/Firefox to recognize the
id attribute in the image map generated, the content-type must be set
to application/xhtml+xml (see
https://bugzilla.mozilla.org/show_bug.cgi?id=109445).  This patch does
however not change the content-type, but uses an ugly hack to make the
CVSGraph output work in Mozilla with the current text/html
content-type: a name attribute is merged into the id attribute in the
map_name defined in the cvsgraph.conf.dist file.

The XHTML code does not contain the standard XML declaration, just the
XHTML 1.0 Strict Doctype. This is to keep ViewCVS as encoding agnostic
as before and let the browser decide which encoding to use. An XML
file without the encoding declared must be interpreted as UTF-8 (or
UTF-16 if the byte order mark is included).

* viewcvs/cvsgraph.conf.dist
  Add name="" hack to the 'map_name' variable so Mozilla/Firefox will work.

* viewcvs/lib/ezt.py
  XHTML-ize sample output.

* viewcvs/lib/viewcvs.py
  XHTML-ize hard-coded output.
  (view_cvsgraph): Pass "-x x" to cvsgraph to force XHTML production.

* viewcvs/lib/blame.py
* viewcvs/lib/debug.py
* viewcvs/lib/py2html.py
* viewcvs/lib/query.py
* viewcvs/lib/vclib/bincvs/__init__.py
* viewcvs/templates/annotate.ezt
* viewcvs/templates/diff.ezt
* viewcvs/templates/dir_alternate.ezt
* viewcvs/templates/directory.ezt
* viewcvs/templates/error.ezt
* viewcvs/templates/graph.ezt
* viewcvs/templates/log.ezt
* viewcvs/templates/log_table.ezt
* viewcvs/templates/markup.ezt
* viewcvs/templates/query.ezt
* viewcvs/templates/query_form.ezt
* viewcvs/templates/query_results.ezt
* viewcvs/templates/revision.ezt
* viewcvs/templates/roots.ezt
* viewcvs/templates/docroot/help_dirview.html
* viewcvs/templates/docroot/help_log.html
* viewcvs/templates/docroot/help_logtable.html
* viewcvs/templates/docroot/help_query.html
* viewcvs/templates/docroot/help_rootview.html
* viewcvs/templates/docroot/styles.css
* viewcvs/templates/include/branch.ezt
* viewcvs/templates/include/branch_form.ezt
* viewcvs/templates/include/diff_form.ezt
* viewcvs/templates/include/dir_footer.ezt
* viewcvs/templates/include/dir_header.ezt
* viewcvs/templates/include/file_header.ezt
* viewcvs/templates/include/footer.ezt
* viewcvs/templates/include/header.ezt
* viewcvs/templates/include/paging.ezt
* viewcvs/templates/include/sort.ezt
* viewcvs/templates/include/view_tag.ezt
  XHTML-ize hard-coded output and templatized data.

* viewcvs/CHANGES
  Note this change.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1109 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-09-28 17:06:16 +00:00
cmpilato b629620cf6 Lose 'row.href' and 'row.rev_href' for the more meaningful
'row.log_href' and 'row.view_href'.

* viewcvs/lib/viewcvs.py
  (view_directory): For files, rename 'row.href' to 'row.log_href',
    and 'row.rev_href' to 'row.view_href'.  For directories, do the
    renames, but swap the mappings.

* viewcvs/templates/dir_alternate.ezt
* viewcvs/templates/directory.ezt
  Track the changes to these data dictionary items.

* viewcvs/website/upgrading.html
  Note the changed variables.  Also, add svn_path as a configuration
  parameter recently added.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1108 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-09-27 18:08:47 +00:00
cmpilato ac88e349ca Expose annotation support for local Subversion repositories. Patch
largely by Stefan Haller <haller@ableton.com>, at least in the
approach used.

* viewcvs/viewcvs.conf.dist
  (svn_path): New configuration variable.

* viewcvs/lib/config.py
  (Config.set_defaults): Populate a new svn_path config member.

* viewcvs/lib/viewcvs.py
  (Request.__init__): Tweak the way Subversion's vclib.Repository
    objects are opened to have different codepaths for the 'svn' and
    'svn_ra' modules, and pass the new cfg.general.svn_path option to
    the 'svn' module's SubversionRepository.

* viewcvs/lib/vclib/svn/__init__.py
  (BlameSource, BlameSequencingError, _item): New.
  (SubversionRepository.__init__): Add 'svn_path' parameter.
    Calculate and store a path for the 'svn' command-line client binary.
  (SubversionRepository.annotate): Really implement annotation.

* viewcvs/templates/log.ezt,
* viewcvs/templates/log_table.ezt
  Enable annotate links for Subversion, too!


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1100 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-09-23 20:15:08 +00:00
pefu adbaa3d909 Fixed SF-Bug # 1192503: Updated broken link to competing project cvsweb
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1090 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-09-13 22:04:24 +00:00
cmpilato bbd4c762cb * templates/docroot/images/broken.png
* templates/docroot/images/cvsgraph_16x16.png
* templates/docroot/images/cvsgraph_32x32.png
  More PNG background fixes from Jordan Russell <jr-list-2005@quo.to>.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1046 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-03-01 20:25:52 +00:00
cmpilato b1d10a7f96 Jordan Russell <jr-list-2005@quo.to> was kind enough to rework some of
PNG files to have white backgrounds so that wussie browsers that don't
support PNG transparency (like Internet Explorer) can deal with them.

* templates/docroot/images/back_small.png
* templates/docroot/images/logo.png
* templates/docroot/images/text.png
  Tweaked.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1045 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-28 15:54:15 +00:00
cmpilato 6355639d08 Provide the Subversion youngest revision, and a link to it, to the
directory view.  This is pretty common request, the most recent by
Sergio Rua <srua@plus.net>.

* viewcvs/lib/vclib/svn_ra/__init__.py
  (get_youngest_revision): New.

* viewcvs/lib/vclib/svn/__init__.py
  (get_youngest_revision): New.

* viewcvs/lib/viewcvs.py
  (view_directory): Re-organize some data dictionary stuffing (I
    really wish that *all* data dictionary parameters were initialized
    at the head of each view function so we can see a canonical list
    of those params, but maybe another day...).  Also, for 'svn'
    roottypes, populate a new 'youngest_rev' and 'youngest_rev_href'
    dictionary items.

* viewcvs/website/upgrading.html
  Document the new 'youngest_rev' and 'youngest_rev_href' template keys.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1044 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-28 15:40:08 +00:00
cmpilato ad0bc5c421 * viewcvs/templates/markup.ezt
This template was on crack.  The absence of a revision log was
  enough to turn of the display of almost all of the other interesting
  data, and turn on the display of data that was in one half redundant,
  and in the other half non-existant.  Good Lord...


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1043 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-25 15:59:20 +00:00
cmpilato f723597546 Now that Subversion's RA layer has a pleasant API (instead of a nasty
vtable structure), update the ViewCVS 'svn_ra' module to use it.  This
module now almost has total functional parity with the 'svn' module.

* viewcvs/lib/vclib/svn_ra/__init__.py
  Import the svn.ra module.
  (date_from_rev, created_rev): Actually flesh out these functions
    using the new RA capabilities.
  (LastHistoryCollector.add_history): Remove leading slashes from
    paths used to make ChangedPath items.
  (either_binary): Leave a TODO, with some optimization ideas.
  (SubversionRepository.__init__): Use the RA interface to fetch the
    youngest revision instead of a really kludgy (and more expensive)
    algorithm based on dirents.
  (FileDiff.get_files, SubversionRepository.openfile): Fixup the use
    of streams.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1038 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-17 19:01:46 +00:00
rey4 6b9207ab39 Add title attributes to directory links
* lib/viewcvs.py
  (view_directory):
    add new row.viewable attribute so it is possible to tell whether a file
    link goes to a checkout or markup page

* templates/directory.ezt:
    add title attributes


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1036 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-13 16:46:56 +00:00
rey4 605109cbfd Fix page title for repository listing page
* templates/include/header.ezt


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1026 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-06 19:49:30 +00:00
cmpilato 83af4b6b3d Move the magical 'Repository Listing' option to the top of the option set.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1025 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-05 16:52:12 +00:00
rey4 86a7feb403 Add unobtrusive link to repository listing view on the common page
headers.

* templates/include/header.ezt
    add "Repository Listing" option to the roots select box

* lib/viewcvs.py
  (Request.run_viewcvs):
    handle magic "roots" value submitted by the roots select box

  (common_template_data):
    add "view" template parameter


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1024 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-04 18:33:20 +00:00
rey4 56e7993f12 Add repository listing view. This change doesn't any links to the new
view because I'm not really sure where they would fit best in the UI.
So for now, the view is only visible when viewcvs.cgi is loaded
with no trailing path in the URL and either root_as_url mode is
enabled or default_root is not set.

* lib/viewcvs.py
  (Request.run_viewcvs, Request.get_link, nav_path, common_template_data,
   _views):
    add support for new view

  (view_roots):
    new function

* lib/config.py
  (Config.set_defaults):
    set default templates.roots option

* templates/roots.ezt
    new template

* viewcvs.conf.dist
  (templates/roots):
    new option

  (general/default_root, options/root_as_url_component):
    update documentation


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1023 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-04 18:32:32 +00:00
rey4 d0029c46d3 Add revision links to annotate view
* lib/viewcvs.py
  (view_markup, nav_header_data)
    move "view_href," "download_href," "annotate_href" assignments
    into nav_header_data

* templates/annotate.ezt
    add revision links here


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1015 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-03 13:03:19 +00:00
rey4 dc76b574a9 Clean up path handling in viewcvs views, eliminate unused template variables.
* lib/viewcvs.py
  (_path_join):
    new function

  (Request.run_viewcvs, nav_path, common_template_data, view_markup,
   view_log, view_cvsgraph, generate_tarball, view_query):
    use _path_join

  (nav_header_data):
    remove unused variables

* templates/graph.ezt
    don't use "path" variable


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1014 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-02-03 12:58:14 +00:00
rey4 99818c7cf0 Add a bunch of links between different views. Some of these links
were present in ViewCVS 0.9.2, but seem to have been inadvertently
removed since then.

* lib/viewcvs.py
  (common_template_data):
    set "up_href, "log_href," and "graph_href" template variables
    for files

  (view_markup):
    set "annotate_href"

  (view_directory):
    stop setting "up_href" here

  (view_log):
    stop setting "graph_href" and "back_url" here
    set "annotate_href" here

  (view_queryform):
    set "dir_href" here

* templates/annotate.ezt
* templates/diff.ezt
* templates/graph.ezt
* templates/log.ezt
* templates/log_table.ezt
* templates/markup.ezt
* templates/query_form.ezt
* templates/include/branch.ezt
    add links

* website/upgrading.html
    document changed variables


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1003 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-01-14 05:20:46 +00:00
rey4 0b8521ef61 Add viewcvs logo to the page across from the title.
* templates/include/header.ezt
    look at it go...


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1001 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-01-14 03:47:20 +00:00
rey4 c0110cacae Simplify page titles. Someone was getting a little - too crazy - with -
the: punctuation ;)

* templates/annotate.ezt
* templates/diff.ezt
* templates/graph.ezt
* templates/log.ezt
* templates/log_table.ezt
* templates/markup.ezt
* templates/query.ezt
* templates/query_form.ezt
* templates/query_results.ezt
* templates/revision.ezt
* templates/include/dir_header.ezt
* templates/include/header.ezt
  change titles

* lib/config.py
  (Config.set_defaults):
    remove "main_title" option

* viewcvs.dist.conf
    remove "main_title" option

* website/upgrading.html
    document removal of "main_title" option


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1000 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-01-14 03:40:55 +00:00
rey4 fdb5ced659 Templatize the clickable path in header.ezt.
* lib/viewcvs.py
  (clickable_path, _dir_url):
    removed

  (nav_path):
    new function, replaces clickable_path

  (common_template_data):
    set "nav_path" template variable with nav_path() instead of
    clickable_path()

  (view_directory, view_log, view_queryform, view_query):
    don't override 'nav_path' variable

* templates/include/header.ezt
    use changed 'nav_path' variable

* website/upgrading.html
    document changed 'nav_path' variable


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@995 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-01-13 17:30:45 +00:00
rey4 3d3554b07e Remove extra clickable paths from directory and markup pages.
* lib/viewcvs.py
  (view_markup):
    don't set 'nav_file' template variable

* templates/markup.ezt
    remove the clickable path right before the revision information

* templates/include/dir_header.ezt
    remove clickable path in "Current Directory" row of summary table

* website/upgrading.html
    add documentation on 'nav_file' template variable


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@994 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-01-13 16:55:48 +00:00
rey4 35c9d578f7 Add a promiment link to the log page on the markup page. ViewCVS 0.9.2
had one, but it got lost in the sauce.

* templates/markup.ezt
    add (log) link right before (download) and (as text) links


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@992 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-01-13 16:14:12 +00:00
rey4 77e0fd633a Add "Parent Directory" link in directory listings
* templates/directory.ezt
* templates/dir_alternate.ezt
    add "Parent Directory" rows

* lib/viewcvs.py
  (view_directory):
    set "up_href" template value

* website/upgrading.html
    document "up_href" variable


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@990 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-01-13 05:57:01 +00:00
rey4 7e897b10df Fix UnmatchedEndError in dir_alternate template.
* templates/dir_alternate.ezt
    remove unmatched [end]


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@989 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-01-13 05:38:13 +00:00
cmpilato 39d2eedd10 Fix Bugs item #1090934, reported by ahndee.
* lib/viewcvs.py
  (view_revision_svn): Convert 'text_mods' and 'prop_mods' members of
    each changed path item into EZT booleans.

* templates/revision.ezt
  Use if-any tests, instead of comparisons with "1", to determine if
  each changed path item has text or property mods.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@984 8cb11bc2-c004-0410-86c3-e597b4017df7
2005-01-06 20:27:27 +00:00
rey4 b6a4e521be Remove apache logo from default templates
* templates/include/footer.ezt
    Powered by... nothing :'(


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@980 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-12-06 01:45:59 +00:00
cmpilato b26f6c0e09 * viewcvs/lib/viewcvs.py
(view_log): Only show download hrefs for files, and make view hrefs
    for directories show the directory view.

* viewcvs/templates/include/branch.ezt
  Only display the view_href if it exists.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@962 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-10-20 16:27:04 +00:00
cmpilato 0540dd9c0a * lib/viewcvs.py
(view_log): Always expose the view_href and download_href.

* templates/log.ezt
* templates/log_table.ezt
  Lose the "if CVS" condition I added for some includes a while ago.

* templates/include/branch.ezt
  Always show bookmarkable links to HEAD/download.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@961 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-10-19 14:46:35 +00:00
cmpilato f570dd8bd6 Don't include the branch and view_tag templates for non-CVS log displays.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@947 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-10-13 18:19:14 +00:00
rey4 fd665fd18e Swap sorting arrows in directory view following a discussion on the
dev list that ended at

http://mailman.lyra.org/pipermail/viewcvs-dev/2004-September/001769.html

* templates/docroot/images/ascending.png
* templates/docroot/images/descending.png
* templates/docroot/images/down.png
* templates/docroot/images/up.png
    rename ascending and descending images to down and up based on the
    direction of the arrows

* templates/directory.ezt
* templates/dir_alternate.ezt
    update to use new image names


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@945 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-10-09 02:59:27 +00:00
rey4 267d335899 Combine "Dead Files" and "Files Shown" counts in directory listing
* templates/include/dir_header.ezt


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@941 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-10-08 23:51:55 +00:00
rey4 55aa1e3d12 Update the documentation so it's no longer an impediment to a 1.0
release. There's still a lot of room for improvement, but there
should be no gaping holes or inaccuracies.

* INSTALL
    update old paths

    remove mention of svn_parent_path

    remove advice about trailing slashes in the Troubleshooting
    section. They're nice, but optional now that we don't use
    relative links.

* README
    add pointer to windows/README

* templates/docroot/help_logtable.html
    document the missing columns

* website/upgrading.html
    document the configuration options

    add a word of advice about upgrading with custom templates


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@935 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-10-08 17:57:14 +00:00
rey4 22965539ff Make the navigation bar easier to read
* templates/docroot/styles.css
  (.vc_navheader):
    switch to gray background because blue links on purple background
    are hard to read

* header.ezt
  (nav_path):
    make it bold


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@930 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-09-27 21:01:06 +00:00
rey4 e80dfb1aa9 Now that we're using our own icons instead of the icons provided by Apache,
we can get rid of the alternative icons we provided for the standalone web
server and IIS. We can also get rid of the "icons" configuration option.

* lib/apache_icons.py
* tools/bin2inline_py.py
    removed, icons for the standalone server

* windows/icons/apache_pb.gif
* windows/icons/small/back.gif
* windows/icons/small/dir.gif
* windows/icons/small/text.gif
    removed, icons for IIS

* templates/include/footer.ezt
    point "Powered by Apache" image at /icons/apache_pb.gif instead of
    [icons]/apache_pb.gif

* standalone.py
  (apache_icons, icons_last_modified):
     removed

  (ViewCVS_Handler.do_GET):
    remove handling of /icons/ paths

  (serve):
    stop setting options.icons config value

* viewcvs.conf.dist
  (icons):
    removed

* lib/config.py
  (Config.set_defaults):
    stop setting default options.icons config value

* lib/viewcvs.py
  (common_template_data):
    don't set "icons" template variable

* windows/README
  (ICONS FOR IIS):
    removed

  (DOCROOT OPTIMIZATION):
    new section about the docroot parameter

* website/upgrading.html
    remove documentation for "icons" template variable, update
    documentation for "docroot"


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@923 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-09-25 00:00:31 +00:00
jhenstridge d027efa883 Copy online documentation, stylesheet and required images to
templates/docroot/

* templates/docroot/help_*.html, templates/docroot/styles.css: copied
  from website/
* templates/docroot/images/*: copied from website/images/ or from Apache.
  fix up the transparency on some of the PNGs (just 1-bit transparency
  though, so they work with IE).
* lib/viewcvs.py (view_doc): update to the new location for documentation.
  We can use the same location in the "installed" and "uninstalled" modes.
* viewcvs.conf.dist: update the comment about the docroot config value.
* templates/*.ezt: update for new icon locations.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@921 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-09-22 06:22:42 +00:00
jhenstridge b68ec0fda5 Fix some validity errors on the query_form.ezt template.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@919 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-09-14 08:56:18 +00:00
jhenstridge 7cce726069 Fix up validity errors due to non-escaped ampersands in URLs.
* lib/viewcvs.py: add an optional escape parameter to the get_url()
   method, that will entity escape the URL.
   Pass escape=1 to each call to get_url() that is used to construct a
   URL for display in a template.
 * lib/blame.py: fix up a small entity escaping problem here too.
 * templates/revision.ezt: fix up a few HTML validity errors in this
   template that were a lot more obvious after clearing up the other
   errors.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@918 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-09-14 08:49:32 +00:00
jhenstridge 302fa88601 * templates/include/dir_footer.ezt: get rid of validity error due to
misnesting of <form> and <table> tags.
* templates/include/diff_form.ezt: get rid of a similar problem in the
  diff form.
  Also simplify the form a bit for the case when there are no tags (ie.
  subversion).


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@916 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-09-03 12:31:59 +00:00
jhenstridge c969184313 * templates/directory.ezt, dir_alternate.ezt: make the sort order arrow
part of the header hyperlink.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@915 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-09-03 11:48:38 +00:00
cmpilato e376b03b6d * website/styles.css
Make the annotate data "smaller", and increase the padding between
  columns.

* viewcvs/templates/annotate.ezt
  Remove superfluous spaces in table cells.  Mozilla is rendering
  wrongly, presumably because the cells are using "nowrap" or "pre"
  whitespace handling.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@912 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-08-14 16:50:57 +00:00
cmpilato 2f0a5efaf1 Cleanup the new dead file handling code to be more template-friendly
(and honest).

* lib/viewcvs.py
  (view_directory): Always calculate the num_dead variable with
    truth.  Just because we aren't showing dead files doesn't mean they
    don't exist.

* templates/include/dir_header.ezt
  Provide a single place for reporting the number of, and toggling the
  display of, dead files.

* templates/directory.ezt
* templates/dir_alternate.ezt
  Stop handling dead file display toggling on what appears (and yet
  isn't) a per-item basis.  Also, use Apache's broken.gif as the icon
  for dead files.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@911 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-08-11 14:35:44 +00:00
rey4 4f1e9a7ce7 Update alternate template.
* templates/dir_alternate.ezt
    fix handling of attic directories as in templates/directory.ezt, rev 1.47


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@910 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-08-01 14:41:39 +00:00
rey4 f3ca45b9a0 Handle CVS Attic paths transparently in the bincvs module
instead of exposing them to users.

* templates/include/dir_footer.ezt
    add link to show dead files

* templates/directory.ezt
    remove code for detecting Attic entries,
    change (in the attic) caption to (dead)

* lib/viewcvs.py
  (Request.run_viewcvs):
    handle old Attic URL's by redirecting,
    remove unused request.full_name member

  (get_up_path, _re_up_attic_path, nav_header_data, generate_tarball,
   download_tarball):
    remove code for handling Attic directories

  (view_markup):
    remove unused "full_name" variable

  (view_directory):
    remove code for handling Attic directories,
    replace "no_match" template variable with "num_dead"

  (view_log):
    update call to get_up_path

  (view_annotate, view_cvsgraph_image, view_cvsgraph, view_diff):
    use CVSRepository.rcsfile to get path to rcs file

* lib/vclib/bincvs/__init__.py
  (CVSRepository.itemtype):
    look in Attic for repository files

  (CVSRepository.listdir):
    remove "cvs_list_attic" option, now always list attic files.
    leave "Attic" and "CVS" directories out of returned listing.

   (CVSRepository.rcsfile, CVSRepository._atticpath):
     new methods

   (BinCVSRepository.openfile, BinCVSRepository.filelog):
     use CVSRepository.rcsfile to get path to rcs file

   (_get_logs):
     don't mark directories as dead

* lib/vclib/ccvs/__init__.py
   (CCVSRepository.filelog, CCVSRepository.openfile):
     use CVSRepository.rcsfile to get path to rcs file

* website/upgrading.html
    document "no_match" and "num_dead" template variables


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@908 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-31 22:34:51 +00:00
rey4 98b799adbf Improve error handling in directory view.
* 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
2004-07-31 14:38:03 +00:00
jhenstridge 7a0284214c * templates/include/header.ezt: remove stray </h1> tag.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@903 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-28 02:51:40 +00:00
jhenstridge 85d9d50631 * diff_form.ezt: wrap the text associated with the "makepatch" checkbox
in a <label> element, so that users can click on the text to toggle
  the value.
  Quote a few unquoted attribute values.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@901 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-26 08:17:15 +00:00
jhenstridge c3aff09497 * lib/viewcvs.py, templates/log.ezt, templates/log_table.ezt: revert
change that moved generation of human readable diff URLs from the
  templates to the Python code.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@899 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-24 16:34:04 +00:00
jhenstridge 4e573ace1d Fix up the diff links when diff_format is set to a non-default value on
the log pages.

* templates/include/diff_form.ezt: if no tags exist for the file, don't
  show the drop down tag selection box.  This gets rid of some unneeded
  UI when browsing Subversion repositories.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@897 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-23 12:43:11 +00:00
jhenstridge 198923b18a * viewcvs.py: add code to calculate various diff URLs used in the log
view.  For Subversion repositories, these URLs are usually shorter
  (only include p1/p2 when paths differ) and handle a few corner
  cases w.r.t. moves that the old code didn't.

* log.ezt, log_table.ezt: use the diff URLs passed in from viewcvs.py
  rather than constructing them in the template.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@896 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-23 11:28:30 +00:00
jhenstridge 4f348926fe Add thead/tbody tags to log_table.ezt, query.ezt and revision.ezt
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@895 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-23 09:55:50 +00:00
jhenstridge 09165074cf set size of sort arrow images, so that they don't cause reflows while
loading.  Wrap the column headers in a <thead> tag, and the rest of
the elements in a <tbody> tag.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@894 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-23 08:43:04 +00:00
jhenstridge 0f89aa8265 Add vc_log CSS class to log message on revision.ezt template. Fix from
Simon Lieschke (patch #995667)


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@893 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-22 10:08:29 +00:00
jhenstridge 247234ff03 Add support for generating backout scripts from query results like Bonsai
can.  Suggested in Bug #777122.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@890 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-22 02:10:51 +00:00
jhenstridge af221adef2 Use a different parameter name for the query sort key so that it doesn't
get mixed up with the directory view sort (similar to how the log view
uses logsort as a parameter name).

Don't display the branch column in results for a subversion repo query.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@889 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-21 16:01:09 +00:00
jhenstridge f2d02f282b Update get_link() to add a rev parameter for diff links on subversion
repositories (sets rev to the same value as r2).

Update run_viewcvs() so that if no view is selected, handle requests
that specify r1,r2,rev as diffs rather than checkouts, and requests
that specify r1,rev as logs.

Update log.ezt and log_table.ezt to set the rev parameter in the diff
links when browsing subversion repositories.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@888 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-21 15:46:47 +00:00
jhenstridge cc970525ac Simplify column sort code, so that clicking the sort column header
reverses the sort order, while clicking on other headers sorts by
that column in ascending order.  This matches how most GUIs handle
sorting in columned lists.

Also port the sort handling from dir_alternate.ezt to directory.ezt
to reduce differences between the two templates.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@886 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-21 14:58:30 +00:00
jhenstridge 57c58fde9b Fix up dir_alternate.ezt template to fix bug #995121 (switch the
pathname and revision links for directories).

Previously dir_alternate.ezt was broken for CVS repositories, resulting
in a traceback since it was trying to show the log href which doesn't
exist.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@885 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-21 12:17:50 +00:00
jhenstridge 55bdd8cb45 Convert double dashes in comment to single dashes, since the double dash
ends the comment.  Mentioned in a Debian bug report:
  http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=245550

Add a <meta name="generator"> tag to the top listing the version of
viewcvs used to generate the page.  This is less likely to be removed
from custom templates, and should be helpful when tracking bugs.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@884 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-20 07:26:52 +00:00
jhenstridge 31ac07eb78 render all revision log messages as <pre class="vc_log">...</pre>
Add CSS for vc_log to set it italic (as it was already shown in most places),
and set some proprietary properties to turn on word wrapping for Mozilla,
Opera and IE, and the equivalent standard CSS3 property (for when browsers
support it).


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@882 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-19 08:49:39 +00:00
jhenstridge 8a3030d4cf use CSS classes for the different columns in annotate mode. In particular,
set "white-space: pre" for the text column, so that white space isn't
collapsed.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@881 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-18 11:11:56 +00:00
jhenstridge 236668b628 Expose glob matching and notregex matching in query_form.ezt.
Loosen some of the parameter validation to _validate_regex for
branch, file and who query parameters.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@880 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-18 06:37:31 +00:00
jhenstridge 7ad43eaa74 Port the "diff link" support over to the query.cgi script.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@878 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-17 06:46:02 +00:00
jhenstridge d8cc63ee4e Add simple querying support directly to the viewcvs script. This is
closer to the Bonsai query interface, and provides better integration
with the rest of viewcvs.

Fixed two bugs in cvsdb.py:
 - when loading up query results, set the checkin type on the Commit object
 - When sorting on file name or author, order by the name rather than ID.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@877 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-17 06:03:33 +00:00
jhenstridge a6ae62b59f 1) add a bit of documentation on using svndbadmin to load revision
information into the query database.
2) Update query.cgi to set [docroot] correctly.  This allows it to find
   the stylesheet, and corrects the help link in the footer.
3) Results could point at subversion repositories, so check if the
   repository is in svn_roots too.
4) Only display repository names rather than paths in the results.
   This matches what viewcvs.cgi shows the user.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@875 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-16 16:39:46 +00:00
cmpilato 648ac31eb3 * viewcvs/lib/viewcvs.py
(list_roots): Make the roots hash values into tuples, adding the roottype.
  (common_template_data): Make the 'roots' list items into hashes that
    carry the root names and types.

* viewcvs/templates/include/header.ezt
  Split the list of repositories up into CVS ones and Subversion ones
  using optgroups.  Note the super-cool single pass over the roots,
  appending options to variables created on-the-fly.  Have I mentioned
  how much I love James Henstridge today?


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@871 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-16 14:11:55 +00:00
cmpilato 1b68297aff Makin' things purtier. Patch by James Henstridge <james@jamesh.id.au>.
* viewcvs/templates/log_table.ezt
  Set the HTML class attribute to vc_header_sort for the header of the
  sort column.  Change the tags around the log message from
  <i><pre>...</pre></i> to <pre><i>...</i></pre>.  Since <pre> is a
  block level element and <i> is an inline element, the old nesting
  results in an extra block after the message in the table cell.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@866 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-07-01 20:56:38 +00:00
cmpilato 7b8eb7639e Instead of sending colored diffs to the diff.ezt template, and raw
diffs to their own text/plain output, templatize all diffs.  By
default now, all diffs will go through diff.ezt (which has been
updated to handle it).  Only if the new 'makepatch' boolean CGI flag
is set will diffs be sent directly as text/plain, non-templatized
output.

* viewcvs/lib/viewcvs.py
  (_legal_params): Add new 'makepatch' boolean parameter.
  (check_freshness): Fix a speeling eror.
  (MarkupPipeWrapper.__init__): Add 'htmlize' parameter, and use it.
  (human_readable_diff): Lose the 'request', 'sym1', and 'sym2'
    parameters.  Now return the parsed dates and DiffSource object
    instead of populating a data dictionary and completely generating
    the page.
  (spaced_html_text): Use an intermediate variable for readability.
  (raw_diff): New.
  (view_diff): Honor the new 'makepatch'.  Update calls to
    human_readable_diff(), and make use of raw_diff().  Do all page
    generation for diffs here now.  Adds a new 'raw_diff' data
    dictionary item, useful for testing raw vs. colored, as well as
    for positioning that raw diff output in the template.

* templates/diff.ezt
  Use the new 'raw_diff' data dictionary item to position raw diff
  output in the template.  Update the diff form to allow for the
  generation of traditional "patch-ish" raw diff output.

* templates/include/diff_form.ezt
  Allow for the generation of traditional "patch-ish" raw diff output.

* website/styles.css
  (vc_raw_diff): New style class.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@864 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-06-22 14:37:11 +00:00
cmpilato 71b16e1321 *** empty log message ***
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@849 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-05-12 01:46:43 +00:00
cmpilato af1f78ba83 * viewcvs/templates/include/dir_footer.ezt
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
2004-05-11 06:53:52 +00:00
cmpilato a0bc4d071b * viewcvs/lib/viewcvs.py
(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
2004-05-10 15:37:11 +00:00
cmpilato d0a62c7520 Try to get the query.cgi script working again. Unfortunately, I'm not
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
2004-04-28 15:53:39 +00:00
cmpilato 1d6743ab98 * viewcvs/templates/revision.ezt
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
2004-04-28 14:53:22 +00:00
cmpilato 5995f83c4c Some more ViewCVS fixes and tweaks.
* 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
2004-04-24 17:38:31 +00:00
cmpilato da21434ef0 Some bug fixes as suggested (in great detail, just short of a patch)
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
2004-04-22 15:40:01 +00:00
cmpilato 0f09f6c241 Templatize the annotate view!
* 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
2004-04-21 05:08:12 +00:00
cmpilato a8c5db6248 Templatize the markup view.
* 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
2004-04-20 16:40:12 +00:00
cmpilato cf04879462 Oops! Missed an update of a relocated template.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@825 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-04-15 20:37:59 +00:00
cmpilato ba43e61754 Re-arrange the templates directory a bit.
* viewcvs/templates/dir_footer.ezt
* viewcvs/templates/dir_header.ezt
* viewcvs/templates/footer.ezt
* viewcvs/templates/header.ezt
  Move all of these...

* viewcvs/templates/include/dir_footer.ezt
* viewcvs/templates/include/dir_header.ezt
* viewcvs/templates/include/footer.ezt
* viewcvs/templates/include/header.ezt
  ...to here.

* viewcvs/templates/annotate.ezt
* viewcvs/templates/diff.ezt
* viewcvs/templates/dir_alternate.ezt
* viewcvs/templates/directory.ezt
* viewcvs/templates/graph.ezt
* viewcvs/templates/log.ezt
* viewcvs/templates/log_table.ezt
* viewcvs/templates/markup.ezt
* viewcvs/templates/query.ezt
  And then update the [include] items in these files to note the new
  locations of the aforementioned relocated templates.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@824 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-04-15 05:57:57 +00:00
cmpilato 1b8e7c9aa5 Do some work to expose Subversion directory commit info (logs,
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
2004-04-15 05:27:55 +00:00
cmpilato fe97494fd0 Fix copyfrom links in the Subversion log view.
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
2004-03-08 16:41:37 +00:00
rey4 05888638d0 Make view/download links on log and markup pages simpler and more uniform.
I didn't like a number of things about previous interface, like how it:
 - inconsistently made some links pop up and others open in the same window
 - used inconsistent terminology, "view" links lead to markup pages in some
   cases and direct downloads in others
 - omitted useful links, there were no direct download links for images and
   no markup or "as text" links for "nonviewable" files (like text files
   that ending in .doc)
 - inserted extraneous punctuation, in lines like
   "Revision 1.1 - , (view/download)"

There's some more information about this change posted on the dev list:
http://mailman.lyra.org/pipermail/viewcvs-dev/2004-January/001337.html


* lib/viewcvs.py:
  (view_markup, view_log):
    set new template variables that have the same names and functions on
    all pages: "view_href", "download_href", and "download_text_href"

* templates/log.ezt
* templates/log_table.ezt
* templates/include/branch.ezt
* templates/markup.ezt
    use new template variables and get rid of pop-up links

* templates/dir_alternate.ezt
* templates/directory.ezt
    get rid of pop-up links

* website/upgrading.html
    describe changed variables


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@788 8cb11bc2-c004-0410-86c3-e597b4017df7
2004-01-21 22:50:26 +00:00
rey4 a478890739 Restore "this entry is unreadable" error messages that got mistakenly
suppressed in revision 1.205 of viewcvs.py.

* lib/viewcvs.py:
  (view_directory_cvs):
    stop skipping unreadable rows. also simplify row.name initialization
    by omitting trailing slashes for directory names

  (view_directory_svn):
    omit trailing slashes from directory names

* templates/directory.ezt
* templates/dir_alternate.ezt
    add trailing slashes to directory names


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@755 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-10-25 04:17:06 +00:00
cmpilato 551a38195c * viewcvs/lib/viewcvs.py
(view_revision_svn): Calculate links to the previous and next
    revisions, as well as a jump-box for whatever revision you so
    desire.

* viewcvs/templates/revision.ezt
  Add UI for navigating to previous and next revisions, for jumping to
  any particular revision you like.

* viewcvs/lib/vclib/svn/__init__.py
  (date_from_rev, fetch_log): Stop recalculating the youngest rev.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@752 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-10-24 19:27:02 +00:00
uid99421 c0a6d838c6 * templates/revision.ezt:
add the standard page header to the new revision page


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@744 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-10-23 19:23:26 +00:00
cmpilato a33f547c1e * viewcvs/lib/viewcvs.py
(view_revision_svn): Oops.  Fix the prev and diff_href calculations.

* viewcvs/templates/revision.ezt
  Fix some logic to always populate the right number of cells.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@741 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-10-22 18:35:56 +00:00
cmpilato 9d5d4170f9 More work on the cool new revision view.
* viewcvs/lib/vclib/svn/__init__.py
  (LogEntry.__init__): Remove 'other_paths' parameter and support.
  (ChangedPathEntry): Remove.
  (ChangedPath, get_revision_info): New.
  (log_helper): Don't do changed-path or action stuffs.  Update call
    to LogEntry().
  (get_logs): Update call to LogEntry().

* viewcvs/lib/viewcvs.py
  (view_log_svn): Remove support for 'other_paths' support.
  (view_revision): Move svn-specific stuff to new view_revision_svn()
  (view_revision_svn): New.

* viewcvs/templates/revision.ezt
  Make this template actually do something useful.

* viewcvs/templates/log.ezt
* viewcvs/templates/log_table.ezt
  Remove display of "other_paths" from Subversion logs.  Make revision
  numbers into links to the revision view.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@740 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-10-22 18:23:01 +00:00
cmpilato 45629a7dde Begin implementing the new 'revision' view.
* viewcvs/lib/viewcvs.py
  (Request.get_link): Add code to generate the new revision info links.
  (view_revision): New.
  (_views): Alphabetically sort the views here, and add the new 'rev' view.

* viewcvs/viewcvs.conf.dist
  (templates.revision): New.

* viewcvs/templates/revision.ezt
  New.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@737 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-10-21 20:04:30 +00:00
rey4 131904872c Stop looking up "action" values for subversion log entries. C. Mike
pointed out that will ultimately allow us to get rid of an inefficient
call to svn_fs_paths_changed().

* lib/vclib/svn/__init__.py
  (LogEntry.__init__, log_helper, get_logs):
    no longer set LogEntry.action member

* templates/log.ezt
* templates/log_table.ezt
    stop trying to read LogEntry.action member


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@729 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-10-17 17:56:44 +00:00
cmpilato 4e5303978a Expose the actions for "other changed paths".
* viewcvs/lib/vclib/svn/__init__.py
  (ChangedPathEntry.__init__): Add 'action' parameter.
  (_unparse_action): New helper (with code previously in log_helper()).
  (log_helper): Now call _unparse_action() to get the action string
    for the path.  But now also call it for the other paths, passing
    the result to the updated ChangedPathEntry.__init__() function.

* viewcvs/templates/log.ezt
* viewcvs/templates/log_table.ezt
  Now show the type of change that happened for "the other paths", and
  don't make paths that were deleted into hyperlinks.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@728 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-10-16 14:41:10 +00:00
cmpilato 9a8d5d115b Whip 'select for diffs', 'diff to previous', and 'diff to selected'
into shape for Subversion.

* viewcvs/lib/viewcvs.py
  (view_log): Grab the path of a version selected for diffs from the
    query data, and stash it in the data dictionary.

* viewcvs/templates/log_table.ezt
* viewcvs/templates/log.ezt
  Fix the 'diff to previous', 'diff to selected', and 'select for
  diff' links for Subversion.  Also, don't display the various "branch
  point" and "next main" diff links for Subversion.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@720 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-10-15 16:42:02 +00:00
rey4 22aeba1b38 * templates/log_table.ezt: sync up with log.ezt 1.26
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@714 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-10-03 22:10:19 +00:00
cmpilato 4f46a705e2 Some fix-em-ups to the new history-using ViewCVS code. Thanks to Greg
Stein and Russell Yanofsky for review and suggestions.

* lib/vclib/svn/__init__.py
  (log_helper): Add 'pool' argument, and use it instead of
    svnrepos.pool for allocations.  Also, calculate the action and
    copy_rev/copy_path fields in the log entries.
  (fetch_log): Use an iteration subpool when looping over history items.

* templates/log.ezt
  Eliminate an unnecessary "if-any" check (since "is" does this work
  for us in this case).


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@713 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-09-30 13:58:44 +00:00
cmpilato f808704efe * viewcvs/lib/vclib/svn/__init__.py
(log_helper): Populate the 'action' attribute of the LogEntry.

* viewcvs/templates/log.ezt
  Expect human-readable strings for the action type (instead of the
    single-character abbreviations).


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@712 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-09-26 14:29:07 +00:00
cmpilato 7eae388966 Make "diff to previous" for across Subversion copies work.
* viewcvs/lib/viewcvs.py
  (_legal_params): Allow 'p1' and 'p2' query args.
  (view_log_svn): Populate prev_path entry members.
  (view_diff): Handle the 'p1' and 'p2' query string items.  Update
    call to vclib.svn.do_diff().

* viewcvs/templates/log.ezt
  Update "diff to previous" links to include prev_path.

* viewcvs/lib/vclib/svn/__init__.py
  (do_diff): Add (and use) 'path2' argument.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@710 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-09-26 02:58:59 +00:00
cmpilato c77b65be9d * templates/dir_alternate.ezt
* templates/directory.ezt
* templates/markup.ezt
* templates/include/branch.ezt
  s/resizeable/resizable/.  This fixes Bug issue #756811.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@705 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-08-24 05:20:55 +00:00
cmpilato 5e834c47e7 Fix directory templates to properly handle missing graph_href's (like,
for example, which using Subversion).  This fixes #Bugs item #793866,
reported by Timothee Besset.

* templates/dir_alternate.ezt
* templates/directory.ezt


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@704 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-08-24 05:06:41 +00:00
rey4 1ce3cc2174 Fixed bug in html form that was reported by John Hall
<john-news1@cambridgetechgroup.com>.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@699 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-08-10 01:25:44 +00:00
rey4 66bb812aeb * lib/viewcvs.py (common_template_data): new function to set a few variables
common to all templates

  (Request.__init__): moved icon and docroot initialization into
  common_template_data

  (html_footer, view_directory, view_log, view_markup, view_checkout,
   view_cvsgraph, human_readable_diff): changed to use common_template_data

* templates/dir_alternate.ezt:
  templates/directory.ezt:
  templates/graph.ezt:
  templates/header.ezt:
  templates/log.ezt:
  templates/log_table.ezt:
  templates/query.ezt: renamed docroot and icon variables

* website/upgrading.html: updated description of changed template variables


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@692 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-07-25 05:34:11 +00:00
rey4 5d4c447dd4 added "icons" and "docroot" options to control the locations of
static files

* viewcvs.conf.dist, lib/config.py: added new options

* templates/dir_alternate.ezt:
* templates/directory.ezt:
* templates/header.ezt:
* templates/log.ezt:
* templates/log_table.ezt:
* templates/query.ezt:
* lib/viewcvs.py (Request.__init__):
  new "request.docroot" and "request.icons" template variables

* standalone.py (serve): standalone server must use default locations


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@690 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-07-24 20:37:39 +00:00
cmpilato 69e5862d59 * viewcvs/lib/viewcvs.py
(markup_stream): Get log message and size display as part of the
    markup output working for Subversion.

* viewcvs/templates/markup.ezt
  Add display of file size for Subversion repositories, and make the
    'changes since' line CVS-only.

* viewcvs/lib/vclib/svn/__init__.py
  (StreamPipe.read, StreamPipe.readline): Don't try to read if EOF
    has been hit.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@681 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-07-07 14:43:50 +00:00
rey4 94102ae7ae updated alternate template files
* dir_alternate.ezt: updated with recent changes to directory.ezt

* log_table.ezt: updated with recent changes to log.ezt


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@679 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-07-05 16:52:31 +00:00
rey4 eb16ebf2ce removed empty column from directory information table and added missing
</tr> closing tag


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@678 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-07-05 16:51:08 +00:00
rey4 c6ddff38ef Added some new fields to the Subversion log view and fixed the
download/view/markup links for old revisions of copied files.

The new fields are "Other changed files" which is a list of links to other
files changed in the same revision, "Copied from" which is displayed for
file revisions that are the result of a copy operations, and "Filename"
which is displayed for older file revisions which precede a copy operation.

* viewcvs.conf.dist
* lib/config.py (set_defaults): added "show_changed_paths" option to determine
  whether or not to retrieve and display the new information

* lib/viewcvs.py (run_viewcvs): now passes show_changed_paths option to
  newly created subversion repository objects

  (view_log_svn): changed the way download/view/markup links are generated
  and added code to generate links for new fields

* templates/log.ezt: template additions

* lib/vclib/svn/__init__.py (LogEntry.__init__): added extra arguments for new
  fields

  (ChangedPathEntry): new class to hold information about the changed paths
  associated with a revision

  (LogReceiver.__init__): added some new members to hold more state for the
  callback function

  (LogReceiver.receive): added some code to crawl through the "paths" hash
  and save useful information

  (get_logs): changed to work with new LogReciever constructor

  (fetch_log): changed call to repos.svn_repos_get_logs() to pass true for the
  "discover_changed_paths" argument. moved fs.file_length() call into
  LogReceiver.__init__


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@675 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-07-03 06:20:24 +00:00
rey4 61406314a9 Changes intended to simplify handling URLs in ViewCVS. Nearly all
links between ViewCVS pages are now constructed by a new Request
method called "get_link," and all URL parsing happens in another new
Request method called "run_viewcvs."

I also added support for a new optional parameter called "view." It
provides a more uniform way of linking to ViewCVS pages, so you can
say

  /viewcvs/dir/file.txt?view=log
  /viewcvs/dir/file.txt?view=co
  /viewcvs/dir/file.txt?view=annotate
  /viewcvs/dir/file.txt?view=markup

instead of

  /viewcvs/dir/file.txt
  /viewcvs/*checkout*/dir/file.txt
  /viewcvs/dir/file.txt?annotate=head
  /viewcvs/dir/file.txt?rev=HEAD&content-type=text/vnd.viewcvs-markup

Changes which are not backwards compatible had to be made to some
template files. Old templates will not work with the new code.


* templates/include/branch_form.ezt:
* templates/include/diff_form.ezt:
* templates/include/paging.ezt:
* templates/include/sort.ezt:
* templates/diff.ezt:
  changed to use form action and hidden fields provided by the script

* templates/directory.ezt: got rid of relative urls, changed to use
  form action and hidden fields provided by the script

* templates/graph.ezt: changed to take image path from the script

* templates/header.ezt: got rid of "qquery" variable

* templates/log.ezt: changed the way diff and annotate links get
  constructed

* lib/viewcvs.py (Request.__init__): moved out url parsing stuff into
  new "run_viewcvs" method.

  (Request.run_viewcvs): new Request method to hold all url parsing
  code and replace the global function with the same name.

  (Request.get_url, Request.get_link): new methods to construct urls
  for ViewCVS pages. Most of the hyperlinks that appear in generated
  pages are now made by these functions.

  (get_up_path): turned off special handling of attic directory for
  subversion, switched names of regular expressions

  (_legal_params, _validate_param, _validate_root): added new 'view'
  parameter, turned off separate validation for root parameter

  (_re_validate_revnum): allow empty string to be specified as a
  revision number. needed to prevent validation error when doing a
  regular expression search on the cvs trunk (which sets
  only_with_tag to "")

  (_strip_suffix, _repos_pathtype): added some new helper functions

  (sticky_query, toggle_query, download_url): removed these functions,
  Request.get_url() is now used instead.

  (clickable_path, prep_tags, augment_entry): changed signatures and
  implementations to use Request.get_url

  (is_viewable, is_viewable_image): changed is_viewable() to
  is_viewable_image() to avoid overlap in functionality with is_text()

  (nav_header_data): got rid of 'qquery' template parameter, changed
  'file_url' to use an absolute pathname instead of a relative one

  (view_auto): new function that marks up the current file if it is
  viewable, otherwise downloads it. called when a user clicks on the
  revision numbers in directory listings.

  (view_markup, markup_stream): renamed markup_stream to view_markup
  and changed signature

  (get_file_data_svn): no longer tries to generate physical pathnames
  for subversion files since the values it did generate were
  meaningless and were ignored anyway.

  (get_file_data): changed docstring

  (prepare_hidden_values): changed signature

  (view_directory, view_directory_cvs, view_directory_svn): factored
  out some of the common parts of view_directory_cvs and
  view_directory_svn functions into a new function called
  view_directory. implementations were also changed to use new get_url
  and get_link functions

  (view_log, view_log_cvs, view_log_svn): ditto

  (process_checkout): changed signature and moved in support for
  subversion

  (view_checkout, search_files): changed implementations to deal with
  new url handling, and the changes to process_checkout.

  (view_annotate, human_readable_diff, download_tarball): changed to
  use new url methods

  (view_cvsgraph): changed signature to be consistent with
  view_checkout, view_annotate, view_markup, etc. Added new template
  parameter 'imagesrc' so the graph url doesn't have to
  be hardcoded in the template.

  (cvsgraph_image, view_cvsgraph_image): renamed cvsgraph_image to
  view_cvsgraph_image and changed its signature (also for consistency
  with the other view_* functions).

  (_views, _view_codes): new dictionary objects mapping "view"
  parameter values to functions that produce various viewcvs pages.

  (handle_config): got rid of global "default_settings" dictionary

  (run_viewcvs): replaced by Request.run_viewcvs

  (main): now calls Request.run_viewcvs()


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@667 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-07-01 08:35:28 +00:00
cmpilato 0a88d6f1a6 * viewcvs/lib/vclib/svn/__init__.py
(get_logs, fetch_log): Add file sizes to file LogEntry() items.

* viewcvs/templates/log.ezt
  Add file size display for Subversion repositories.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@665 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-06-26 19:54:13 +00:00
cmpilato dd34c9fd4c Implement templatized error messages. Thanks to Russell Yanofsky
<rey4@columbia.edu> for bringing sanity to my morning with his fix of
the "isinstance()" usage.

* viewcvs/lib/config.py
  (set_defaults): Add new default value for self.templates.error.

* viewcvs/viewcvs.conf.dist
  (error): New configuration variable for specifying the error template.

* viewcvs/templates/error.ezt
  New default error template.

* viewcvs/lib/debug.py
  (ViewCVSException.__init__): Lose the 'description' member.
  (PrintException): Now prints exception data passed in (doesn't do
    the sys.exc_info() call itself any more).
  (GetExceptionData): New generic exception data harvester for use
    with templatized output.

* viewcvs/lib/viewcvs.py
  (view_error): New error printer that tries to use the error template
    before falling back to direct output.

* viewcvs/lib/query.py
  Update calls to debug.PrintException() to get the exception data
  from debug.GetExceptionData()


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@664 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-06-26 18:18:41 +00:00
cmpilato f6a150d62b Fix a template bug reported by Branden Robinson <branden@deadbeast.net>.
* templates/include/branch_form.ezt
* templates/include/diff_form.ezt
* templates/include/sort.ezt
  Use an action="" value in these forms that can deal with both states
    of the root_as_url_component option.

* lib/viewcvs.py
  (view_log_cvs, view_log_svn): Add 'current_root' to the data
    dictionary.  This is "just because", not really related to the bugfix.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@662 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-06-25 20:32:03 +00:00
cmpilato 5473b5d8d4 No longer display "Changes since" for non-CVS repositories
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@646 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-04-29 20:32:51 +00:00
rey4 561a2074d3 - removed hardcoded links in query page
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@597 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-02-11 02:55:40 +00:00
timcera bd78d04280 Bolding revision number. See patch
http://sourceforge.net/tracker/index.php?func=detail&aid=621979&group_id=18760&atid=318760


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@582 8cb11bc2-c004-0410-86c3-e597b4017df7
2003-02-01 05:02:09 +00:00
cmpilato 5a5450e4c9 Implement alternative URL scheme, and make Subversion a little more
public.  Miscellaneous Subversion bug fixes, too.

* viewcvs/lib/config.py
  (Config.set_defaults): Add default state for 'root_as_url_component'
    option.  Remove "CVS" from the 'general/address' and
    'general/main_title' default values.

* viewcvs/cgi/viewcvs.conf.dist
  Lots of documentation changes in here.
  (root_as_url_component, svn_roots, svn_parent_path): New options.
  (address, main_title): Lose the "CVS" in the value.

* viewcvs/lib/viewcvs.py
  (Request.__init__): Handle the new 'root_as_url_component' option.
  (list_roots): New.
  (clickable_path, download_url): Take any embedded roots into account
    during href generation.
  (view_diff): Fix the revision parsing here.  I dunno why I ever made
    this code CVS-specific in the first place...
  (view_log_svn): Populate 'roottype' data member.
  (view_log_cvs): Was view_log().  Populate 'roottype' data member.
  (view_directory_cvs, view_directory_svn): Use new list_roots()
    helper.  Also, calculate 'nav_path' unconditionally (it may be
    None, but it will at least be defined so templates can use it).
  (main): Update call to view_log_cvs().

* templates/directory.ezt
* templates/dir_alternate.ezt
  Take 'embedded_root' into account for href generation.

* templates/log.ezt
  Do some "CVS" vs. "Subversion" string changing.  Disable "annotate"
  link for Subversion.

* templates/log_table.ezt
  Disable "annotate" link for Subversion.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@575 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-12-12 02:02:52 +00:00
cmpilato 794354e63a * viewcvs/templates/directory.ezt
* viewcvs/templates/dir_alternate.ezt
  Make the [hide] link conditional on the presence of the
    'attic_showing' data member. Also, treat the directory named 'Attic'
    special only for cvs roottypes.

* viewcvs/lib/viewcvs.py
  (view_directory_cvs): Setup the new 'attic_showing' data member.
  (view_directory_svn): Don't bother with the 'hide_attic_href' and
    'show_attic_href' data members.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@573 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-11-15 00:11:57 +00:00
gstein 43c6a836e4 Fix the URL construction to use entities for the ampersands.
Submitted by: Ville Skytt� <scop@users.sourceforge.net>


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@569 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-10-10 23:08:52 +00:00
gstein c82276049a Various changes:
- remove diff_font_face/size options and move the font stuff from code
  to the diff.ezt template
- move error() back to viewcvs.py and have config.py raise an
  exception (so config doesn't have to know about CGI stuff)
- revamp SVN parent path stuff to avoid catch-all try/except

* cgi/viewcvs.conf.dist: remove the diff_font_face and diff_font_size
    options. These are now part of the diff.ezt template.
    COMPAT BUSTER

* templates/diff.ezt: need to apply font changes since the EZT
    references no longer include them.

* lib/viewcvs.py:
  (error): moved (back) here from config.py
  (DiffSource._get_row): stop inserting HTML into the values; leave
    that for the template to do however it wants
  (handle_config): catching all exceptions is very, very dangerous.
    rework this code to avoid exceptions thru the use of
    os.path.exists() and wrap an OSError exception catcher around the
    small little bit that might throw it.

* lib/config.py:
  (error): shifted back to viewcvs.py
  (_parse_roots): shifted below the "important" part of this file,
    which is the config stuff. changed the error handling to throw an
    exception rather than call error()
  (MalformedRoot): new exception. note that ViewCVS includes code for
    catching exceptions and pretty-printing them to an HTML page, so
    we don't need a specific catch of this exception.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@564 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-10-09 04:04:03 +00:00
cmpilato 8fdacfb716 Finish getting that enscript stuff working for Subversion, and
implement rudimentary directory version jumping.

* viewcvs/lib/vclib/svn/__init__.py
  (date_from_rev): New.
  (StreamPipe): new class.
  (get_file_contents): now returns StreamPipe object.

* viewcvs/templates/directory.ezt
  Get some subversion directory-revision-jumping UI action on.

* viewcvs/lib/viewcvs.py
  (Request.__init__): Allow 'HEAD' as incoming 'rev' option.
  (view_checkout): Use new get_file_contents() return.
  (view_directory_svn): Populate new 'roottype', 'tree_rev' and
    'jump_rev' data members.
  (view_directory_cvs): Populate new 'roottype' data member.

* viewcvs/lib/config.py
  (set_defaults): Stop using real default values for cvs_roots and
    default_root.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@558 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-10-02 20:00:27 +00:00
cmpilato b5d5e9d245 * viewcvs/lib/viewcvs.py
(handle_config): Use '' instead of None for the default value of
    "search".  A bug in urlencode() requires it.
  (view_diff_svn): New placeholder function.
  (Request.__init__, human_readable_diff): No longer chop the '.diff'
    off of the path.
  (main): Reorg the code here a bit.  I'm pretty sure I didn't
    actually change the logic outside of adding: redirect on file
    paths that have the extra '.diff' tacked on, and call the
    view_diff_svn stub at the right time.

* templates/log.ezt
* templates/log_table.ezt
* templates/include/diff_form.ezt
  Stop tacking that confounded ".diff" onto the diff queries.  The
  presence of r1 and r2 are enough to do the job.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@552 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-09-27 14:53:31 +00:00
cmpilato 5b6234678b Begin adding Subversion config and query support. First step was to
rename the 'cvsroot' URL query item to 'root' (while still supporting
'cvsroot' as a valid token that just gets mapped to 'root' under the
hood) and to add support for an svn_roots configuration value (not
added to the default config file as part of this commit, though).

* viewcvs/lib/config.py
  (_parse_roots): New helper.
  (Config._force_multi_value): Add 'svn_roots'.
  (Config._process_section): Use new helper function to parse
    'cvs_roots' and 'svn_roots' configuration items.
  (Config.set_defaults): Initialize default svn_roots config item.

* viewcvs/lib/viewcvs.py
  (_sticky_vars, _legal_params): Rename 'cvs_root' to 'root'.
  (_validate_root): Was _validate_cvsroot.
  (Request.__init__): Patch 'cvsroot' query items to be 'root' items.
    Examine both CVS and Subversion root configurations and choose the
    appropriate repository.
  (view_directory): Show both Subversion and CVS roots in the templates.

* viewcvs/lib/query.py
  (build_commit): Use 'root' in the URL query portion instead of
  'cvsroot'.

* viewcvs/templates/directory.ezt
* viewcvs/templates/dir_alternate.ezt
  Replaces references to 'cvsroot' with 'root'.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@546 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-09-06 20:36:58 +00:00
timcera ce16ab01b0 Added UTC/localtime feature based on patch supplied by Guy Davis in
'[ 548889 ] Local time display option'.
* Made a 'make_time_string' function that returns formatted date
  string in localtime or UTC, based on configuration choices.
* Added 'use_localtime' option in 'cgi/viewcvs.conf.dist' and
  'lib/config.py'.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@510 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-05-06 02:05:25 +00:00
timcera 837c82f2f1 Changes to the onClick handlers. Patch from Ville Skytt� (scop).
Basically include a 'return false;' and replace 'about:blank's.
See [ 541050 ] Bad onclick handler implementation at
http://sourceforge.net/tracker/index.php?func=detail&aid=541050&group_id=18760&atid=318760


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@507 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-04-27 20:24:12 +00:00
pefu 1d1b308d87 During testing with standalone.py I got a lot of
annoying 301 redirection "errors".  I tracked them
down to missing trailing slashes.  This change adds
these slashes to the directory URLs.  I'm not sure
whether this is right cure for the problem.  Please
review and comment.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@487 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-02-19 15:51:06 +00:00
pefu f583f7fc50 Sync with Tims changes to directory.ezt
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@486 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-02-19 15:26:10 +00:00
timcera 10a05b47f1 I think this fixes the cvsroot= not being propogated correctly in
the URLs.  It also fixes a problem with directory.ezt not having
closed </form> tags under certain conditions.
  *) Abstracted out a prepare_hidden_values function to create the
     appropriate hidden values for a particular form.  Should have
     everything in _sticky_vars in the request object as a hidden
     value EXCEPT the value(s) set by the form.
  *) Edited directory.ezt to use the new system.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@484 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-02-19 10:52:23 +00:00
pefu 67de5edd63 Correct hasty checkin (URL path to icons went wrong)
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@470 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-02-07 10:03:29 +00:00
pefu 1d120d8991 Inspired by Tim Ceras EMail this morning
( http://mailman.lyra.org/pipermail/viewcvs-dev/2002-February/000485.html )
I added sort direction toggles to the directory view.  It works.
But unfortunately the table header code in the template becomes very
bloated.  So I decided to put this only into dir_alternate.ezt for the
time being.  Please play around with it and review.  Putting
directory.ezt back into sync can be done later.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@469 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-02-07 09:08:50 +00:00
pefu 2c9ccd262e Trying to keep this in sync with directory.ezt. :-(
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@465 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-02-01 07:40:21 +00:00
timcera 44651e5b2e * Fixed bug where a directory of only directories still had the search
files option.
  * Rearranged table to make 'Show all files' button lined up with the 'Show'
    button.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@464 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-02-01 04:08:51 +00:00
timcera 794a72f201 Added a page number to the page pick list.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@463 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-02-01 04:05:46 +00:00
timcera 8004d3ed59 Made common elements of the log templates into include files. Makes the
templates much easier to read and allows easier movement of the
elements around on the page.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@461 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-02-01 03:29:25 +00:00
timcera d72922d81b This changes the behavoir of the View and Download links on log and log_table.
* For text files:
  'Download' opens download to file dialog box
  'View as Text' displays revision in new window
  'View as markup' displays enscript colored view with header information
  'View annotated' displays blame

* For gif, jpeg, and png:
  'View' displays graphic with header information similar to text markup

* For other binaries:
  'View/Download' will either view or download depending on browser's
   mime type / application settings.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@460 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-02-01 03:02:17 +00:00
timcera a25b2de3f9 This corrects some problems with rcsdiff header processing.
* Symbolic constants for tests.
* Moved text to diff.ezt template.
* Used elif to clean up logic.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@452 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-01-24 02:17:53 +00:00
timcera d24e850723 Added complete processing of rcsdiff header.
* Binary files are treated appropriately, detecting if there are differences
  or not.  Should fix part of feature request '[ #497044 ] Hide Diffs for
  Binaries'.
* Detects whether diff is accessible to rcsdiff and whether diff is GNU diff.
  Might move a diff test to viewcvs-install.  Advantage to it being here is
  that it responds to the CGI environment.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@450 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-01-23 05:05:18 +00:00
timcera a30ae3877a Created template components and put in templates/include directory.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@449 8cb11bc2-c004-0410-86c3-e597b4017df7
2002-01-23 04:18:26 +00:00
timcera 16bcb9e218 Added paging capability.
* Added use_pagesize to viewcvs.conf.dist and config.py
  * Modified directory and log templates to have a <select>
    pulldown menu based on files for directory views and revs
    for file logs.  Also setup to make the current page the
    'selected' item in the pulldown.
  * Added paging function to viewcvs.py.  Called from
    view_directory and view_log.
  * Added two variables to the _sticky_vars, dir_pagestart and
    log_pagestart.  Couldn't use a single pagestart var because
    it stuck around between the directory and log pages.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@434 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-31 04:39:34 +00:00
gstein ba99093be8 fix the test for selecting the "Side by Side" popup
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@421 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-23 10:34:14 +00:00
gstein 9171ad07a8 Add a missing UTC onto the revision's date.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@420 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-23 09:58:33 +00:00
gstein cd03714ecd Stop defining page titles in the code, and do it in the templates
instead.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@419 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-23 09:57:06 +00:00
gstein b41bd99aa3 Fix a bug where accidentally overwrote [nav_path] with the file
navigation. Change the file navigation to [nav_file] (in the code and
the template)


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@416 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-23 04:47:18 +00:00
gstein 5ca27eee4c Revise some of the attic handling to clarify what is happening, some
of the naming, and shift some text from the program to the templates.

* viewcvs.conf.dist: clarify description of the hide_attic default

* viewcvs.py: add [show_attic_href], [hide_attic_href], and
    [rows.state] variables for managing the attic links. remove the
    [rows.hide_attic_href] and [rows.attic] variables.

* directory.ezt, dir_alternate.ezt: use the new vars to insert the
    text/links for the attic handling.

* upgrading.html: document the template variable changes. a few other
    tweaks.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@414 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-23 04:13:35 +00:00
gstein 1470ccd12f Various UI fixes and tweaks
* viewcvs.py:
  - make "search" param a sticky variable; it should propagate through
    the screens, across column sort changes, etc
  - htmlify() the search expression
  - add a new variable to specify whether a search form is needed on
    the directory page (to select a tag and/or a regex)
  - add [files_shown] since [num_files] isn't "right"; need longer
    term fix for variable w.r.t message when zero files are selected
  - always create form parameters because we may have a search form
    (and now use them in the search form)
  - use new ezt.boolean() where appropriate

* directory.ezt, dir_alternate.ezt:
  - display the current location and selection criteria in one block
  - move selection form to bottom of screen; this emphasizes the
    directory contents rather than how to select/refine the contents
  - tweak the "no_match" message since the search expression could be
    causing the zero-matches
  - use a table to format the various forms of selection criteria
  - use the params for *both* tag selection and regex selection
  - optionally display the "show all files" button, based on whether
    there is current selection criteria or not


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@412 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-22 04:54:38 +00:00
gstein ae049f281b Implement the alternate view: revnum in front, linking to log page;
fname in second column, linking to HEAD.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@408 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-21 12:22:12 +00:00
gstein 70db664ec6 Clean up the mess in directory.ezt
* rather than using [headers] to determine the columns, just display
  them explicitly. use the new [have_logs] to determine whether the
  additional columns are needed.

* fix a bunch of problems in directory.ezt relating to unreadable
  files or errors while reading CVS information (lining up columns and
  whatnot)

* remove the "show_author" config option, favoring removal from the
  templates instead.

* remove the unused "hide_non_readable" option. remove the
  "use_java_script" and "open_extern_window" options; these were
  removed recently, but accidentally left in the .conf file.

* remove the "flip_links_in_dirview" option, favoring a new template
  instead. added a copy of directory.ezt as dir_alternate.ezt. changes
  to actually make the columns flipped are coming in a future commit.

* remove the [rev_in_front], [rows.span], and [rows.cols] options;
  these are now obsolete given the above changes

* add documentation to upgrading.html


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@403 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-21 04:50:33 +00:00
timcera 8432cb1c1d An [end] directive was missing, ViewCVS was throwing the new unclosed block
error.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@397 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-18 06:11:13 +00:00
gstein d71c208540 Big update! Convert the rest of the pages to use templates.
* annotation, human readable diff, CvsGraph, and a marked-up file all
  use a template to generate the basic parts of the page. In many
  cases (annotate, graph, markup), the content is still rendered
  by other code.

* for the diff support, we take advantage of the new list iteration
  support in EZT to "iterate on" a DiffSource object, which parses a
  diff stream into structured object for the template to display.

* for the CvsGraph page, we make use of EZT's new stream support to
  stream in an imagemap from the CvsGraph executable. the graph page
  includes a navigation header now.

* updated the upgrading.html page with some items missing from the 0.7
  instructions, plus new instructions.

* because of the complete conversion, the configuration file no longer
  specifies colors or images -- these are all in the templates now.
  Removed the relevant material from config.py and viewcvs.conf.dist.

* converted html_footer() to use the new footer.ezt template because
  we still have to call that manually in the markup and annotate
  cases.

* add the templates to viewcvs.conf.dist and config.py

* added a handy generate_page() utility for generating pages from a
  template and its input data.

* removed download_link, html_icon, html_option, print_diff_select,
  and navigate_header utility functions. These all printed HTML to the
  output, but are obsolete due to the new templates.

* the new nav_header_data() utility function fills in data used by the
  "header.ezt" template, which replaces the navigate_header() func.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@395 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-18 00:22:14 +00:00
gstein 830c6ba76c Move the footer to its own template, and include it from the others.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@394 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-18 00:09:00 +00:00
gstein e9a4e3bbe2 Minor fix to the diff-selection popup. It tested for "c" when it
should have been "s". (the resulting bug is that a side-by-side diff
would never appear pre-selected in the popup)


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@393 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-18 00:06:53 +00:00
pefu acbf138a6e Add Help buttons.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@386 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-12 20:42:31 +00:00
timcera d59be9459d * Added regular expression search of all files in a directory.
+ created search_files function
  + split view_checkout into view_checkout and process_checkout.
    Wanted the process_checkout code to checkout the files from the
    repository.
  + split get_file_data into get_file_data and get_file_tests.
    Wanted get_file_tests to tell what kind of object was in the repository.
  + Modified directory.ezt to include searches.
    - Moved select by tag function up to the top of the page
    - Included code to return how many files survived the filters
    - The 'Reset' button now says 'Show all files'.
  + Modified viewcvs.conf.dist to include use_re_search option.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@378 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-12-11 05:19:22 +00:00
pefu d11dffb713 Table header should look left aligned and green similar
to the table headers in directory.ezt and query.ezt


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@361 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-27 22:13:30 +00:00
pefu 16281c1db5 A lot of small changes in one commit:
lib/viewcvs.py, templates/directory.ezt:
* Fix SF Bug [ #486085 ] checkout_magic_path uses invalid chars
  Provide backward compatibility for old style URLs.

standalone.py:
* Changed from calling viewcvs.main() to calling viewcvs.runcgi(),
  so that the timing results sampled by debug are displayed in the browser.

* Added two more toggles to the GUI.  Now it is simpler to perform a
  systematic test of several permutations of these config flags.

* Shortened the label text for the query entry field in the standalone GUI.

* Added some comments to this Tkinter GUI setup code, which has grown beyond
  than what I was my first intention.

lib/viewcvs.py, lib/config.py, cgi/viewcvs.conf.dist, standalone.py
and templates/directory.ezt:
* Added a new config flag variable called flip_links_in_dirview, which defaults
  to the classic setting (like cvsweb).  If it is set to 1 instead then the
  file and revision columns are exchanged and at the same time these two columns
  exchange the meaning of their links.  This design should solve the user
  interface design problem brought up first in
    http://www.lyra.org/pipermail/viewcvs-dev/2001-November/000285.html
  which was than than further discussed here:
    http://www.lyra.org/pipermail/viewcvs-dev/2001-November/000288.html
    http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/viewcvs/viewcvs/templates/Attic/direasy.ezt?hideattic=0
    http://www.lyra.org/pipermail/viewcvs/2001q4/000533.html
  Since than I received two personal emails from people sharing my POV.

  Unfortunately the huge [for rows]-block in directory.ezt has grown
  again.  But it is difficult to avoid this with the current design of
  lib/viewcvs.py and the templating engine lib/ezt.py.  I'm open to
  suggestions.

  In lib/viewcvs.py function view_directory I factored out the computation
  of row.span into a new local variable called span, since the number of
  empty trailing columns is decreased by one if the flip_links layout
  is configured.

templates/query.ezt:
* Rearranged the table columns in the commit database query result table,
  so that they match the existing table layouts of directory.ezt and
  log_table.ezt.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@360 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-27 21:56:06 +00:00
pefu 6a0c6f2029 Log messages should look like they were
formatted in the first place. (see viewcvs.print_log() last line for
example, how the log message is displayed elsewhere


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@355 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-19 14:36:18 +00:00
pefu 889f71f657 Even on the 1600x1200 pixel display of my new DELL Inspiron the table
generated by query.cgi was unacceptable wide.

After I widened the browser window so that it occuoies the whole
screen width, it still required a horizontal scrollbar.
I find this unusable.  So I decided to remove the
Description column and put the Log message blocks on a separate
table row.

But since this may be a matter of taste, I left the original
stuff in, but commented out.  People with really large
screens (2000 pixels and up) might want to revert this change.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@353 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-19 12:09:55 +00:00
gstein cef439958f Remove direasy.ezt.
directory.ezt incorporated its cvsgraph icon, so its only difference is
flipping the links around. But the existing definition for the links makes
more sense, so that leaves direasy.ezt without any new or interesting
features.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@347 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-19 03:11:21 +00:00
gstein 175d6f0ac4 Updates to the help stuff
* rename ~helppage~ magic path to ~docroot~ with the intent that we might
  serve other content out of there (including users' data if necessary)

* shift Help link down below the logo where it is more visible

* rename g_template_dir to its real semantic: g_install_dir

* rename view_helppage() to view_doc() and use new g_install_dir to find the
  doc root.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@346 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-19 02:59:13 +00:00
gstein 983a2c298e Minor tweaks:
- "view annotated" rather than "view annotation" (we don't want to imply
  there is some kind of annotation facility; we really need a better word
  for this; and no... 'blame' isn't it :-)

- use a rowspan on the revision column


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@339 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-18 11:45:54 +00:00
gstein 51988428f2 Fix up the diff links:
* put them back on a single line

* restore ordering -- "previous" is the most common, so it goes first

* add the action text into Diff links for larger hit targets
  (idea from Stephen Lamm <slamm@yahoo-inc.com>)


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@338 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-18 11:30:27 +00:00
gstein 9a8c28d886 Shift some presentation code out of query.py; do the work in the template.
Also, make sure the result table isn't shown if we haven't run a query.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@337 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-18 11:11:38 +00:00
gstein b048907b6d Complete the conversion of the cvsdb query facility over to templates. This
was a "minimal impact" switch. A bit more cleanup is coming separately.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@335 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-18 10:34:35 +00:00
gstein 674a2ee494 incorporate the graph icon from direasy (add size params). keep the links
the same. eliminate the border around the image.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@327 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-17 09:25:19 +00:00
timcera 9fdfe05d24 * Corrected the colspan option for the 'Log' row.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@324 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-15 20:42:25 +00:00
pefu 2bc61a621d direasy.ezt is a simple variation based on directory.ezt.
Recently Stephen Lamm wrote:
> Have file links go to the latest revision instead of the cvs log.
> When I click on the file name, I expect to get that file, and not
> some meta information about it. Another column next the name could
> have a link like "(Log)" to get that information. That would be
> more explicit. I find it strange to click on the revision number
> to get a file because I typically do not think of files in terms
> of revision numbers. (The revision number probably should not have
> a link on it at all.)

In this template the revision number carries a link to the Log
page  (so the meaning of both columns are simply swapped).
Additionally (if you enable cvsgraph) the text string "(graph)" is replaced
by a small 16x16 pixel icon.

I experimented with the suggestion to add the word '(Log)' to each
filename but in the end I think that both (graph) and (log)
waste a lot of valueable horizontal screen space.

If you want to try this template out, you can simply start
	./standalone.py --gui
in the viewcvs directory and select the radio button labeled
with 'direasy.ezt'.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@322 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-15 18:12:22 +00:00
pefu eae9e0131f Added the utc date (I missed that)
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@321 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-15 18:00:56 +00:00
timcera 7232487cf0 * Combined the 'Branches' and 'Tags' columns.
* Probably fixed the problem of many tags in the table.
* Minor format changes.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@317 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-15 02:10:26 +00:00
pefu 18667d725d Open a new browser window to display help pages.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@314 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-13 22:32:29 +00:00
timcera c80469ba5e * Moved log to seperate line.
* Changed link text.
* Added 'Diffs' column.
* Removed link from revision number.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@312 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-13 20:59:35 +00:00
pefu c8f661e626 * Fixed the links on the help pages to point to the viewcvs website @ SF.
* Finally removed the duplicated text from directory.ezt and replaced it
  with a 'Help' button at the upper right corner.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@311 8cb11bc2-c004-0410-86c3-e597b4017df7
2001-11-13 20:54:07 +00:00