Commits
- Commit:
c24e2d2e71abf0ac4feb95dc4f238d454819fed9
- From:
- Lucas Gabriel Vuotto <lucas@sexy.is>
- Via:
- Thomas Adam <thomas.adam22@gmail.com>
- Date:
replace date, strftime %G-%m-%d with %F
Use the more predictable %F, aka %Y-%m-%d, instead of %G-%m-%d. %G
follows the definition of ISO-8601 week-based year, which is weird.
In particular, 2024 is one of such years with weird behaviour:
$ date -jf %Y-%m-%d +"%F %G-%m-%d" 2024-12-30
2024-12-30 2025-12-30
Diff from Lucas Gabriel Vuotto (thanks!); stsp agrees
- Commit:
0279329dccffda40b130fe1a08f888694df1238f
- From:
- Stefan Sperling <stsp@stsp.name>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
rename got_commit_graph_iter_start() to got_commit_graph_bfsort()
This function begins a breadth-first traversal. The new name makes
it easier to distinguish from got_commit_graph_toposort().
- Commit:
f03e50d6fa7d457cde6feabb23a528f11bb45461
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: guard against missig folder and file parameter in BLOB and BLAME
ok stsp
- Commit:
978394e7c1b381b6d87cda75ebfaf507bb01ec64
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: use 'more' for the tag listing too
prodded by stsp and jamsek; ok stsp@
- Commit:
34875d49d76084b885a5ee82586965a633787bb2
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: render READMEs in the tree view
ok tracey@
- Commit:
feaddee622f43226923713b48d635518d166e5e5
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: add patch action to serve diffs in plain text
ok tracey@
- Commit:
f85c939fb7758c7cad91e0705b4d932d52597867
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: get rid of proc.[ch]
proc.c really shines when there's a network of different types of
processes, potentially with a various number of instances each,
that needs to exchange messages. Gotwebd instead has a much simpler
design, and using proc.c causes more overhead (/headaches) than it
solves.
So, this attempts to provide the same functionalities but with a
much simpler implementation that fits gotwebd better.
ok stsp@
- Commit:
b38bef130a0b3f87cc472394f280940bd4e72238
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: fix branches modification time with show_repo_age off
If show_repo_age is set to off, got_get_repo_age() returns without
setting the timestamp. got_get_repo_age() is also used by the
branch listing to show how old they are however, and we end up
rendering the stack garbage.
Instead, respect `show_repo_age off' one layer above, and always
return a timestamp in got_get_repo_age(). While here, initialize
the timestamp to zero so it's set also in case of failures.
Issue reported on IRC by xs, thanks!
- Commit:
102d840de78061d9f313aaa557ef64f586932143
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
dropping unnecessary strlen()s
ok jamsek, stsp
- Commit:
6c24d194f2260b073d8e8ad3e756efa3ce20dd2e
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
change got_get_repo_tags' limit argument to size_t
The function already carefully avoids wrapping around zero. While
here add a sanity check for limit == 0, like what was previously done
for got_get_repo_commits().
- Commit:
087cc2fc09698b114296411034739df31c999471
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: make got_get_repo_commits take a size_t
and while here make sure 0 is rejected.
requested by, improvements and ok stsp@
- Commit:
7272b60a19e7deee3a1808cbda935e201074c50d
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: simplify got_get_repo_commits(): don't traverse all the commits!
In some cases (e.g. limit=1 for DIFF action) we could end up traversing
all the commits instead of fetching just the one requested. Needless to
say, this makes the diff page extremely slow.
reported by and ok stsp@
- Commit:
d8edcc947b59de53c551373983750441a33bbe02
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: fix some got_error_from_errno2/3 calls
it's not printf-like so %s don't make sense. Tweak the order of
the arguments to obtain the intended output.
- Commit:
72f5a11aff98b21aafaf38400707411549e7c12b
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: avoid needless double fseek()
got_gotweb_closefile() already takes care of rewinding before
truncating and closing, so no need to replicate here.
ok stsp@
- Commit:
aa2aecab69ed4f6ff9ab2a5bb7e32109cf95aefc
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
gotwebd: lower log priority of unexpected disconnections
no need to be so loud when a client disconnects earlier than expected,
log it only in verbose mode. Don't log GOT_ERR_CANCELLED too since
that is only used to communicate the callers that we need to stop.
ok stsp@
- Commit:
5e43aca66f1762b7612d9efb4b000575f1b7a3ab
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
oops, one was missing
- Commit:
a97a7b2d0f3aef38c682073294822e88e1c2ef1c
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
got_operations.c: use consistently a space before labels
makes diff prettier and easier to read; instead of the label we
have the function name in the hunk line.
- Commit:
c4c6774f44148ea66dc566dfdcf36f531f9e5291
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
remove fsync() from got_gotweb_closefile()
discussed with millert@
- Commit:
d00235d81cec70db37ca306ea1db137a5464982e
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
rename got_gotweb_flushfile -> got_gotweb_closefile
suggested and ok millert@
- Commit:
985ec13bc7dc1bc1885d8111e51ea98c619d0d4e
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
make got_gotweb_flushfile always close the file
ok millert@
- Commit:
db26fc4c9b43331d8bc1536cc9f576724710b817
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
rename some local fdN vars after previous change
- Commit:
04b2c111f2cee68f0aa07855fcb7329a4913050b
- From:
- Omar Polo <op@omarpolo.com>
- Via:
- Thomas Adam <thomas@xteddy.org>
- Date:
simplify got_gotweb_openfile/flushfile
Return only the FILE *, and require only that to close subsequently.
Having to manage the file descriptor too makes using these functions
unnecessary complex.
millert@ agrees
- Commit:
4fccd2fe0ffbbc668b66abe63614470635f92f1b
- From:
- Thomas Adam <thomas@xteddy.org>
- Date:
portable: configure: split out dependencies
Rather than assume all dependencies are required for all programs, split
them out.
This will make packaging easier, as well as splitting the code to use
subprojects.
Note that due to the use of config.h semantics, in most cases the
got_compat.h header file is now at the top of the .c file it is included
in, so that it can handle the system header inclusion properly.
- Commit:
98670ba726486c39efff220ab1e074c62023aae7
- From:
- Thomas Adam <thomas@xteddy.org>
- Date:
portable: rework SHA detection
Simply the SHA detection by not predicating on libcrypto, but instead
checking individual header files.
- Commit:
4680f704353811c8bb6ce65eac3714d1bd200c26
- From:
- Thomas Adam <thomas@xteddy.org>
- Date:
portable: remove sha1.h; found portably
Remove sha1.h as this is found portably across systems.