summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorSandro Jäckel <sandro.jaeckel@gmail.com>2023-11-02 03:16:52 +0100
committerJo-Philipp Wich <jo@mein.io>2023-11-02 12:40:44 +0100
commit376f1c80a967cf349e9d7d6168dd9bce3c35ebd8 (patch)
tree6f36f85e0be6bbdfe5fb47fb0e2594dcfa97738f /scripts
parent6f5f9a0218ab7da6a11b91ee6a5ccba0531de963 (diff)
downloadopenwrt-376f1c80a967cf349e9d7d6168dd9bce3c35ebd8.tar.gz
openwrt-376f1c80a967cf349e9d7d6168dd9bce3c35ebd8.tar.bz2
openwrt-376f1c80a967cf349e9d7d6168dd9bce3c35ebd8.zip
build: use long hashes when generating feed.buildinfo
Short hashes are not guaranteed to be unambiguous forever and could collide if the repo grows over time. Git also estimates how many characters are roughly required to prevent such a collision and slowly increases the amount of characters beginning from 6, OpenWrt is already at 8. Lets use the full hash the have a predictable length and keep hashes unambiguous forever. Signed-off-by: Sandro Jäckel <sandro.jaeckel@gmail.com>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/feeds6
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/feeds b/scripts/feeds
index aee73e793f..7d5b83e081 100755
--- a/scripts/feeds
+++ b/scripts/feeds
@@ -162,7 +162,7 @@ my %update_method = (
'update_force' => "git pull --ff-only || (git reset --hard HEAD; git pull --ff-only; exit 1)",
'post_update' => "git submodule update --init --recursive",
'controldir' => ".git",
- 'revision' => "git rev-parse --short HEAD | tr -d '\n'"},
+ 'revision' => "git rev-parse HEAD | tr -d '\n'"},
'src-git-full' => {
'init' => "git clone '%s' '%s'",
'init_branch' => "git clone --branch '%s' '%s' '%s'",
@@ -171,12 +171,12 @@ my %update_method = (
'update_force' => "git pull --ff-only || (git reset --hard HEAD; git pull --ff-only; exit 1)",
'post_update' => "git submodule update --init --recursive",
'controldir' => ".git",
- 'revision' => "git rev-parse --short HEAD | tr -d '\n'"},
+ 'revision' => "git rev-parse HEAD | tr -d '\n'"},
'src-gitsvn' => {
'init' => "git svn clone -r HEAD '%s' '%s'",
'update' => "git svn rebase",
'controldir' => ".git",
- 'revision' => "git rev-parse --short HEAD | tr -d '\n'"},
+ 'revision' => "git rev-parse HEAD | tr -d '\n'"},
'src-bzr' => {
'init' => "bzr checkout --lightweight '%s' '%s'",
'update' => "bzr update",