Hiltjo Posthuma [Sat, 15 Jul 2017 11:50:24 +0000 (13:50 +0200)]
improve example, add initial post-receive example
Hiltjo Posthuma [Thu, 6 Jul 2017 11:20:41 +0000 (13:20 +0200)]
README: add example for a git hook and to set the url file
Hiltjo Posthuma [Wed, 5 Jul 2017 18:25:54 +0000 (20:25 +0200)]
README: add example to create tar.gz archives by tag
Hiltjo Posthuma [Sun, 25 Jun 2017 10:28:59 +0000 (12:28 +0200)]
Makefile: remove TODO
fixes make dist, thanks stateless :)
Hiltjo Posthuma [Fri, 23 Jun 2017 12:03:14 +0000 (14:03 +0200)]
remove TODO
Hiltjo Posthuma [Fri, 23 Jun 2017 11:53:46 +0000 (13:53 +0200)]
separate getstats from getbyoid: slightly faster
Hiltjo Posthuma [Sun, 7 May 2017 11:12:43 +0000 (13:12 +0200)]
for the commit Date: header use the git format-patch format
Hiltjo Posthuma [Sun, 7 May 2017 10:02:48 +0000 (12:02 +0200)]
dont truncate summary length anymore
make sure not partial (invalid) utf-8 sequences are written. The old logic
truncated by bytelen was wrong. It is too complex to implement it in a
correct way with git: it is not assured a commit message is UTF-8 encoded.
remove showlinecount and summarylen variables.
Hiltjo Posthuma [Thu, 4 May 2017 22:23:50 +0000 (00:23 +0200)]
remove config.def.h: it was not used anymore
thanks tarug0 for reporting it!
Hiltjo Posthuma [Sat, 22 Apr 2017 17:07:07 +0000 (19:07 +0200)]
improve commitinfo_getstats
- reorder: unnecessary allocation when git_patch_from_diff fails.
- no need to free patch object when git_patch_from_diff fails.
Hiltjo Posthuma [Sat, 22 Apr 2017 12:38:39 +0000 (14:38 +0200)]
improve documentation
- add example to README to extract gitweb.owner from a git config.
this is used in gitweb and some cgit configurations.
- fix (new) mandoc warnings (new sentence on each line).
- improve some texts in the man pages, sort / structure some list items.
Hiltjo Posthuma [Mon, 17 Apr 2017 14:39:03 +0000 (16:39 +0200)]
align line numbers to 8 spaces
... now it is done.
Hiltjo Posthuma [Mon, 17 Apr 2017 14:16:33 +0000 (16:16 +0200)]
writeblobhtml: minor style fix
using len instead of the loop 'i' is slightly more clear
Hiltjo Posthuma [Mon, 17 Apr 2017 11:39:05 +0000 (13:39 +0200)]
stagit: fix rendering of first TAB in file
else TABs wont render properly (interpreted as part of HTML whitespace)
at the first TAB of the line.
Hiltjo Posthuma [Mon, 17 Apr 2017 11:13:26 +0000 (13:13 +0200)]
stagit-index: also dont assume someones <html lang> :)
Hiltjo Posthuma [Mon, 17 Apr 2017 11:06:02 +0000 (13:06 +0200)]
stagit-index: remove Content-Language: en
forgot to remove this from stagit-index aswell, see also:
commit
9e96062b620088a42c7b345e07cc8c12e2b59ed2
Hiltjo Posthuma [Sun, 16 Apr 2017 18:59:23 +0000 (20:59 +0200)]
writeblobhtml: fix possible uninitialized variable n when len == 0
... whoops
Hiltjo Posthuma [Sun, 16 Apr 2017 18:37:42 +0000 (20:37 +0200)]
writeblobhtml: improve file view for text-browsers
browsers such as lynx and w3m have some quirks displaying tables and pre
elements.
links is a bit better with this.
Hiltjo Posthuma [Sun, 16 Apr 2017 18:36:48 +0000 (20:36 +0200)]
stagit-index: remove empty h1 and add bold markup to table headers
Hiltjo Posthuma [Sun, 16 Apr 2017 18:36:17 +0000 (20:36 +0200)]
text-browser improvements
for links, lynx, w3m, dil[dl]o etc:
- set oldschool align attribute.
- apply bold markup to table header.
Hiltjo Posthuma [Sun, 16 Apr 2017 18:32:34 +0000 (20:32 +0200)]
README: advertise text-browser improvements
Hiltjo Posthuma [Sun, 16 Apr 2017 18:32:23 +0000 (20:32 +0200)]
LICENSE: bump year
Hiltjo Posthuma [Sat, 15 Apr 2017 10:56:29 +0000 (12:56 +0200)]
browser compatibility: use numeric entity for '
' is a XHTML entity, browsers such as links, w3m, lynx and dillo
don't support it.
Hiltjo Posthuma [Sat, 1 Apr 2017 17:33:19 +0000 (19:33 +0200)]
writeblobhtml, make fprintf format string const
Hiltjo Posthuma [Sat, 25 Mar 2017 12:28:46 +0000 (13:28 +0100)]
README: add instructions to build static binaries
Hiltjo Posthuma [Sat, 25 Mar 2017 12:14:26 +0000 (13:14 +0100)]
Makefile: change () to {} consistently
reported by tarug0, thanks!
Hiltjo Posthuma [Sun, 12 Mar 2017 20:30:43 +0000 (21:30 +0100)]
fix potential leak, found by clang-analyzer
Hiltjo Posthuma [Sun, 12 Mar 2017 20:24:07 +0000 (21:24 +0100)]
fix memory leak of commitinfo
Hiltjo Posthuma [Sun, 12 Mar 2017 18:51:13 +0000 (19:51 +0100)]
atom.xml: add newline before EOF
Hiltjo Posthuma [Sun, 12 Mar 2017 18:50:45 +0000 (19:50 +0100)]
fix memory leak of commitinfo->parent
Hiltjo Posthuma [Sun, 12 Mar 2017 18:50:12 +0000 (19:50 +0100)]
fix memory leak of blob object
Hiltjo Posthuma [Sun, 12 Mar 2017 18:49:14 +0000 (19:49 +0100)]
simplify/shorten pledge stub
Hiltjo Posthuma [Sun, 12 Mar 2017 18:47:58 +0000 (19:47 +0100)]
reduce scope of repodir, remove unused branch parameter
Hiltjo Posthuma [Thu, 5 Jan 2017 17:47:26 +0000 (18:47 +0100)]
bump version to 0.5
Hiltjo Posthuma [Wed, 9 Nov 2016 17:28:46 +0000 (18:28 +0100)]
also remove language and text direction attribute from <html>
Hiltjo Posthuma [Wed, 9 Nov 2016 16:49:38 +0000 (17:49 +0100)]
remove Content-Language: en
thanks Aymeric Mansoux!
Hiltjo Posthuma [Fri, 14 Oct 2016 10:12:35 +0000 (12:12 +0200)]
stagit.1: also document linking to git submodules: .gitmodules file
Hiltjo Posthuma [Thu, 13 Oct 2016 16:10:52 +0000 (18:10 +0200)]
stagit.1: clarify README and LICENSE link creation
thanks Solene Rapenne for the patch! (slightly modified)
Hiltjo Posthuma [Thu, 15 Sep 2016 18:44:47 +0000 (20:44 +0200)]
simplify example.sh, thanks emg for the suggestion!
Hiltjo Posthuma [Wed, 20 Jul 2016 16:15:18 +0000 (18:15 +0200)]
update LICENSE
Hiltjo Posthuma [Sat, 2 Jul 2016 10:44:34 +0000 (12:44 +0200)]
config.mk: remove -lc
Thanks quinq!
POSIX/quinq says:
"In the absence of options that inhibit invocation of the link editor, such as
-c or -E, the c99 utility shall cause the equivalent of a -l c option to be
passed to the link editor after the last pathname operand or -l option, causing
it to be searched after all other object files and libraries are loaded."
Hiltjo Posthuma [Sun, 29 May 2016 13:04:52 +0000 (15:04 +0200)]
treat an empty repo (without a HEAD) as valid
and create the standard files. Disable caching if there is no HEAD.
Hiltjo Posthuma [Sun, 29 May 2016 11:06:32 +0000 (13:06 +0200)]
improve example: strip .git suffix
stagit-index and stagit strip the .git suffix so also strip it from the
directory for the possible www root.
Thanks to ng0 for reporting it!
Hiltjo Posthuma [Sat, 21 May 2016 16:37:53 +0000 (18:37 +0200)]
refs_cmp: simplify check, functionally the same
Hiltjo Posthuma [Sun, 8 May 2016 18:35:49 +0000 (20:35 +0200)]
check if LICENSE, README and .gitmodules is a file blob
don't link to directory trees, etc. Thanks 600360 for reporting it!
Hiltjo Posthuma [Sat, 7 May 2016 13:03:40 +0000 (15:03 +0200)]
release 0.4
Hiltjo Posthuma [Sat, 7 May 2016 12:43:35 +0000 (14:43 +0200)]
update TODO
Hiltjo Posthuma [Sat, 7 May 2016 12:38:39 +0000 (14:38 +0200)]
simplify, id is unused
Hiltjo Posthuma [Sat, 7 May 2016 12:34:26 +0000 (14:34 +0200)]
simplify, no need for goto
Hiltjo Posthuma [Sat, 7 May 2016 12:33:36 +0000 (14:33 +0200)]
improve stagit.1 documentation, reword and explain caching behaviour
Hiltjo Posthuma [Sat, 7 May 2016 12:29:39 +0000 (14:29 +0200)]
consistency for messages for special-case in diffstat
Hiltjo Posthuma [Sat, 7 May 2016 11:52:42 +0000 (13:52 +0200)]
fix error in "code cleanup" commit
9328d2690e118127bcaa5cf9f665d8e7711f7a03
... the loop was simplified, but forgot to remove p++ (double used) while
rebasing the change.
Hiltjo Posthuma [Fri, 6 May 2016 10:01:57 +0000 (12:01 +0200)]
fix and simplify time offset
Hiltjo Posthuma [Fri, 6 May 2016 09:49:25 +0000 (11:49 +0200)]
make diffstat files an anchor (jump to delta)
Hiltjo Posthuma [Tue, 3 May 2016 18:42:46 +0000 (20:42 +0200)]
fix joinpath(): use of global 'repodir', should be 'path'
use joinpath for another case.
Hiltjo Posthuma [Tue, 3 May 2016 18:28:09 +0000 (20:28 +0200)]
fix regression from last commit
Hiltjo Posthuma [Tue, 3 May 2016 18:18:37 +0000 (20:18 +0200)]
code cleanup
Hiltjo Posthuma [Mon, 2 May 2016 22:38:33 +0000 (00:38 +0200)]
remove config.h, add options to stagit.c
Hiltjo Posthuma [Mon, 2 May 2016 22:33:56 +0000 (00:33 +0200)]
add OpenBSD pledge(2) support using -DUSE_PLEDGE
Hiltjo Posthuma [Mon, 2 May 2016 19:48:47 +0000 (21:48 +0200)]
example.sh: use cache file
Hiltjo Posthuma [Mon, 2 May 2016 19:23:17 +0000 (21:23 +0200)]
style: write atom feed end in one write, kills 2 lines
Hiltjo Posthuma [Sun, 1 May 2016 15:54:14 +0000 (17:54 +0200)]
cache support (-c option)
"Optionally the -c cachefile option can be used to cache the entries of
the log page up to the point of the last commit. The cachefile will store
the last commit id and the entries in the HTML table."
this caches the diffstat and commits, it is an expensive operation (twss).
Hiltjo Posthuma [Sun, 1 May 2016 17:08:36 +0000 (19:08 +0200)]
small code cleanup: no need for status variable
Hiltjo Posthuma [Sun, 1 May 2016 15:20:54 +0000 (17:20 +0200)]
atom feed: use published for author commit date, updated for committer date
this is the same as cgit.
Hiltjo Posthuma [Sun, 1 May 2016 14:10:17 +0000 (16:10 +0200)]
fix times (and timezone)
- in the index and log show the short time (GMT).
- in the Atom feed use GMT time.
- for commits show the time + offset.
Hiltjo Posthuma [Sun, 1 May 2016 12:41:51 +0000 (14:41 +0200)]
README: minor update
Hiltjo Posthuma [Sun, 1 May 2016 12:38:57 +0000 (14:38 +0200)]
fix path join '/'
add joinpath() function to handle this.
Hiltjo Posthuma [Sun, 1 May 2016 12:09:42 +0000 (14:09 +0200)]
code cleanup + style, functionally equivalent
Hiltjo Posthuma [Sat, 30 Apr 2016 11:08:44 +0000 (13:08 +0200)]
layout: right align lines changed count in diffstat
Hiltjo Posthuma [Sat, 30 Apr 2016 10:00:33 +0000 (12:00 +0200)]
optimization: suppress large diffs
the values are arbitrary, these can be tweaked later if needed.
Hiltjo Posthuma [Sat, 30 Apr 2016 09:54:33 +0000 (11:54 +0200)]
optimization: read stats once and remember it
for an initial run and new commits this speeds stagit up a bit:
on an initial run of sbase goes from about 4 seconds to 2.8 on my machine.
now we can't use statsbuf, so create the stats string ourselves, while at it
color the + and - using a style (can be disabled for the color-haters out
there ;)).
Hiltjo Posthuma [Fri, 29 Apr 2016 19:52:29 +0000 (21:52 +0200)]
example.sh: fix: sort list (regression from simplifying the script)
Hiltjo Posthuma [Fri, 29 Apr 2016 19:24:58 +0000 (21:24 +0200)]
whoops, module is m---------
Hiltjo Posthuma [Fri, 29 Apr 2016 19:14:46 +0000 (21:14 +0200)]
submodule support
- detect .gitmodules file for submodules, add a link "submodules" to the top menu.
- link each submodule to the .gitmodules file in HEAD.
- revert the special style for modules, but list it as a file "m---------", don't show
the line/filesize though, it is not a file.
Hiltjo Posthuma [Fri, 29 Apr 2016 14:39:33 +0000 (16:39 +0200)]
suppress meaningless error codes when a repo can't be opened (similar to stagit-index)
Hiltjo Posthuma [Fri, 29 Apr 2016 14:38:48 +0000 (16:38 +0200)]
improve example, remove sort hack
Hiltjo Posthuma [Fri, 29 Apr 2016 13:57:55 +0000 (15:57 +0200)]
make submodule link black, easier to read
this is also the same color as a bare repo without a link.
Hiltjo Posthuma [Fri, 29 Apr 2016 13:55:33 +0000 (15:55 +0200)]
minor style fix
Quentin Rameau [Fri, 29 Apr 2016 12:01:45 +0000 (14:01 +0200)]
Fix null pointer access for submodules in writefilestree
Do not try to set a link to submodules from bare repo as we can't get
the actual url.
Hiltjo Posthuma [Fri, 29 Apr 2016 10:32:36 +0000 (12:32 +0200)]
tweak style of showing submodules
this will make it look similar to cgit. show mode as "m---------"
z3bra [Thu, 28 Apr 2016 23:40:30 +0000 (01:40 +0200)]
Don't fail on submodules
Submodules will get listed prefixed with a '@', using a specific CSS class for
styling. The href will be set to the url of the submodule.
Filesize will appear as 0 and filemode will not be printed to avoid an awkward
mode: "?---------".
In writefilestree, we don't return anymore if an entry can't be categorized as
an object, but rather, fail if we can't retrieve its name.
Hiltjo Posthuma [Wed, 27 Apr 2016 17:24:15 +0000 (19:24 +0200)]
fix: check gmtime, can return NULL on error
Hiltjo Posthuma [Wed, 27 Apr 2016 17:19:50 +0000 (19:19 +0200)]
resolve absolute paths to repodir, remove basename just use strrchr.
- resolve repodir, for example: stagit-index ../ used to use ".." as the name,
now it will resolve to the real directory name.
- just use strrchr(path, '/') instead of basename, '/' path separator is now
used.
Hiltjo Posthuma [Wed, 27 Apr 2016 14:40:51 +0000 (16:40 +0200)]
stagit-index: remove unused efopen function
Hiltjo Posthuma [Wed, 27 Apr 2016 14:39:48 +0000 (16:39 +0200)]
fix: link to line in hunk if a patch has multiple files and hunks
thanks to lostd for reporting it!
sin [Fri, 25 Mar 2016 09:30:19 +0000 (09:30 +0000)]
clean generated tarball too
Hiltjo Posthuma [Sun, 20 Mar 2016 16:29:31 +0000 (17:29 +0100)]
Makefile: use NAME variable, suggested by Quentin
Hiltjo Posthuma [Sun, 20 Mar 2016 15:23:33 +0000 (16:23 +0100)]
Makefile: separate CPPFLAGS, compile optimized build by default
Hiltjo Posthuma [Sun, 20 Mar 2016 14:36:21 +0000 (15:36 +0100)]
improve make dist, thanks Quentin Rameau
based on a patch from Quentin with some additions.
- don't build before make dist
- package in directory: stagit-VERSION.
Hiltjo Posthuma [Sun, 20 Mar 2016 13:19:48 +0000 (14:19 +0100)]
premature version bumperation, 0.4 (unreleased)
FRIGN [Tue, 1 Mar 2016 16:15:07 +0000 (17:15 +0100)]
Choose better colors for the diff page
This makes it easier to read on the light background and is not as
straining in the eyes.
Hiltjo Posthuma [Tue, 1 Mar 2016 18:14:00 +0000 (19:14 +0100)]
add titles to pages, summary for commit messages, filename for files
Hiltjo Posthuma [Fri, 26 Feb 2016 18:59:11 +0000 (19:59 +0100)]
fix right-alignment of "Files" column
lostd [Wed, 20 Jan 2016 14:36:16 +0000 (16:36 +0200)]
Use the recommended HTML5 document type.
Hiltjo Posthuma [Wed, 24 Feb 2016 13:47:20 +0000 (14:47 +0100)]
check path truncation
be strict about it
Hiltjo Posthuma [Wed, 24 Feb 2016 13:41:37 +0000 (14:41 +0100)]
config.mk: add -D_DEFAULT_SOURCE to commented builds
Hiltjo Posthuma [Tue, 23 Feb 2016 19:44:00 +0000 (20:44 +0100)]
atom feed: add link, move content order to bottom
NOTE: using relative links violates the Atom specification, but relative
links are convenient aswell.
Hiltjo Posthuma [Tue, 23 Feb 2016 19:37:17 +0000 (20:37 +0100)]
make printshowfile more generic and like other functions
Hiltjo Posthuma [Thu, 21 Jan 2016 19:42:11 +0000 (20:42 +0100)]
just use Name as first column, thanks quinq for the suggestion
Quentin Rameau [Thu, 21 Jan 2016 17:34:14 +0000 (18:34 +0100)]
Rename “Age” column headers into “Date”