Commit Briefs
got patch: add -c flag to apply at a specified commit
it's useful for e.g. to apply old patches that weren't generated by `got diff' or git-diff(1) and so lacks the metadata needed for the 3-way merge. manpage improvements from and ok stsp@
`got patch' pledge early
ok stsp@
got patch: error if patchfile isn't a regular file
`got patch' cannot read patches from non-regular files for obvious reasons. However, it could crash in sendmsg because pledge doesn't allow to send file descriptors referring to directories. So, restrict `got patch' to operate on regular files only and fail otherwise. This still allows to read patches from symlinks since they're resolved at open(2) time and the file type check is performed after. There may be a marginal usefullness in reading patches from fifos, but the current code doesn't allow that anyway since got-read-patch needs a seekable file descriptor anyway. ok tracey@
tweak cmd_info; no functional changes intended
* don't allocate unused pack_fds * drop wpath, cpath, proc, exec and sendfd pledge promises * close the worktree ok stsp@
do not require local author info during 'got rebase'
My commit to reset committer info during rebase was too strict in some use cases. Even when simply forwarding a branch the rebase operation could now fail if GOT_AUTHOR is not set. To fix this, fall back on existing commiter information if no author is configured. And try to obtain author info from Git config in case GOT_AUTHOR is not set. Problems reported by Mikhail.
We don't care about the length of the read line.
Found by llvm's scan-build (dead store). OK stsp
Dot not ignore error from got_object_id_str().
Found by llvm's scan-build (dead store). OK stsp
typo in cat_commit
otherwise prints the author instead of the committer
got commit: add flag to specify the author
This adds a new flag, `got commit -A', that allows to specify the commit author but retains the "committer" (which is obtained as usual via GOT_AUTHOR, got.conf or git config.) with lots of help from and ok stsp
fix email address parsing
we were both too strict and too lose. To avoid breaking got object parser (and to some extent ours too) we need to ensure that there aren't any line feeds, extra < or > and no trailing gibberish. The '@' is not actually required in the email. various tweaks and ok stsp
histedit: make sure mesg is only used after pick or edit
It doesn't really make sense to use mesg after a fold or drop, or after another mesg. it currently "works" as intended, but the behaviour is confusing and not useful, better abort the operation as it's probably not what the user intended. Suggested by and ok stsp@
add signer_id option to got.conf(5)
Setting this option will cause 'got tag' to sign all created tags using the SSH key, unless overridden by the -s flag. ok stsp@
move 'got init' command to 'gotadmin init'
This functionality is better suited for gotadmin because it is technically a server-side repository operation when we consider the 'got' tool as the client-side tool. I have plans to move 'got import' into gotadmin as well. ok op@
fix tag signing when the key file does not exist
This should fail without creating any tag. Before, ssh-keygen(1) would print an error to stderr, but got would create an unsigned tag. ok op@
rename got.conf(5) mirror-references to mirror_references for consistency
Existing configuration files will keep working for now since the old name with dashes is still recognized by the config parser.
rename got.conf(5) fetch-all-branches to fetch_all_branches for consistency
Existing configuration files will keep working for now since the old name with dashes is still recognized by the config parser.