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>
The deleted file should be labeled "renamed to" and the added file
"renamed from", not the other way around (duh!)
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
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>
If the administrator configures pathinfo to be overrideable by the
local repository a warning is shown.
Signed-off-by: Martin Waitz <tali@admingilde.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
This reduces the number of conflicts when rebasing after a series of
patches to the same piece of code is committed upstream.
Signed-off-by: Robert Shearman <rob@codeweavers.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
This allows web sites with a header and footer standard for each page
to add them to the pages produced by gitweb.
Two new variables $site_header and $site_footer are defined (default
to null) each of which can specify a file containing the header and
footer html.
In addition, if the $stylesheet variable is undefined, a new array
@stylesheets (which defaults to a single element of gitweb.css) can be
used to specify more than one style sheet. This allows the clasical
gitweb.css styles to be retained, but a site wide style sheet used
within the header and footer areas.
Signed-off-by: Alan Chandler <alan@chandlerfamily.org.uk>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Print commit-8 only on the first, leading row of
a commit block, to complement the per-commit block coloring.
Signed-off-by: Luben Tuikov <ltuikov@yahoo.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Luben makes a good argument against it, and I agree with him in general.
The clickable handle that appear at seemingly random places makes them
look as if they are separating groups when it is not.
This also restores the executable bit I lost by mistake.
Signed-off-by: Junio C Hamano <junkio@cox.net>
Still not managed to understand git-send-mail sufficiently well to not
accidently miss of this list when I sending it to Junio
Signed-off-by: Alan Chandler <alan@chandlerfamily.org.uk>
Signed-off-by: Junio C Hamano <junkio@cox.net>
When a repository is initialized long time ago with symbolic
HEAD, and "git-pack-refs --prune" is run, HEAD will be a
dangling symlink to refs/heads/ somewhere.
Running -e "$dir/HEAD" to guess if $dir is a git repository does
not give us the right answer anymore in such a case.
Also factor out two places that checked if the repository can be
exported with similar code into a call to a new function,
check_export_ok.
Signed-off-by: Junio C Hamano <junkio@cox.net>
Instead of labelling each and every line with clickable commit
object name, this makes the blame output to show them only on
the first line of each group of lines from the same revision.
Placing too many lines in one group would make the commit object
name to appear too widely separated and also makes it consume
more memory, the number of lines in one group is capped to 20
lines or so.
Also it makes mouse-over to show the minimum authorship and
authordate information for extra cuteness ;-).
Signed-off-by: Junio C Hamano <junkio@cox.net>
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>
Take a look at commit 20a3847d8a
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>
Fixes a failure to build the git-rev-parse manpage, seen with
asciidoc 8.0.0
We would love to use nicer quoting $$~$$ but alas asciidoc 7
does not know about it. So use asciidoc.conf and define {tilde}
to be ~.
Signed-off-by: Junio C Hamano <junkio@cox.net>
Acked-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
lock_ref_sha1_basic relies on errno beeing set to EISDIR by the
call to read() in resolve_ref() to detect directories. But calling
read() on a directory under NetBSD returns EPERM, and even succeeds
for local filesystems on FreeBSD.
Signed-off-by: Dennis Stosberg <dennis@stosberg.net>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Instead of providing the project as a ?p= parameter it is simply appended to
the base URI. All other parameters are appended to that, except for ?a=summary
which is the default and can be omitted.
The this can be enabled with the "pathinfo" feature in gitweb_config.perl.
[jc: let's introduce new features disabled by default not to
upset too many existing installations.]
Signed-off-by: Martin Waitz <tali@admingilde.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Although most people would have one after colon if only for
readability, we never required it in git-parse-remote, so let's
not require one only in git-push.
Signed-off-by: Junio C Hamano <junkio@cox.net>
The command updated the cache without invalidating the cache
tree entries while removing an existing entry.
Signed-off-by: Junio C Hamano <junkio@cox.net>
We advertised git-merge-recur for some time, and we planned to
support it for one release after we made it the 'recursive'.
However we forgot to install it nor have "make clean" clean it.
Signed-off-by: Junio C Hamano <junkio@cox.net>
* jc/gitpm: (52 commits)
Remove -fPIC which was only needed for Git.xs
Git.pm: Kill Git.xs for now
Revert "Make it possible to set up libgit directly (instead of from the environment)"
Revert "Git.pm: Introduce fast get_object() method"
Revert "Convert git-annotate to use Git.pm"
Fix compilation with Sun CC
pass DESTDIR to the generated perl/Makefile
Eliminate Scalar::Util usage from private-Error.pm
Convert git-annotate to use Git.pm
Git.pm: Introduce fast get_object() method
Make it possible to set up libgit directly (instead of from the environment)
Work around sed and make interactions on the backslash at the end of line.
Git.pm: Introduce ident() and ident_person() methods
Convert git-send-email to use Git.pm
Git.pm: Add config() method
Use $GITPERLLIB instead of $RUNNING_GIT_TESTS and centralize @INC munging
INSTALL: a tip for running after building but without installing.
Perly Git: make sure we do test the freshly built one.
Git.pm: Don't #define around die
Git.xs: older perl do not know const char *
...
In particular it removes duplicate information, uses short hashes (as
git-log and company) and uses .. for fast forwarding commits and ... for
not-fast-forwarding commits (shorter, easier to copy&paste). It also
reformat the output as:
1. the ones we store in our local ref (either branches or tags):
1a) fast-forward
* refs/heads/origin: fast forward to branch 'master' of ../git/
old..new: 1ad7a06..bc1a580
1b) same (only shown under -v)
* refs/heads/next: same as branch 'origin/next' of ../git/
commit: ce47b9f
1c) non-fast-forward, forced
* refs/heads/pu: forcing update to non-fast forward branch 'pu' of ../git/
old...new: 7c733a8...5faa935
1d) non-fast-forward, did not update because not forced
* refs/heads/po: not updating to non-fast forward branch 'po' of ../git/
old...new: 7c733a8...5faa935
1e) creating a new local ref to store
* refs/tags/v1.4.2-rc4: storing tag 'v1.4.2-rc4' of ../git/
tag: 8c7a107
* refs/heads/next: storing branch 'next' of ../git/
commit: f8a20ae
2. the ones we do not store in our local ref (only shown under -v):
* fetched branch 'master' of ../git
commit: 695dffe
* fetched tag 'v1.4.2-rc4' of ../git
tag: 8c7a107
Signed-off-by: Santi B.ANijar <sbejar@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
* jc/diff-stat:
diff --stat: ensure at least one '-' for deletions, and one '+' for additions
diff --stat=width[,name-width]: allow custom diffstat output width.
diff --stat: color output.
diff --stat: allow custom diffstat output width.
* 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"
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>
Geert noticed that complete rewrite diff missed the usual a/ and b/
leading paths. Pickaxe says it never worked, ever.
Embarrassing.
Signed-off-by: Junio C Hamano <junkio@cox.net>
(cherry picked from bc1a580757 commit)
Somebody was wondering on #git channel why a git generated diff
does not apply with GNU patch when the filename contains a SP.
It is because GNU patch expects to find TAB (and trailing timestamp)
on ---/+++ (old_name and new_name) lines after the filenames.
The "diff --git" output format was carefully designed to be
compatible with GNU patch where it can, but whitespace
characters were always a pain.
We can make our output a bit more GNU patch friendly by adding an
extra TAB (but not trailing timestamp) to old/new name lines when
the filename as a SP in it. This updates git-apply to prepare
ourselves to accept such a patch, but we still do not generate
output that is patch friendly yet. That change needs to wait
until everybody has this change.
When a filename contains a real tab, "diff --git" format
always c-quotes it as discussed on the list with GNU patch
maintainer previously:
http://marc.theaimsgroup.com/?l=git&m=112927316408690&w=2
so there should be no downside.
Signed-off-by: Junio C Hamano <junkio@cox.net>
This prevents the fetch of the heads again in the second call of fetch_main.
Signed-off-by: Santi Béjar <sbejar@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
The distinction between BASIC_ vs ALL_ is still kept, since it
is not Git.xs specific -- we could face the same issue when we
do other language bindings (e.g. Python).
Signed-off-by: Junio C Hamano <junkio@cox.net>
It just simplifies the whole thing to say
"hour = (hour % 12) + X"
where X is 12 for PM and 0 for AM.
It also fixes the "exact date" parsing, which didn't parse AM at all, and
as such would do the same "12:30 AM" means "12:30 24-hour-format" bug. Of
course, I hope that no exact dates use AM/PM anyway, but since we support
the PM format, let's just get it right.
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Geert noticed that complete rewrite diff missed the usual a/ and b/
leading paths. Pickaxe says it never worked, ever.
Embarrassing.
Signed-off-by: Junio C Hamano <junkio@cox.net>
The number of '-' and '+' is still linear. The idea is that
scaled-length := floor(a * length + b) with the following constraints: if
length == 1, scaled-length == 1, and the combined length of plusses
and minusses should not be larger than the width by a small margin. Thus,
a + b == 1
and
a * max_plusses + b + a * max_minusses + b = width + 1
The solution is
a * x + b = ((width - 1) * (x - 1) + max_change - 1)
/ (max_change - 1)
Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
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>
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>
If http.noEPSV config variable is defined and true, or if
GIT_CURL_FTP_NO_EPSV environment variable is defined, disable using
of EPSV ftp command (PASV will be used instead). This is helpful with
some "poor" ftp servers which does not support EPSV mode.
Signed-off-by: Sasha Khapyorsky <sashak@voltaire.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
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>
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>