Commit Graph

935 Commits (lh/pretty-blob-view)
 

Author SHA1 Message Date
Lars Hjemli 271829f269 cgit.css: make diff headers more visible
This modifies the background color of diff headers to make them easier to
spot.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli e238ebe187 ui-diff: add links to pre- and postversion of blobs
Each diff header now links to the old and new version of each file

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 97aec64973 gen-version.sh: don't sed the output from git describe
Replacing '-' with '.' makes the version name slightly confusing, so lets
stick with the unmodified output of git describe.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 7e1af8ad92 css: remove the annoying tr:hover rule for diffstat
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 0ec8791ca0 ui-commit.c: link to diff instead of tree from diffstat
This makes each entry in the diffstat link to a path-restricted diff.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 1a6025b7a5 Add prefix parameter to cgit_print_diff()
This allows a diff to be restricted to the path prefix specified in the url.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli f527a57c8a Add prefix parameter to cgit_diff_tree()
This paramter can be used to restrict a diff to the specified path prefix.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 98fcf7227c Add support for a renamelimit option in cgitrc
This option can be used to override the default rename-limit in git.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli b65aa5d16f cgit v0.6.3
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 08b67765f9 Upgrade to GIT 1.5.3.2
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 4e40d8507e 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 /.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 0835ffefb8 Remove a few compiler warnings
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 6df9c7028a Add cgit.conf to .gitignore, remove *~
Not having cgit.conf in .gitignore is a bug, while having *~ is a personal
preference.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli ff7a39488a 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>
17 years ago
Lars Hjemli 63d5f5eaea ui-tree: specify parameter position for all htmlf formats
The GNU C library manual tells us that behavior is undefined if only
some formats has a specification for the parameter position.

Noticed-by: <mkraai@beckman.com>
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Michael Krelin 7921572fb1 fixed typo in cgitrc
Signed-off-by: Michael Krelin <hacker@klever.net>
17 years ago
Chris Pickel 0602d8c4f0 Improve the sample cgitrc file
Added and documented missing cgitrc parameters, improved documentation
for virtual-root, added examples for repositories with a working
directory.

[lh:sligthly modified/extended]

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 4beecc9a18 cgit v0.6.2 17 years ago
Lars Hjemli 6bfed7d233 Revert part of "Makefile: add support for DESTDIR"
This removes my editing on the patch received by Chris Pickel, as I didn't
understand the purpose of DESTDIR.

Noticed-by: Chris Pickel <sfiera@macports.org>
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 152c5e2aca Revert "Makefile: add missing references to DESTDIR"
This reverts commit fa31c5ed48, as I
totally misunderstood the purpose of DESTDIR.

Noticed-by: Chris Pickel <sfiera@macports.org>
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli af38d6565f cgit v0.6.1 17 years ago
Lars Hjemli fa31c5ed48 Makefile: add missing references to DESTDIR
When cgit is built it needs to get CGIT_CONFIG and CGIT_CACHE_ROOT prefix
with DESTDIR.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Chris Pickel 898f5f89d3 Make cgit honor CACHE_ROOT as defined in Makefile
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Chris Pickel 97ded7c1c3 Makefile: add support for DESTDIR
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 96a24212fd cgit v0.6
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli bd8e8a3d70 Update README
Add new build instructions, extend the "Missing features" section and add
a note about patches/email address of the author.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 0de21a8d41 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.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli ff13396926 Merge branch 'jo/dirlink'
* jo/dirlink:
  Rename dirlink to gitlink.

Conflicts:

	ui-tree.c

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 4e7e8bf961 Use git-1.5.3 as submodule
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 79f0c10df1 Delete submodules.sh and prepare for using git-submodule
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 95eaf2735e Makefile: add target "get-git"
The new target downloads a suitable git.git tarball from kernel.org and
unpacks it in the git directory.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli e8920b5262 Rewrite the makefile + gen-version.sh
The old files were simply broken, hopefully the new ones will work out
somewhat better.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 1221adbb58 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.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 43291e418a Make ui-tag.c generate valid xhtml
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli f405d0bf75 Add support for line number in url fragment
With this change, urls like http://hjemli.net/git/cgit/tree/ui-tree.c#43 can
be used to jump directly to the specified line number.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli eb45342e73 cgit_print_snapshot_links: use url to specify snapshot name
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 1d4aaff696 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

Conflicts:

	ui-summary.c

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Lars Hjemli 4e9107abfe Add ui-tag.c
This file implements the tag-command, i.e. printing of annotated tags.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
17 years ago
Michael Krelin d6b01dac85 link raw blob from tree file view
Signed-off-by: Michael Krelin <hacker@klever.net>
17 years ago
Michael Krelin bbd4a14456 fix: changed view link to blob in summary.
might not be the best way, but should suffice for now that view command isn't
 handled in any way

Signed-off-by: Michael Krelin <hacker@klever.net>
17 years ago
Michael Krelin dc3c9b5bc4 allow selective enabling of snapshots
snapshot configuration parameter now can be a
 space/slash/comma/colon/semicolon/pipe-separated list of snaphot suffixes as
 listed in ui-snapshot.c

Signed-off-by: Michael Krelin <hacker@klever.net>
17 years ago
Michael Krelin 97c025ae8e shorten snapshot names to repo basename
Signed-off-by: Michael Krelin <hacker@klever.net>
17 years ago
Michael Krelin 1cb8bedf1e introduce cgit_repobasename
that shortens reponame stripping any directories and .git suffixes, that is
 turning 'dir/repo.git/' or 'dir/repo/.git/' or alikes into mere 'repo'.

Signed-off-by: Michael Krelin <hacker@klever.net>
17 years ago
Michael Krelin 0df096f6e1 added snapshot filename to the link
- changed cgit_pageurl into cgit_fileurl with the filename parameter
 - rewritten cgit_pageurl as a wrapper around cgit_fileurl

Signed-off-by: Michael Krelin <hacker@klever.net>
17 years ago
Michael Krelin 86ca02231f add plain uncompressed tar snapshort format
time to make available snapshots selectable

Signed-off-by: Michael Krelin <hacker@klever.net>
17 years ago
Michael Krelin 18a99bdf87 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

Signed-off-by: Michael Krelin <hacker@klever.net>
17 years ago
Michael Krelin 4a92cbb7fd compress .tar.gz using gzip as a filter 17 years ago
Michael Krelin 127f43d4e2 added a chk_non_negative check 17 years ago
Michael Krelin 3aae82703b css: adjust vertical-align of commit info th cells 17 years ago
Michael Krelin f97c707a3b 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
17 years ago