Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/gitweb
AgeCommit message (Collapse)Author
2006-10-23gitweb: Do not esc_html $basedir argument to git_print_tree_entryJakub Narebski
In git_tree, rename $base variable (which is passed as $basedir argument to git_print_tree_entry) to $basedir. Do not esc_html $basedir, as it is part of file_name ('f') argument in link and not printed. Add '/' at the end only if $basedir is not empty (it is empty for top directory) and doesn't end in '/' already. Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-22gitweb: Whitespace cleanup - tabs are for indent, spaces are for align (2)Jakub Narebski
Code should be aligned the same way, regardless of tab size. Use tabs for indent, but spaces for align. Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-09gitweb: Cleanup Git logo and Git logo target generationJakub Narebski
Rename $githelp_url and $githelp_label to $logo_url and $logo_label to be more obvious what they refer to; while at it add commented out previous contents (git documentation at kernel.org). Add comment about logo size. Use $cgi->a(...) to generate Git logo link; it automatically escapes attribute values when it is needed. Escape href attribute using esc_url instead of (incorrect!) esc_html. Move styling of git logo <img> element from "style" attribute to CSS via setting class to "logo". Perhaps we should set it by id rather than by class. Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-07gitweb: [commit view] Do not suppress commitdiff link in root commitPetr Baudis
There's no reason for that, the commitdiff view is meaningful for the root commit as well and we link to it everywhere else. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-07gitweb: Handle commits with empty commit messages more reasonablyPetr Baudis
Currently those look very weird, you can't get easily at the commit view etc. This patch makes their title '(no commit message)'. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-07gitweb: Separate (new) and (deleted) in commitdiff by a spacePetr Baudis
Currently it's pasted to the sha1 of the blob and looks ugly. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-07Show snapshot link in shortlog only if have_snapshoPetr Baudis
Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-06gitweb: refactor decode() for utf8 conversionYasushi SHOJI
we already had a few place using decode() to convert perl internal encode to utf8. added a new thin wrapper to do just that. Signed-off-by: Yasushi SHOJI <yashi@atmark-techno.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-06gitweb: Make the Git logo link target to point to the homepageJunio C Hamano
It provides more useful information for causual Git users than the Git docs (especially about where to get Git and such). People can override with GITWEB_CONFIG if they want to. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net> Acked-by: Petr Baudis <pasky@suse.cz>
2006-10-06gitweb: blame: Minimize vertical table row paddingLuben Tuikov
Minimize vertical table row padding for blame only. I discovered this while having the browser's blame output right next to my editor's window, only to notice how much vertically stretched the blame output was. Blame most likely shows source code and is in this way more "spartan" than the rest of the tables gitweb shows. This patch makes the blame table more vertically compact, thus being closer to what you'd see in your editor's window, as well as reusing more window estate to show more information (which in turn minimizes scrolling). Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-06gitweb: Do not print "log" and "shortlog" redundantly in commit viewLuben Tuikov
Do not print "log" and "shortlog" redundantly in commit view. This is passed into the $extra argument of git_print_page_nav from git_commit, but git_print_page_nav prints "log" and "shortlog" already with the same head. Noticed by Junio. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-05tar-tree deprecation: we eat our own dog food.Junio C Hamano
It is silly to keep using git-tar-tree in dist target when the command gives a big deprecation warning when called. Instead, use "git-archive --format=tar" which we recommend to our users. Update gitweb's snapshot feature to use git-archive for the same reason. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-04Update the gitweb/README file to include setting the GITWEB_CONFIG environmentAlan Chandler
Signed-off-by: Alan Chandler <alan@chandlerfamily.org.uk> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-03gitweb: document webserver configuration for common gitweb/repo URLs.Martin Waitz
Add a small apache configuration which shows how to use apache to put gitweb and GIT repositories at the same URL. Signed-off-by: Martin Waitz <tali@admingilde.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-03gitweb: Escape ESCAPE (\e) characterLuben Tuikov
Take a look at commit 20a3847d8a5032ce41f90dcc68abfb36e6fee9b1 using gitweb before this patch. This patch fixes this. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-10-01Merge branch 'lt/web'Junio C Hamano
* lt/web: gitweb: tree view: hash_base and hash are now context sensitive gitweb: History: blob and tree are first, then commitdiff, etc gitweb: Remove redundant "commit" from history gitweb: Don't use quotemeta on internally generated strings gitweb: Add snapshot to shortlog gitweb: Factor out gitweb_have_snapshot() gitweb: Remove redundant "commit" link from shortlog gitweb: "alternate" starts with shade (i.e. 1) gitweb: Add history and blame to git_difftree_body() gitweb: Remove excessively redundant entries from git_difftree_body Revert "gitweb: extend blame to show links to diff and previous" gitweb: Quote filename in HTTP Content-Disposition: header gitweb: Add git_url subroutine, and use it to quote full URLs gitweb: Split validate_input into validate_pathname and validate_refname gitweb: Use "return" instead of "return undef" for some subs gitweb: Strip trailing slashes from $path in git_get_hash_by_path gitweb: extend blame to show links to diff and previous gitweb: Remove redundant "tree" link gitweb: tree view: eliminate redundant "blob"
2006-09-30gitweb: tree view: hash_base and hash are now context sensitiveLuben Tuikov
In tree view, by default, hash_base is HEAD and hash is the entry equivalent. Else the user had selected a hash_base or hash, say by clicking on a revision or commit, in which case those values are used. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-29gitweb: History: blob and tree are first, then commitdiff, etcLuben Tuikov
Reorder link display in history to be consistent with other list displays: log, shortlog, etc. We now display: blob | commitdiff blob | commitdiff | diff_to_current and tree | commitdiff Instead of the old history format where "blob" and "tree" are between "commitdiff" and "diff_to_current" if present/ applicable. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-29gitweb: Remove redundant "commit" from historyLuben Tuikov
Remove redundant "commit" from history -- it can be had by clicking on the title of the commit. This commit makes visualization consistent with shortlog, log, etc. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-29gitweb: Don't use quotemeta on internally generated stringsLuben Tuikov
Do not use quotemeta on internally generated strings such as filenames of snapshot, blobs, etc. quotemeta quotes any characters not matching /A-Za-z_0-9/. Which means that we get strings like this: before: linux\-2\.6\.git\-5c2d97cb31fb77981797fec46230ca005b865799\.tar\.gz after: linux-2.6.git-5c2d97cb31fb77981797fec46230ca005b865799.tar.gz This patch fixes this. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-29gitweb: Add snapshot to shortlogLuben Tuikov
Add snapshot to each commit-row of shortlog. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-29gitweb: Factor out gitweb_have_snapshot()Luben Tuikov
Create gitweb_have_snapshot() which returns true of snapshot is available and enabled, else false. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-29gitweb: Remove redundant "commit" link from shortlogLuben Tuikov
Remove the redundant "commit" link from shortlog. It can be had by simply clicking on the entry title of the row. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-29gitweb: "alternate" starts with shade (i.e. 1)Luben Tuikov
When displaying a list of rows (difftree, shortlog, etc), the first entry is now printed shaded, i.e. alternate is initialized to 1, as opposed to non-shaded (alternate initialized to 0). This solves the problem when there is only one row to display -- it is displayed shaded to visually indicate that it is "active", part of a "list", etc. (Compare this to the trivial case of more than one entry, where the rows have alternating shade, thus suggesting being part of a "list" of "active" entries, etc.) Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-28gitweb: Add history and blame to git_difftree_body()Luben Tuikov
Add blame and history to Deleted files. Add blame and history to Modified or Type changed files. Add blame and history to Renamed or Copied files. This allows us to do blame->commit->blame->commit->blame->... instead of blame->commit->file->blame->commit->file->blame->... which is longer and easier to get wrong. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-28gitweb: Remove excessively redundant entries from git_difftree_bodyLuben Tuikov
1) All entries on the left are blobs and clicking on them leads to blobs. No more diff or blob depending on what happened (modified or mode changed) to the file -- this goes to the right, in the "link" column. 2) Remove redundant "blob" from the link column on the right. This can now be had by clicking on the entry itself. This reduces and simplifies the code. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-28Revert "gitweb: extend blame to show links to diff and previous"Luben Tuikov
This concept is very fine, but it makes blame slow across renames and across branches, so revert it. There is a better way to do this. This reverts commit 03d06a8e26f4fbd37800d1e1125c6ecf4c104466. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-27gitweb: Quote filename in HTTP Content-Disposition: headerJakub Narebski
Finish work started by commit a2f3db2 (although not documented in commit message) of quoting using quotemeta the filename in HTTP -content_disposition header. Just in case filename contains end of line character. Also use consistent coding style to compute -content_disposition parameter. Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-27gitweb: Add git_url subroutine, and use it to quote full URLsJakub Narebski
Add git_url subroutine, which does what git_param did before commit a2f3db2f5de2a3667b0e038aa65e3e097e642e7d, and is used to quote full URLs, currently only $home_link. Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-27gitweb: Split validate_input into validate_pathname and validate_refnameJakub Narebski
Split validate_input subroutine into validate_pathname which is used for $project, $file_name and $file_parent parameters, and validate_refname which is used for $hash, $hash_base, $hash_parent and $hash_parent_base parameters. Reintroduce validation of $file_name and $file_parent parameters, removed in a2f3db2f validate_pathname in addition to what validate_input did checks also for doubled slashes and NUL character. It does not check if input is textual hash, and does not check if all characters are from the following set: [a-zA-Z0-9_\x80-\xff\ \t\.\/\-\+\#\~\%]. validate_refname first check if the input is textual hash, then checks if it is valid pathname, then checks for invalid characters (according to git-check-ref-format manpage). It does not check if all charactes are from the [a-zA-Z0-9_\x80-\xff\ \t\.\/\-\+\#\~\%] set. We do not have to validate pathnames we got from git. Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-27gitweb: Use "return" instead of "return undef" for some subsJakub Narebski
Use "return" instead of "return undef" when subroutine can return, or always return, non-scalar (list) value. Other places are left as is. Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-27gitweb: Strip trailing slashes from $path in git_get_hash_by_pathJakub Narebski
It also removes unused local variable $tree Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-27gitweb: extend blame to show links to diff and previousLuben Tuikov
git_blame2() now has two more columns, "Prev" and "Diff", before the "Commit" column, as follows: Prev Diff Commit Line Data SHA Diff SHA N ... ... The "Prev" column shows the SHA of the parent commit, between which this line changed. Clicking on it shows the blame of the file as of the parent commit, for that line. So clicking repeatedly on "Prev" would show you the blame of that file, from the point of view of the changes of that particular line whose "Prev" you're clicking on. The "Diff" column shows "Diff" which is a link to blobdiff between "Prev" and "Commit" commits _for that line_. So clicking on "Diff" would show you the blobdiff (HTML) between the parent commit and this commit which changed that particular line. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-27gitweb: Decode long title for link tooltipsYasushi SHOJI
This is a simple one liner to decode long title string in perl's internal form to utf-8 for link tooltips. This is not crucial if the commit message is all in ASCII, however, if you decide to use other encoding, such as UTF-8, tooltips ain't readable any more. Signed-off-by: Yasushi SHOJI <yashi@atmark-techno.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-27gitweb: Remove redundant "tree" linkLuben Tuikov
In "tree" view, remove redundant "tree" link in the tree listing. It is identical to simply clicking on the tree entry itself. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-26gitweb: tree view: eliminate redundant "blob"Luben Tuikov
Binary and non-binary blobs: The "list" table element of tree view is identical to the "blob" link part of the link table element. I.e. clicking on "blob" is identical to clicking on the entry itself. Thus, eliminate "blob" from being shown -- the user can get identical result by simply clicking on the entry itself. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-25gitweb: fix over-eager application of esc_html().Petr Baudis
Contents of %diffinfo hash should be quoted upon output but kept unquoted internally. Later users of this hash expect filenames to be filenames, not HTML gibberish. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-24gitweb: Consolidate escaping/validation of query stringPetr Baudis
Consider: http://repo.or.cz/?p=glibc-cvs.git;a=tree;h=2609cb0411389325f4ee2854cc7159756eb0671e;hb=2609cb0411389325f4ee2854cc7159756eb0671e (click on the funny =__ify file) We ought to handle anything in filenames and I actually see no reason why we don't, modulo very little missing escaping that this patch hopefully also fixes. I have also made esc_param() escape [?=&;]. Not escaping [&;] was downright buggy and [?=] just feels better escaped. ;-) YMMV. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-23Fix snapshot link in tree viewPetr Baudis
It would just give HEAD snapshot instead of one of the particular tree. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-23gitweb: Fix @git_base_url_list usagePetr Baudis
As it is now, that array was never used because the customurl accessor was broken and ''unless @url_list'' never happenned. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-23gitweb: Fix tree link associated with each commit log entry.Petr Baudis
The link forgot to have hb parameter and the resulting tree view failed to show the navbar for that commit. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-23Make path in tree view look nicerPetr Baudis
Based on talk on the IRC with Junio some evenings ago, I've updated the path showing in tree view to look better and sent updated patches privately, but it seems the old version ended up being used, so here's the new one again. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-22gitweb: Relabel "head" as "HEAD"Petr Baudis
"head" is a reference in refs/heads/, while those labels mean HEAD, the latest revision of the default branch. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-22gitweb: Rename "plain" labels to "raw"Petr Baudis
I don't have much preference either way and as far as I'm concerned, it may go the other way as well. Consistency is what is important. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-22gitweb: Link to associated tree from a particular log item in full log viewPetr Baudis
Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-22gitweb: Link to latest tree from the head line in heads listPetr Baudis
Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-22gitweb: Link to tree instead of snapshot in shortlogPetr Baudis
Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-22gitweb: More per-view navigation bar linksPetr Baudis
Navigation bars in various views were empty or missed important items that should have been there, e.g. getting a snapshot in tree view or log of ancestry in commit view... This feeble patch attempts to consolidate that. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-22gitweb: Link (HEAD) tree for each project from projects listPetr Baudis
Current projects list is oriented on easily getting "what's new" information. But when already using gitweb as an interface to something, I personally find myself to _much_ more frequently wanting to rather see "what's in" (or "what's new in") and it's quite annoying to have to go through the summary page (which is also rather expensive to generate) just to get there. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-09-21gitweb: Make git_get_hash_by_path check type if providedJakub Narebski
Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>