Lars Hjemli [Mon, 5 Nov 2007 23:38:18 +0000 (00:38 +0100)]
Merge branch 'iconv-rebased' of http://x2a.org/pub/git/cgit
* 'iconv-rebased' of http://x2a.org/pub/git/cgit:
Use utf8::reencode_string from git
Convert subject and message with iconv_msg.
Add iconv_msg function.
Set msg_encoding according to the header.
Add commit->msg_encoding, allocate msg dynamicly.
Lars Hjemli [Sun, 28 Oct 2007 14:36:18 +0000 (15:36 +0100)]
Make print_branch() handle refs not pointing at commits
The master branch of stable/linux-2.6.20 currently references a tag
object, which makes print_branch() die with a segfault. This teaches
print_branch() to handle such cases more gracefully.
Lars Hjemli [Sat, 27 Oct 2007 08:55:10 +0000 (10:55 +0200)]
Merge branch 'filter-refs'
* filter-refs:
Add links to the new refs page from summary page
Add support for refs view
Make cgit_print_branches()/cgit_print_tags() external
Add descriptions of summary-branches and summary-tags to cgitrc
Add support for config param summary-branches
Move logic for age comparision from cmp_tag_age into cmp_age()
Add support for config param summary-tags
Sort tags by age
Use reflist to print tag info
Use reflist to print branch info
Add functions and types for ref lists
Lars Hjemli [Sat, 27 Oct 2007 08:13:42 +0000 (10:13 +0200)]
Add support for config param summary-branches
This parameter can be used to specify max number of branches to show
on the summary page (if not all branches will be displayed, the "most
idle" branches are the ones to be pruned). The default value for this
parameter is 0, which disables the pruning.
Lars Hjemli [Wed, 24 Oct 2007 19:14:44 +0000 (21:14 +0200)]
Skip unknown header fields when parsing tags and commits
Both the commit- and tagparser failed to handle unexpected header fields.
This adds futureproofing by simply skipping any header we don't know/care
about.
Lars Hjemli [Wed, 19 Sep 2007 22:56:53 +0000 (00:56 +0200)]
Use trim_end() to remove trailing slashes
All urls and paths read from cgitrc needs to be 'normalized', i.e. get any
trailing slashes removed, and the trim_end() function works out nice for
this purpose.
Removing the trailing slashes also happens to fix the case where the virtual
root should be a single slash; that case used to require specifying the full
hostname (including the http:// prefix), but now it can simply be specified
as /.
Lars Hjemli [Wed, 19 Sep 2007 22:00:06 +0000 (00:00 +0200)]
ui-tree: show last line of blob
The last line in a blob was never printed by ui-tree::print_object(), which
was particularly annoying when the blob missed a final newline. This fixes
the issue.
Noticed-by: <mkraai@beckman.com> Signed-off-by: Lars Hjemli <hjemli@gmail.com>
Lars Hjemli [Tue, 4 Sep 2007 09:04:47 +0000 (11:04 +0200)]
Set xdemitconf_t.findfunc=NULL
This function-pointer was introduced in git v1.5.3-rc0-42-gf258475. It
needs to have a value, and setting it to NULL triggers the old behaviour
for selecting hunk headers.
Lars Hjemli [Mon, 23 Jul 2007 20:51:45 +0000 (22:51 +0200)]
ui-snapshot: whitespace/formatting cleanup
Introduce a #define for number of snapshot archive entries, move all decls
to function entrypoint, remove some trailing whitespace and reformat a few
lines.
Lars Hjemli [Sun, 22 Jul 2007 21:57:48 +0000 (23:57 +0200)]
Merge branch 'master' of git://git.klever.net/patchwork/cgit
* 'master' of git://git.klever.net/patchwork/cgit:
link raw blob from tree file view
fix: changed view link to blob in summary.
allow selective enabling of snapshots
shorten snapshot names to repo basename
introduce cgit_repobasename
added snapshot filename to the link
add plain uncompressed tar snapshort format
introduced .tar.bz2 snapshots
compress .tar.gz using gzip as a filter
added a chk_non_negative check
css: adjust vertical-align of commit info th cells
add support for snapshot tarballs
Michael Krelin [Sat, 21 Jul 2007 00:05:34 +0000 (02:05 +0200)]
introduced .tar.bz2 snapshots
- reworked write_tar_gzip_archive to handle arbitrary filter as a
write_compressed_tar_archive
- reformatted whitespaces in the said function to adhere to common cgit
standards
- added wrappers around write_compressed_tar_archive for .tar.gz and .tar.bz2
- added a hint for vim to use 8 characters shift width by default
Michael Krelin [Wed, 18 Jul 2007 12:40:03 +0000 (14:40 +0200)]
add support for snapshot tarballs
- reworked cgit_print_snapshot to use a list of supported archivers and pick
one for the suffix supplied
- moved printing of snaphot links into ui-snapshot and make it iterate through
the said list
Lars Hjemli [Fri, 29 Jun 2007 18:32:08 +0000 (20:32 +0200)]
Merge branch 'lh/menu'
* lh/menu:
Add ofs argument to cgit_log_link and use it in ui-log.c
Add trim_end() and use it to remove trailing slashes from repo paths
Do not include current path in the "tree" menu link
Add setting to enable/disable extra links on index page
Change S/L/T to summary/log/tree
Change "files" to "tree"
Include querystring as part of cached filename for repo summary page
Add more menuitems on repo pages
Lars Hjemli [Tue, 26 Jun 2007 16:04:31 +0000 (18:04 +0200)]
Add trim_end() and use it to remove trailing slashes from repo paths
The new function removes all trailing instances of an arbitrary character
from a copy of the supplied char array. This is then used to remove any
trailing slashes from cgit_query_path.
Lars Hjemli [Tue, 26 Jun 2007 15:32:03 +0000 (17:32 +0200)]
Do not include current path in the "tree" menu link
When generating the menu links on repo pages the tree link included the
current path. This made the link pretty useless whenever the current path
was set so this commit just passes NULL instead.
Lars Hjemli [Mon, 18 Jun 2007 22:56:40 +0000 (00:56 +0200)]
Add setting to enable/disable extra links on index page
The summary/log/tree links displayed for each repository on the index
page lost some of their purpose when the header menu was added, so this
commit introduces the parameter 'enable-index-links' which must be set
to 1 to enable these links.
Suggested-by: Kristian Høgsberg <krh@bitplanet.net> Signed-off-by: Lars Hjemli <hjemli@gmail.com>