* lib/viewvc.py
(view_roots): Generate a log_href -- the revision log for the root
directory of the repository -- where it makes sense to do so.
* templates/classic/roots.ezt,
* templates/default/roots.ezt
Markup the last-modified-revision as a link to the log view where we can.
* docs/template-authoring-guide.html
Note the additional data dictionary item.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2653 8cb11bc2-c004-0410-86c3-e597b4017df7
* templates/classic/include/diff_display.ezt
* lib/viewvc.py
Rename 'display_as' to 'diff_block_format', as discussed on ML.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2650 8cb11bc2-c004-0410-86c3-e597b4017df7
(top level) Introduce formatting rules for 4th and 5th levels of variables.
(diff.ezt) Update for the changes on the property-diff branch. Describe
missing parts (intraline diffs, patch_href). Fix some typos and copy-paste
errors.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/branches/property-diff@2642 8cb11bc2-c004-0410-86c3-e597b4017df7
Tweak the "from 0.8" section for a bit of consistency with other sections.
(As if anyone is still running 0.8.)
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2633 8cb11bc2-c004-0410-86c3-e597b4017df7
#433 ("queries return only partial results"). When a database query
is artificially limited by the 'row_limit' setting, inform the user
that the returned data is incomplete.
* lib/cvsdb.py
(CheckinDatabase.CreateSQLQueryString): Add 'detect_leftover'
parameter, used internally to check for a reached query limit.
(CheckinDatabase.RunQuery): Update call to CreateSQLQueryString(),
and check for leftover query response rows. If any are found, set
the appropriate flag on the query object.
(CheckinDatabaseQuery.__init__): Set initial values for new
'executed' and 'limit_reached' members.
(CheckinDatabaseQuery.SetExecuted,
CheckinDatabaseQuery.SetLimitReached,
CheckinDatabaseQuery.GetLimitReached,
CheckinDatabaseQuery.GetCommitList): New functions.
* lib/viewvc.py
(view_query): Use query.GetCommitList() now instead of poking into
the query object directly. Also, check query.GetLimitReached(),
reporting the findings through the data dictionary (via a new
'row_limit_reached' item) to the templates.
* lib/query.py
(run_query): Use query.GetCommitList() now instead of poking into
the query object directly. Now return a 2-tuple of commits and a
limit-reached flag.
(main): Update expectations of run_query() call. Populate
'row_limit_reached' data dictionary item.
* templates/query_results.ezt,
* templates/query.ezt
Display a warning if the query results are incomplete.
* templates/docroot/styles.css
(.vc_warning): New style definition.
* docs/template-authoring-guide.html
Document the new 'row_limit_reached' template item.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2551 8cb11bc2-c004-0410-86c3-e597b4017df7
mechanisms, namely by removing the largely redundant "global" limit
and allowing the per-query row limit (which already exist, too) to do
its work.
While here, remove a poorly conceived (but thankfully unhighlighted)
mechanism for overriding the administrative limit on database rows
which was accessible via URL CGI params.
* lib/viewvc.py
(_legal_params): Remove 'limit' as a legal parameter.
(view_query): No longer allow an undocumented URL parameter to
override the admin-declared SQL row limit. That should have never
been allowed!
* lib/cvsdb.py
(CheckinDatabase.__init__): Remove 'row_limit' parameter and
associated self._row_limit member.
(CheckinDatabase.CreateSQLQueryString): No longer fuss with
self._row_limit. Let the individual query carry the row limit.
(ConnectDatabase): Update call to CheckinDatabase().
* lib/query.py
(form_to_cvsdb_query): Now accept 'cfg' parameter, and set the
query's row limit from the configured defaults.
(run_query): Update call to form_to_cvsdb_query().
* docs/url-reference.html
Remove reference to the 'limit' parameter.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2547 8cb11bc2-c004-0410-86c3-e597b4017df7
roots view").
* lib/viewvc.py
(view_roots): Include revision metadata in the data dictionary.
(list_roots): If configured to do so, calculate some last-modified
metadata for Subversion roots.
* lib/config.py
(Config.set_defaults): Set default value for new show_roots_lastmod
option.
* conf/viewvc.conf.dist
(show_roots_lastmod): New option.
* templates/roots.ezt
Show some roots metadata if configured to do so.
* docs/template-authoring-guide.html
Document new 'roots' view data dictionary items.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2517 8cb11bc2-c004-0410-86c3-e597b4017df7
* lib/viewvc.py
(view_diff): Use repos.itemlog() to fetch revision metadata about
the left- and right-hand diff objects and expose 'author', 'log',
'ago', and 'size' to the templates.
* docs/template-authoring-guide.html
Document the newly added template data dictionary items.
* templates/diff.ezt
Display the revision authors in the diff view.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2275 8cb11bc2-c004-0410-86c3-e597b4017df7
* conf/viewvc.conf.dist
(allowed_cvsgraph_useropts): New option.
* lib/config.py
(Config.set_defaults): Set default value for new
'allowed_cvsgraph_useropts' option.
* lib/viewvc.py
(_legal_params): Add new legal parameters: 'gflip', 'gbbox',
'gshow', 'gleft', and 'gmaxtag'.
(cvsgraph_make_reqopt, cvsgraph_normalize_gshow, cvsgraph_extraopts):
New helper functions.
(view_cvsgraph_image): Now pass the -O option set to the cvsgraph
binary.
(view_cvsgraph): Now pass the -O option set to the cvsgraph binary.
Also, add new template data stuff for generating a user-configurable
graph display options form.
* templates/graph.ezt,
* templates/docroot/styles.css
Add template stuff for generating a user-configurable graph display
options form.
* docs/url-reference.html,
* docs/template-authoring-guide.html
Update documentation.
* CHANGES
Note this change.
Patch by: Bertho Stultiens <bertho{_AT_}j.auh.dk> (originally),
Jene Jasper <tigris{_AT_}shadowland.demon.nl> (port to 1.1.x),
me (tweaks for official ViewVC inclusion)
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2204 8cb11bc2-c004-0410-86c3-e597b4017df7
into two: 'log_pagesize' and 'dir_pagesize', individually controlling
the size of pages used (if at all) for the revision log and directory
views, respectively.
* conf/viewvc.conf.dist
(use_pagesize): Removed, in favor of...
(dir_pagesize, log_pagesize): ...these.
* lib/viewvc.py,
* lib/config.py,
* bin/standalone.py
Replace the use and tooling around 'use_pagesize' with
'dir_pagesize' and 'log_pagesize' as appropriate.
* templates/include/paging.ezt,
* templates/include/dir_header.ezt
Stop using the option value to determine whether or not to show
pagination UI. Use the presence of some pages instead.
* docs/upgrading-howto.html
Note the changes in options.
Patch by: Lei Zhang <thestig{_AT_}google.com>
(Tweaked by me.)
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2142 8cb11bc2-c004-0410-86c3-e597b4017df7
in all of its templated views. Do this with a custom, dictionary-like
class that prevents the creation of new keys after an initial
instantiation of keys and (possibly dummy) values.
* lib/ezt.py
(TemplateData): New.
* lib/viewvc.py
(common_template_data): Now return an ezt.TemplateData() object.
(make_comma_sep_list_string): New.
(markup_or_annotate): Use new ezt.TemplateData() interface now. Use
make_comma_sep_list_string() where applicable.
(view_roots, view_log, view_cvsgraph, view_diff, view_revision,
view_queryform, view_query): Use new ezt.TemplateData() interface now.
(view_directory): Use new ezt.TemplateData() interface now. Drop
'search_re_form' dictionary item.
* lib/query.py
(main): Use new ezt.TemplateData() interface now. While here, drop
'script_name' calculation (it isn't used).
* templates/include/dir_header.ezt
Display the search form if 'search_re_action' is set, not 'search_re_form'.
* docs/template-authoring-guide.html
Remove 'search_re_form'. Update 'search_re_action' description.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2123 8cb11bc2-c004-0410-86c3-e597b4017df7
Trade the 'mime_types_file' option for 'mime_types_files' -- an
ordered list of MIME mapping files to consult. And provide our own
(empty) mapping file that folks can use to override the mappings
provided by other such files.
* mimetypes.conf.dist
New file.
* viewvc.conf.dist
(mime_types_files): Was mime_types_file, and now accepts multiple values.
* lib/config.py
(Config._force_multi_value): Add "mime_types_files" to the list of
multi-value configuration options.
(Config.set_defaults): Track rename of mime_types_file parameter,
now setting the default to a list containing only "mimetypes.conf".
* lib/viewvc.py
(load_config): Track new name and format of mime_types_files option.
* viewvc-install
(FILE_INFO_LIST): Also install mimetypes.conf.dist as itself and as
mimetypes.conf.
* INSTALL
(INSTALLING VIEWVC): Update reference to renamed configuration option.
* docs/upgrading-howto.html
Update this document.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2101 8cb11bc2-c004-0410-86c3-e597b4017df7
from an email response I gave on the dev@ list. Will massage this
into something a little more ready for publicity later.
* docs/release-notes,
* docs/release-notes/1.1.0.html
New.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2085 8cb11bc2-c004-0410-86c3-e597b4017df7
* lib/viewvc.py
(view_revision): Add new 'num_changes' data dictionary item.
* templates/revision.ezt
Expose new 'num_changes' item as a header on this page, and tweak
the way the more/first changes links appear.
* docs/template-authoring-guide.html
Document num_changes dictionary item.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2067 8cb11bc2-c004-0410-86c3-e597b4017df7
files).
* lib/viewvc.py
(markup_or_annotate): Make the default value for the 'annotation'
data dictionary member 'none' (instead of None) to simplify
template logic.
* docs/template-authoring-guide.html
Update docs for 'annotated'.
* templates/file.ezt
Use simplified logic to avoid missing links. (No, not *that* kind ...)
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2064 8cb11bc2-c004-0410-86c3-e597b4017df7
and have that mean "use an authorizer". So let's just prevent that
confusion right now, okay?
* lib/config.py
(Config.set_defaults): Set 'authorizer' by default to None.
* viewvc.conf.dist
(authorizer): Update comments for correctness, and don't imply that
"forbidden" is the default authorizer.
* docs/upgrading-howto.html
Stop saying that "forbidden" is the default authorizer.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@2053 8cb11bc2-c004-0410-86c3-e597b4017df7
* viewvc.conf.dist
(hide_errorful_entries): New.
* lib/config.py
(Config.set_defaults): Init cfg.options.hide_errorful_entries to 0.
* lib/viewvc.py
(view_directory): If cfg.options.hide_errorful_entries is enabled,
skip any directory entries that carry errors.
* docs/upgrading-howto.html
Note the new option.
* CHANGES
Note this (and the previous) change.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1998 8cb11bc2-c004-0410-86c3-e597b4017df7
modules were renamed), and merge r1933 (in which the 'imp' module is
used to more directly deal with the import cycle problem).
* docs/upgrading-howto.html
Remove upgrading notes about renamed modules since, now, they aren't
renamed any more.
* viewvc-install
Note re-renamed paths.
* bin/mod_python/viewvc_mp.py,
* bin/mod_python/query_mp.py
Rename these back ...
* bin/mod_python/viewvc.py,
* bin/mod_python/query.py
... to these, and use the 'imp' module to load libraries from
specific locations.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1994 8cb11bc2-c004-0410-86c3-e597b4017df7
configured template directory now.
* lib/viewvc.py
(get_view_template): Rework this to interpret per-template overrides
as relative to the template-dir, which itself is relative to the
configuration location.
* viewvc.conf.dist
(templates): Strip 'templates/' from the sample template locations,
and note that these paths are relative to the configured template
directory.
* docs/upgrading-howto.html
Note this change of interpretation.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1953 8cb11bc2-c004-0410-86c3-e597b4017df7
the details of those changes, run:
svn log --stop-on-copy --verbose \
http://viewvc.tigris.org/svn/viewvc/branches/merged-file-views@1917
Basically, this change unifies the annotate and markup views at the
cost of dropping support for all but one of our syntax highlighting
engines -- Pygments. (So, goodbye to 'enscript', 'highlight',
'source-highlight', 'py2html', and 'php'.) By settling on a single
markup engine (and a Python-module-based one with a BSD license, at
that), we:
* added syntax highlighting to the annotate view
* added line numbers to the markup view (prior to this, you
sometimes had 'em and sometimes didn't, depending on which
highlighting engine you used).
* essentially unified the markup and annotate views -- they even
share the same template now.
* can ship ViewVC with Pygments and syntax highighting enabled so
folks don't have to do additional config work to get that feature.
This change may be controversial. Depending on the overlap of
supported syntaxes across the various engines we supported prior to
this change, we may be losing support for some languages. And we're
also losing URL markup-ing (which was, again, partially supported
depending on the markup engine you were using). Somebody is going to
get upset that their pet benefit is now missing. I understand that.
I'm optimistic, though, that we can identify the lossages that really,
really matter, and address them in low-maintenance-hassle ways using
this slimmer, trimmer codebase as the baseline.
Also in this commit (in addition to the merged changes):
* templates/docroot/styles.css
Minor stylation tweaks.
* viewvc.conf.dist
(enable_syntax_coloration): Tweak the comment to indicate that
Pygments is required for syntax coloration to work.
* CHANGES
Note these changes.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1918 8cb11bc2-c004-0410-86c3-e597b4017df7
ViewVC's core libraries, turn the form hidden-values objects from HTML
strings to iterable objects that templates can use to *make* HTML strings.
* lib/viewvc.py
(Request.get_form): Now prepare hidden values as an iterable list of
objects with .name and .value attributes.
(common_template_data): Don't add 'change_root_action' and
'change_root_hidden_values' data dictionary items.
(prepare_hidden_values): Remove as unused.
* templates/include/diff_form.ezt,
* templates/include/dir_footer.ezt,
* templates/include/dir_header.ezt,
* templates/include/paging.ezt,
* templates/include/pathrev_form.ezt,
* templates/include/sort.ezt,
* templates/diff.ezt,
* templates/log_table.ezt,
* templates/query_form.ezt,
* templates/revision.ezt
Iterate over hidden-values items to generate <input type="hidden"
.../> output.
* docs/upgrading-howto.html,
* docs/template-authoring-guide.html
Note these changes.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1894 8cb11bc2-c004-0410-86c3-e597b4017df7
* lib/viewvc.py
(common_template_data): Add request.username to the common template
data as 'username'.
* docs/template-authoring-guide.html
Document the addition.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1893 8cb11bc2-c004-0410-86c3-e597b4017df7
allow_compress option do something useful.
. o O ( What other dead code exists in this software? )
* lib/viewvc.py
Import the 'gzip' module unconditionally.
(Request.__init__): Determine if gzip output encoding is allowed.
(get_writeready_server_file): New.
(download_tarball): Lose the code that falls back to using a gzip
binary. Use get_writeready_server_file()
(generate_page, view_checkout, view_cvsgraph_image, view_doc,
view_patch): Use get_writeready_server_file(), allowing it to do
server header output finalization.
* lib/config.py
(Config.set_defaults): No longer initialize self.utilities.gzip.
Now initialize cfg.option.allow_compress to 0.
* viewvc.conf.dist
(utilities.gzip): Lose.
(options.allow_compress): Lose note that indicates that 'gzip' must
be installed and accessible in the program path.
* docs/upgrading-howto.html
Don't note the addition of cfg.utilities.gzip ... because I just
un-added it.
* CHANGES
Note support for gzip-encoded output.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1873 8cb11bc2-c004-0410-86c3-e597b4017df7
dictionary stuffs. It can be expensive to generate (especially when
authorization is in place) and brings little value considering we have
a roots listing view. The sole known casualty in this change is the
little drop-down roots listing box, which is often one of the first
customizations (removing this) that folks make to their ViewVC
instances anyway.
* lib/viewvc.py
(find_root_in_parents, locate_root): New functions.
(common_template_data): Move the root listing data dictionary stuff ...
(view_roots): ... to here. Now uses expand_root_parents().
(load_config): This, however, no longer uses expand_root_parents.
(Request.run_viewvc): Use locate_root() to find a requested root
name rather than expecting cvs_roots and svn_roots to be fully
populated.
* templates/include/header.ezt
Lose the root listing drop-down box, and de-table-ize the breadcrumbs.
* templates/docroot/styles.css
(.vc_navheader): Add some padding.
* docs/template-authoring-guide.html
Move the 'roots' stuff from the COMMON template data collection to
the section specific to the root listing view.
git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@1865 8cb11bc2-c004-0410-86c3-e597b4017df7