* [gentoo-dev] [PATCH subversion.eclass] Export working copy information after the update.
@ 2013-07-23 18:46 Michał Górny
2013-07-27 10:18 ` Michał Górny
0 siblings, 1 reply; 2+ messages in thread
From: Michał Górny @ 2013-07-23 18:46 UTC (permalink / raw
To: gentoo-dev; +Cc: hattya, Michał Górny
Currently, subversion.eclass exports working working copy information
such as ESVN_WC_REVISION two times: once before running 'svn up',
and the second time in pkg_preinst(). As a result, between those two
calls ESVN_WC_REVISION lists the *previous* working copy revision rather
than the current one.
This behavior is not exploited by any ebuild. Instead, all ebuilds that
use ESVN_WC_REVISION either hack it around, or actually use the wrong
revision mistakenly.
The patch fixes the eclass to export working copy information *after*
the update is done. Redundant call to subversion_wc_info is removed from
pkg_preinst() as no ebuild needs the re-export.
Fixes: https://bugs.gentoo.org/show_bug.cgi?id=282486
---
gx86/eclass/subversion.eclass | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/gx86/eclass/subversion.eclass b/gx86/eclass/subversion.eclass
index 43d7ce1..9c349bd 100644
--- a/gx86/eclass/subversion.eclass
+++ b/gx86/eclass/subversion.eclass
@@ -324,6 +324,9 @@ subversion_fetch() {
${ESVN_UPDATE_CMD} ${options} || die "${ESVN}: can't update ${wc_path} from ${repo_uri}."
fi
fi
+
+ # export updated information for the working copy
+ subversion_wc_info "${repo_uri}" || die "${ESVN}: unknown problem occurred while accessing working copy."
fi
fi
@@ -441,7 +444,6 @@ subversion_src_prepare() {
# config protection.
subversion_pkg_preinst() {
local pkgdate=$(date "+%Y%m%d %H:%M:%S")
- subversion_wc_info "${1}"
if [[ -n ${ESCM_LOGDIR} ]]; then
local dir="${ROOT}/${ESCM_LOGDIR}/${CATEGORY}"
if [[ ! -d ${dir} ]]; then
--
1.8.3.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [gentoo-dev] [PATCH subversion.eclass] Export working copy information after the update.
2013-07-23 18:46 [gentoo-dev] [PATCH subversion.eclass] Export working copy information after the update Michał Górny
@ 2013-07-27 10:18 ` Michał Górny
0 siblings, 0 replies; 2+ messages in thread
From: Michał Górny @ 2013-07-27 10:18 UTC (permalink / raw
To: gentoo-dev; +Cc: hattya
[-- Attachment #1: Type: text/plain, Size: 894 bytes --]
Dnia 2013-07-23, o godz. 20:46:15
Michał Górny <mgorny@gentoo.org> napisał(a):
> Currently, subversion.eclass exports working working copy information
> such as ESVN_WC_REVISION two times: once before running 'svn up',
> and the second time in pkg_preinst(). As a result, between those two
> calls ESVN_WC_REVISION lists the *previous* working copy revision rather
> than the current one.
>
> This behavior is not exploited by any ebuild. Instead, all ebuilds that
> use ESVN_WC_REVISION either hack it around, or actually use the wrong
> revision mistakenly.
>
> The patch fixes the eclass to export working copy information *after*
> the update is done. Redundant call to subversion_wc_info is removed from
> pkg_preinst() as no ebuild needs the re-export.
>
> Fixes: https://bugs.gentoo.org/show_bug.cgi?id=282486
Committed.
--
Best regards,
Michał Górny
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 966 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-07-27 10:18 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-23 18:46 [gentoo-dev] [PATCH subversion.eclass] Export working copy information after the update Michał Górny
2013-07-27 10:18 ` Michał Górny
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox