summaryrefslogtreecommitdiff
path: root/include/release.sh
AgeCommit message (Collapse)Author
10 daysrelease.sh: use cache src on release buildsLeah Rowe
use what's in cache/clone/ from the main directory this speeds up the build process Signed-off-by: Leah Rowe <leah@libreboot.org>
10 daysmake notices a bit more readableLeah Rowe
add line breaks, so that the license and author are visually separated. this makes it easier to read. Signed-off-by: Leah Rowe <leah@libreboot.org>
10 daysrelease.sh: fix typo in script: ./mk, not ./mxLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
10 daysxbmk: cleanup of recent code refactoringLeah Rowe
be a bit less pedantic about if else clauses. leave the big ones still with then on separate lines, where else is specified. also unroll a few condensed code lines where i missed a few. sloccount 2303 in lbmk. that's still only slightly bigger than libreboot 20260907 which was 2180, and still much smaller than libreboot 20230625 which was 3322. this is *without* the condensed codelines, so now the only thing that's reduced is the overall amount of logic present in the build system. and i should clarify that lbmk is presently much more powerful than both of those two versions (20160907/20230625). the 2016 one is useful for comparison historically, since that was the last major version of libreboot prior to the great second coming of leah in 2021; and the 2023 june release was basically the last one before the great audits of 2023 to 2025 began. not to brag (not much anyway), but all of this means that lbmk is an insanely efficient build system, considering all the features it has and what it does. i unrolled the condensed code style in lbmk, making the scripts a lot easier to read, because i received complainst about the condensed style previously used; nicholas chin and alper nebi yasak both told me that it sucked, and riku viitanen had hinted at that same fact several months prior. so hopefully now, lbmk is a bit nicer. those and other people often find it challenging to challenge me because for reason they assume i'll get upset and fly off the handle, but it's the opposite. i want constant criticism, so that i know to improve! Signed-off-by: Leah Rowe <leah@libreboot.org>
11 daysrelease.sh: unroll condensed code linesLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-09-18Revert "xbmk: don't use backticks for command substitution"Leah Rowe
This reverts commit 4999a49de39667b3239fc2010d0e99c958b29417.
2025-09-13xbmk: much more verbose error messagesLeah Rowe
use the new functionality in err(), whereby a given function name and arguments can be provided, for debugging purposes. something similar was already done in a few places, and replaced with this unified functionality. this patch will make xbmk much easier to debug, under fault conditions. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-09-11xbmk: don't use backticks for command substitutionLeah Rowe
the newer way handles escaped characters better, and it can be nested more easily. it's also more readable. personally, i prefer the old way, because it's more minimalist, but it occurs to me that a lot of people nowadays don't know about backticks, but they do know of the modern way. to make the code more readable, i have modernised it. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-09-07release.sh: delete xbmkwd on src tarballsLeah Rowe
the previously deleted tmp/ directory was a relic from prior to recent tmpdir changes. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-09-07release.sh: put vdir in xmtmp, not XBMK_CACHELeah Rowe
XBMK_CACHE is meant for permanent cached files, not temporarily files. the temporary release files are copied upon successful return, to their rightful place under release/ this new change also reduces the chance of race conditions, if multiple xbmk instances are used; while not yet supported as a use-case, this is a goal for a future design change. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-09-02init.sh: create separate lock in release dirsLeah Rowe
this removes the current hackiness, preventing build errors since xbtmp is now based on xbmkpwd, which changes when we're in the release dir. XBMK_RELEASE is still set accordingly, so this will still work the same way. this is also cleaner in general. XBMK_CACHE is still the same, so the release work directory still re-uses files from the main work directory, rather than re-creating them. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-09-02release.sh: remove support for the -d flagLeah Rowe
this lets you change the directory for outputted release files, versus the default "release" directory. this code is buggy, because it could let you overwrite a part of xbmk or worse - and checking for such bad usage would require a lot more code. knobs are for nobs. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-09-01release.sh: fix broken release lock file handlingLeah Rowe
we need to copy the main lock file, rather than creating a new, empty one. this is because the new lock file handling requires it, and the release lock file will be used during release builds. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-26release.sh: use printf to create version filesLeah Rowe
Don't copy the files directly, because we might be doing this from a work directory that has no files; in this case, generic "unknown" variables are used, without generating any files, so the current logic would produce an error. However, we do need to create those dot files, because we then rely on them for building release binaries. The new logic maintains current behaviour, while fixing this technical edge-case scenario via mitigation. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-26xbmk: rename xbmklocal/xbmktmp variablesLeah Rowe
shorten them Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-22release.sh: copy version files to rsrcLeah Rowe
Otherwise, an "unknown" version number is created. This regression was caused by the recent optimisation that reduces the amount of extra work done by init.sh on child instances of xbmk. As a result of those changes, now release.sh has to do some minor initialisation of its own, such as this. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-18release.sh: rename relsrc to rsrcLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-18release.sh: tidy up nuke()Leah Rowe
i wasn't ok having that variable initialisation and then the commands on the same line. it looks messy. having the commands on a separate line makes the code nice to read, so let's separate them. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-17release.sh: simplify nuke() EVEN MORE, yet againLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-17release.sh: use x_ on find command for nuke()Leah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-17release.sh: simplify nuke() EVEN MORELeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-17get.sh: move nuke() to release.shLeah Rowe
we really only need it there, because the context is for release archives. normal use of the git repository doesn't matter in the context of deletions, because that will not be distributed. only the result of ./mk release will be distributed. the builds produced will not change as a result of this, for people using the normal git repository, because the files in question are never used anyway, in our configs. this is being done to make working on local repos easier. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-17release.sh: simplify prep_release_bin()Leah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-17release.sh: don't move src/docs/Leah Rowe
otherwise, ./mk -b (without argument) will fail, on release archives. also, perhaps i should add an mkhelper to build it? Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-13release.sh: Don't run prep_release with fx_Leah Rowe
The result of the printf statement is sorted, making it do binaries first, which results in a lot of junk files then being present inside the source archive. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-12release.sh: simplify release()Leah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-12release.sh: clean up the vdir after releaseLeah Rowe
do this after moving the version directory within it. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-12release.sh: remove src_dirname variableLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-12release.sh: build in tmp directory firstLeah Rowe
don't move to the real directory until the work is done. that way, a re-try can be done, while analysing the old files. it is created based on the tmpdir, under XBMK_CACHE/ Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-12release.sh: remove unnecessary mkdir commandLeah Rowe
the following git clone command creates that directory Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-12release.sh: split up build_release()Leah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-12release.sh: delete tmp/cache from the tarballLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-12lib.sh: remove rmgit()Leah Rowe
We don't need to call it from git.sh, because it's only being done when building a release anyway, and we already run rmgit when doing a release. The function itself is only two simple fx_ calls, so we can just do that from build_release(). Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-12lib.sh: remove mk()Leah Rowe
i don't need it. i can use fx_ instead, on functions that previously called mk(). Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-09lbmk: use x_ instead of err, where appropriateLeah Rowe
many places in lbmk used err, because older versions of x_ did not handle globbing properly. however, use of x_ is preferable on trivial commands. the only time err() should be called is what it has to be, when x_ can't work, or when a more useful error message is needed, for context. Signed-off-by: Leah Rowe <leah@libreboot.org>
2025-05-08mk: move release functions to idnclude/release.shLeah Rowe
The idea with mk is that it's meant to basically be a stub for running everything else, while mainly having the trees logic within it (what was once script/trees). Signed-off-by: Leah Rowe <leah@libreboot.org>