aboutsummaryrefslogtreecommitdiffstats
path: root/tools/kgit-checkpoint
AgeCommit message (Collapse)Author
2019-08-08Add SPDX license headers to source filesWilliam Bourque
Kconfiglib/* were under ISC license before they were imported here from https://github.com/ulfalizer/Kconfiglib Adjusting SPDX header to reflect that fact. tools/* all have some sort of GPLv2 headers; adding SPDX header to make it obvious. This address bug #13334 : https://bugzilla.yoctoproject.org/show_bug.cgi?id=13334 Change-Id: I243f2dd266a398f982798b771e74a67be70ecb52 Signed-off-by: William Bourque <wbourque@gmail.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
2015-03-11tools: unify meta directory detectionBruce Ashfield
The various scripts in the kern-tools have grown slightly different meta directory detection routines over time. This means that we are not always consistent, and the checks are not as robust as possible. As part of this change, we have a single (which to avoid including a common kgit script and coupling the tools .. is repeated) routine for detecting the meta branch. This detection logs the result in a new file ".metadir", which subsequent scripts can find, and use, thereby avoid repeating the same check many times. We also enhance the check to look for a sentinel file in a proper meta directory, to avoid false positives when an unexpected kernel process leaves an uncommitted directory in the kernel dir. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2015-03-04checkpoint: detect meta directory on restoreBruce Ashfield
We are allowed to restore a checkpoint multiple times, but detecting if a checkpoint has already been restored depends on the proper meta directory being checked. In much the same way as other scripts, we should query the filesystem for the right directory versus using a hardcoded default. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2014-08-29tools: allow meta directories that are not the same as the branch nameBruce Ashfield
With this change it is now possible to have a meta branch with meta data in a directory that is not the same name as the branch. The changes to three parts of the build are required to discover the name of the meta directory by relying on the fact that in a clean/proper build the meta directory is the only untracked, top level directory in the build. As such, we can restore a checkpoint and then examine the build directory to determine the meta directory name .. avoiding any new variables to indicate this to the scripts and build system. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2014-07-09kgit-checkpoint: ensure that full meta-data artifacts are maintainedBruce Ashfield
If a repository is generated with full meta data history, there are extra artifcacts present due to the import and filtering of the data. By moving directory names earlier, and forcing checkouts, we can ensure that the checkpoint create and restore operations always work properly. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2013-09-30kgit-checkpoint: expand commit logs around 00-README filesPaul Gortmaker
If there was a 00-README, it was used as-is for a commit log, which might lead to confusing commit logs w/o a short log, etc. Add a header/shortlog, an indication of the file path, and delimiters around the included 00-README file. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
2013-09-30kgit-checkpoint: delete .gitignore and .mailmap on orphan branchPaul Gortmaker
There was a separate block of code for deleting .gitignore since it wasn't swept up in the output of "ls" in the above block. However this was failing to remove anything, and was only noticed when adding additional error checking, i.e: Switched to a new branch 'meta-ovp' fatal: pathspec 'meta-ovp/.gitignore' did not match any files This happens because .gitignore isn't in the index of the orphan. We can just delete the git version of the removal block and add it to the output of ls (along with .mailmap -- we don't want that on the meta branch either.) Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
2013-09-30kgit-checkpoint: add error checking to all git opsPaul Gortmaker
Having it blindly continue when things clearly have gone wrong doesn't make any sense. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
2013-09-30kgit-checkpoint: fix alternate meta directory checkpointsBruce Ashfield
Handling of initial checkpoints with non-standard "meta" directories was broken, since the branch doesn't exist, the directory name was reset to "meta" even if an alternate name was passed. Checking for the branch to exist before querying it fixes the issue. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2013-08-20kern-tools: use .meta as meta data containerBruce Ashfield
Previously the meta directory was added to all .gitignore files, otherwise all users of the kernel would see an untracked directory "meta". This caused workflow issues, since the same .gitignore was shared on the meta branch itself. Which meant that changes were not shown and files needed to be added with the -f flag. To fix this, we teach the tools to look for .$META as the meta data container, and place the meta branches directory under that same name. The result is that the .meta directory is ignored by git automatically, but is available to all branches. And switching to the meta branch no longer warns of clobbered files, and once you arrive, files are tracked and manipulated normally. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2013-06-05kgit-checkpoint: clear .gitignore for meta branchBruce Ashfield
The meta branch should not inherit the .gitignore from the main repository. If we do, we can't see important details like changes to the meta-data. Removing it completely fixes the problem. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2012-07-19kgit-checkpoint: fix verify_branch variable name typoBruce Ashfield
Fixing a long standing typo in a test for the verify_branch, which was "verify_branch" vs "$verify_branch". Clearly not a much exercised code path, since always false test hasn't worked for two years. Reported-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2012-05-10kern-tools: remove meta tag and directory assumptionsBruce Ashfield
During repository sanity checks (createme) and during the checkpoint process, there were several assumptions about the tree that either relied on a tag, or a particular directory name. With this set of changes, simply passing the meta branch name is enough to sanitize and restore the checkpoint. If no meta branch name is passed, the default of 'meta' is used for both the branch and meta data directory name. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2012-04-17checkpoint: allow orphan branches and drop unused functionalityBruce Ashfield
The ability to 'join' checkpoints is not used, and overly complicates the checkpoint processing, so it can be removed. Secondarily the checkpoint creation and restore is changed to handle branches that do not share a common base with the rest of the repository. With this change orphan branches or common branches can be used to store meta data. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2011-06-21tools: remove confusing meta subdirBruce Ashfield
The 'meta' branch can have many names, but when it is called 'meta' the subdirectory meta/cfg/meta/, simply looks like a mistake. This is renamed to meta/cfg/scratch/ to indicate its actual use .. a scratch location for building the meta series. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2010-12-06yocto: update tools to adapt to 0.9 or 1.0 kernel treesBruce Ashfield
Allow the tools to detect and adapt to the different format trees. Once 0.9 support has been removed, these commits can be reverted. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2010-12-04kgit-checkpoint: query branches for checkpoint directoriesBruce Ashfield
The test for the type of checkpoint meta directory was filesystem based. But this check won't work before you uncheckpoint a tree (since the directory won't be in the working tree of all branches). To fix this, we check the checkpoint branch itself to see what the meta directory is called. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2010-12-02yocto: generalize branch names and configurationBruce Ashfield
The existing branch and meta data storage was tightly coupled to the existing naming scheme. In order to support a more transparent branch hierarchy, changes are required to the scripts that manage the tree. Note: These changes are not backwards compatible with old trees. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2010-07-16kern_tools: instatiate minimum set of kernel toolsbruce
Create the smallest set of kernel tools required to checkout, build and manipulate Wind River Linux kernel. Details of the usage are in the indivdual scripts, but generally speaking these are never excuted directly by the end user Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>