Skip to content
Snippets Groups Projects
Verified Commit e41c9461 authored by Jan Alexander Steffens (heftig)'s avatar Jan Alexander Steffens (heftig)
Browse files

fix(db-functions): Lock state repo before creating a file

Maybe this doesn't matter because the change isn't staged yet anyway,
but it makes me feel safer.
parent f757bcea
No related branches found
No related tags found
1 merge request!47fix(db-functions): Lock state repo before creating a file
Pipeline #84846 failed
......@@ -204,6 +204,8 @@ vcs_update_package() {
local gittag
gittag="$(gittag_from_pkgver "${pkgver}")"
lock 8 "${GIT_STATE_REPO}/.git/dbscripts.lock" "Locking state repo"
mkdir -p "${GIT_STATE_REPO}/${dest}"
printf '%s %s %s %s\n' \
"${pkgbase}" \
......@@ -212,8 +214,6 @@ vcs_update_package() {
"$(git -C "${GIT_PACKAGES_CACHE}/${pkgbase}" rev-parse "${gittag}")" \
> "${GIT_STATE_REPO}/${dest}/${pkgbase}"
lock 8 "${GIT_STATE_REPO}/.git/dbscripts.lock" "Locking state repo"
arch_git -C "${GIT_STATE_REPO}" add "${GIT_STATE_REPO}/${dest}/${pkgbase}"
vcs_commit "update ${pkgbase} to ${pkgver} in ${dest}"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment