commit | f676e16b148429354c46260eb0eaa68c80dda667 | [log] [tgz] |
---|---|---|
author | Theodore Ts'o <tytso@mit.edu> | Wed Jul 24 16:32:06 2024 -0400 |
committer | Theodore Ts'o <tytso@mit.edu> | Wed Jul 24 22:13:01 2024 -0400 |
tree | 6ababb791fb5b402e0e61e8000ddf9ff19050096 | |
parent | bedcbcda3a710e2e894bfe88ef9fe20272a03f4d [diff] |
test-appliance: kcs: resolve git branch name more reliably If the user specifies a branch name to KCS, e.g., via "--repo origin" we need to make sure that git repository is updated before trying to resolve the branch name, since the reference in the locally cached repository might be out of date. On the other hand, the commit reference is a SHA hash id, we'd rather not do a full git fetch if the commit is already in the repository. So the strategy we use is to try to resolve the commit first if it is all hex digits and at least 7 characters long. If that fails, then do a git fetch, and then first try to resolve the commit prefixed with "origin/", to see if it is branch name in the origin git tree. If that fails, then try resolving the bare commit name; this should work if the commit revision specifier is either a tag or SHA hash id. Also use the --prune (-p) and --force (-f) options so if the upstream git branches are rewound or deleted, the local repository accurately reflects the state of the upstream / remote repository. Signed-off-by: Theodore Ts'o <tytso@mit.edu>
The xfstests-bld project was originally designed as system to make it easy to build xfstests in way that isolated it from the versions of various libraries such as libaio, xfsprogs, that were available in a particular distribution. It has since evolved to have four primary functions:
More details about how to use xfstests-bld to carry out these three functions can be found in the Documentation directory.
If you are first getting started using xfstests, you should probably read the Quickstart guide first. If you don't know much about xfstests, you may also want to read this introduction to xfstests.
The xfstests-bld project has been made available under the terms of the GNU General Public License, version 2. A copy can be found in the file named COPYING in the distribution.