Commit Briefs

1c72bab5d1 Thomas Adam

portable: regress: drop GNU date on *BSDs

Check if date(1) supports -r and fallback to gdate if that fails, via a shell-wrapper. From Christian "naddy" Weisgerber.


a796e0cb12 Thomas Adam

typo


28466fcabc Thomas Adam

fix diff and log diffstat tests broken in 65dedee0a2cd

I failed to update regress when changing the diffstat summary line in the previous commit to use a singular noun after 1. ok op@ and stsp@


8d5e51600d Thomas Adam

regress: replace echo \n with printf and heredoc

echo \n is not really portable. Not that it matters since the regress suite is already using non-POSIX features (like `local'). However, it's the only place using it and easy to fix. ok jamsek


964791552c Thomas Adam

add regress for new got log -d switch

ok stsp@


bf3ab20628 Thomas Adam

fix regression test failures with Git 3.30.5 / 2.38.1 or later installed

The fix for CVE-2022-39253 in Git made our regression tests fail since creating submodules from local clones is no longer allowed by default. Add an override to our invocations of "git submodule add", the same which was added to Git's regression test suite as part of their fix. This CVE doesn't otherwise affect us. We do not implement submodules. Our use of them in regression tests exists only to ensure that Got does not freak out when it sees one. Precisely because automated support for nested repositories and/or working copies (as in Git Submodules, or Subversion Externals, etc.) have been an endless source of security problems in other systems. sudden test failures pointed out by naddy@


b6b86fd1b9 Thomas Adam

remove trailing whitespace; patch by Josiah Frentsos


8fe0cd3a6f Thomas Adam

portable: regress: rework date command for Ubuntu

Don't rely on '-r' for date as it's not consistent across linuxses. Instead, expand the variables required and use '-d'. OK thomas@


27b10c3cfd Thomas Adam

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@


9b4458b410 Thomas Adam

always show commit or tree IDs in diff header, in order to help 'got patch'

The idea is that got patch can simply look for a line such as: commit - abcde1234567... to find the merge base commit ID to show in diff3 conflict markers. got log -p now displays commit IDs in its diff header, instead ofl tree or blob IDs. ok op@


1d56c8ea1e Thomas Adam

adjust expected test output after got log -s changes

ok op@


2f7ada2061 Thomas Adam

add one-line output mode to got log with -s flag

-s for short. Moves log search to -S. Patch by Evan Silberman


fc414659b4 Thomas Adam

use test(1) -eq and -ne to compare integers, and reduce quoting

This brings the rest of the regression test scripts in line with patch.sh.


a3599220a6 Thomas Adam

display the requested object type when an object could not be found

ok millert@


a966211500 Christian Weisgerber

add missing "return 1" to failure handling in the regress scripts

ok stsp@




603cdeb0c7 Stefan Sperling

make 'got log' avoid got_repo_map_path() if run in a work tree

ok naddy


f6cae3ed1e Christian Weisgerber

switch function declarations from Korn shell to Bourne/POSIX shell syntax

ok stsp


7fb414ae4d Stefan Sperling

add a -q option to tests for quiet output and use it for 'make regress'

Previous default output remains when test cases are run individually. ok tracey


502b9684f9 Stefan Sperling

make 'got log' -R and -P options work in combination

With -R, the -P option did not show any paths. Regression test added here demonstrates the problem.


e730362696 Stefan Sperling

add submodule tests

ok semarie


0208f20830 Stefan Sperling

show a list of paths changed in a commit with 'got log -P', and in tog

requested by matthieu@


2e8c69d19f Stefan Sperling

fix "no such entry found in tree" error with got log -p and an added path

ok millert@


50f2fadafa Stefan Sperling

fix 'got log -r' loading refs from the wrong repo if invoked in a work tree

ok tracey