Compare commits

...

7 Commits

4 changed files with 15 additions and 6 deletions

View File

@@ -40,4 +40,7 @@
# AGENTS=(orion taurus)
# whether to include custom maintainer line when importing from arch
# PATCH_MAINTAINER=yes
# PATCH_MAINTAINER=false
# override the default git url for patches repo
# PATCH_URL=${GIT_SSH}:artix/artix-patches.git

View File

@@ -12,12 +12,12 @@ PATCHDIR=${PATCHDIR:-"${WORKSPACE_DIR}/artix-patches"}
update_patches(){
if [[ ! -d "${PATCHDIR}" ]]; then
# ${GIT_ORG}
if ! git clone "${GIT_SSH}:artix/artix-patches.git" "${PATCHDIR}"; then
>&2 echo 'failed to clone %s' "${PATCHDIR}"
if ! git clone "${PATCH_URL}" "${PATCHDIR}"; then
error "failed to clone %s" "${PATCHDIR}"
fi
else
if ! git -C "${PATCHDIR}" pull; then
>&2 echo "Failed to pull artix-patches"
error "Failed to pull artix-patches"
fi
fi
}
@@ -30,7 +30,7 @@ patch_pkgbase(){
-e 's|arch-meson|artix-meson|' \
-i PKGBUILD
if [ "${PATCH_MAINTAINER}" = "yes" ] && [ -n "${PACKAGER}" ]; then
if "${PATCH_MAINTAINER}" && [ -n "${PACKAGER}" ]; then
sed -e 's|# Maintainer:|# Contributor:|' -i PKGBUILD
printf '%s\n%s\n' "# Maintainer: ${PACKAGER}" "$(cat "PKGBUILD")" >"PKGBUILD"
fi

View File

@@ -60,6 +60,10 @@ load_pkg_config(){
DBEXT=${DBEXT:-'gz'}
PATCH_MAINTAINER=${PATCH_MAINTAINER:-false}
PATCH_URL=${PATCH_URL:-"${GIT_SSH}:artix/artix-patches.git"}
if [[ -z "${AGENTS[*]}" ]]; then
AGENTS=(orion taurus)
fi

View File

@@ -181,7 +181,9 @@ else
set_arch="${CARCH}"
fi
${CARCH:+setarch "${set_arch}"} chroot "${working_dir}" "$@"
chroot_args=(/usr/bin/env PATH=/usr/local/sbin:/usr/local/bin:/usr/bin)
${CARCH:+setarch "${set_arch}"} chroot "${working_dir}" "${chroot_args[@]}" "$@"
ret=$?