kumquat-buildroot/support/scripts
Thomas De Schampheleire 44084aa981 support/scripts/setlocalversion: ignore user settings for Mercurial
setlocalversion will use 'hg id' to determine whether or not the current
revision is tagged. If there is no tag, the Mercurial revision is printed,
otherwise nothing is printed.

The problem is that the user may have custom configuration settings (in
their ~/.hgrc file or similar) that changes the output of 'hg id' in a way
that the script does not expect. In such cases, the Mercurial revision may
not be printed or printed incorrectly.

It is good practice to ignore the user environment when calling Mercurial
commands from a well-defined script, by setting the environment variable
HGRCPATH to the empty string. See also 'hg help environment'.

In the particular case of Nokia, a custom extension adds dynamic tags in the
repository, i.e. tags that are stored in a file external to the repository
and only visible when the extension is active. These tags should not
influence the behavior of setlocalversion as they are not official Buildroot
tags, i.e. even if a revision is tagged, the Mercurial revision should still
be printed.

Note that this still does not solve the problem where an organization adds
_real_ tags in their Buildroot repository. For example, there might be a
moving tag 'last-validated' or tags indicating in which product release that
Buildroot revision was used. In these cases, setlocalversion will still not
behave as expected, i.e. show the Mercurial revision.

Signed-off-by: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-02-04 21:25:33 +01:00
..
apply-patches.sh
br2-external
brpkgutil.py
check-bin-arch boot/grub2: add option to install tools 2018-11-26 20:59:33 +01:00
check-host-rpath support/scripts/check-host-rpath: document existing functions 2019-01-17 22:38:34 +01:00
check-kernel-headers.sh
check-uniq-files
eclipse-register-toolchain
expunge-gconv-modules
fix-configure-powerpc64.sh
fix-rpath
generate-gitlab-ci-yml Makefile: offload .gitlab-ci.yml generation 2018-12-09 21:30:24 +01:00
genimage.sh
graph-build-time support/scripts/graph-build-time: replace confusing colors 2019-02-04 15:23:27 +01:00
graph-depends support/scripts/graph-depends: introduce MANDATORY_DEPS array 2018-12-06 22:17:07 +01:00
hardlink-or-copy
mkmakefile support/scripts/mkmakefile: make wrapper silent by default 2018-11-02 21:23:02 +01:00
mkusers
pkg-stats support/scripts/pkg-stats: URL check using threads 2018-10-09 10:11:47 +02:00
pycompile.py
setlocalversion support/scripts/setlocalversion: ignore user settings for Mercurial 2019-02-04 21:25:33 +01:00
size-stats