summaryrefslogtreecommitdiff
path: root/script/update/project/trees
AgeCommit message (Collapse)Author
2023-10-02update/project/trees: fix error handling on mkdirLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-10-02update/project/trees: optimise error handlingLeah Rowe
some x_ calls are made that aren't needed. this is now corrected. additionally, some x_ calls were being made that are quite error-prone, like ones that use $PWD. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-10-02update/project/trees: simplified error handlingLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-10-02update/project/trees: general code cleanupLeah Rowe
reduced sloccount, without reducing functionality Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-10-02update/project/trees: rm yet another rm lineLeah Rowe
good lord, redundancy is indeed redundant. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-10-02update/project/trees: remove one more rm lineLeah Rowe
the one at the end of main is unnecessary, because it's handled inside the for loop. this file isn't used anywhere else, so it's OK. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-10-02update/project/trees: remove redundant rm commandLeah Rowe
as it turns out, i delete "seen" inside the for loop, which is a more thorough way to do it. thus, the first rm command is unnecessary. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-10-02update/project/trees: remove unnecessary linebreakLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-10-02update/project/trees: rm "seen" in the right placeLeah Rowe
it must be done *after* setting cfgsdir Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-10-01Greatly simplify error handling in shell scriptsLeah Rowe
Instead of having detailed error messages, run most commands through a function that calls err() under fault conditions. Where detail is still required, err() is still called manually. Where it isn't, the error message is simply whatever command was executed to cause the error. This results in a massive sloccount reduction for lbmk; specifically, 178 sloc reduction, or a 8.1% reduction. The total sloccount is now 2022, for shell scripts. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-30simplify initialising variables in shell scriptsLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-27move build/command/options to include/option.shLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-25only update git submodules in project/treesLeah Rowe
do not update them in project/repos - despite what the previous commit message says, this behaviour is error prone and should be avoided. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-25update/project/*: unified git reset handlingLeah Rowe
With this change, lbmk now also updates submodules on simple git clones, not just multi-tree clones. This is OK, because git does not return non-zero status when git submodule update is ran, where git submodules are not actually defined. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-25update/project/*: unified patch handlingLeah Rowe
Handle patches by a function at include/git.sh Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-25update/project/trees: remove extra.sh handlingLeah Rowe
This functionality has never been used, except in the erstwhile osboot project, and even then only experimentally. It was intended for use with coreboot's gerrit site, but it became Libreboot project policy that this not be relied upon, instead preferring to include patches directly within lbmk. This functionality can be re-added, if necessary. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-25Update email address for Leah Rowe copyrightsLeah Rowe
also, some of them were out of date; years now updated. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-25Use SPDX license headers on all scriptsLeah Rowe
This results in much cleaner copyright and license declarations. SPDX headers are legally recognised and make auditing easier. Also, remove descriptions of each script, from each script. Libreboot documentation at docs/maintain/ describes them. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-09update/project/*: remove redundant checksLeah Rowe
these scripts used to be in the main directory of lbmk, and thus needed to check for root user, and also git credentials. now they are called by the main lbmk script, which also runs the same checks. avoid waste of resources by not running the same check twice. Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-04merge config/ and resources/Leah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-01update the fetch scripts themselvesLeah Rowe
the fetch scripts call themselves, for dependencies Signed-off-by: Leah Rowe <leah@libreboot.org>
2023-09-01handle project downloads in main lbmk scriptLeah Rowe
this means the unified /tmp handling is now provided for in both the former "fetch" and "fetch_trees" script, which are now (respectively): ./update project repo ./update project trees if the fetch scripts weren't cleaning /tmp before, they now are, because lbmk handles it Signed-off-by: Leah Rowe <leah@libreboot.org>