Utilisation du nom de paquet si le nom de projet diffère avec celui ci

This commit is contained in:
wpetit 2017-03-21 15:52:49 +01:00
parent 0028db764a
commit 222b6c8940

View File

@ -0,0 +1,16 @@
#!/usr/bin/env bash
source "${TAMARIN_UTIL}"
if [ ! -f debian/control ]; then
fatal "No debian/control file found !"
fi
package_name=$(grep -E '^Package:' debian/control | awk '{ print $2 }')
project_name=$(get_opt project_name)
if [ "${package_name}" != "${project_name}" ]; then
warn "The project's name '${project_name}' differs from the package one ('${package_name}'). Using package's one..."
set_opt project_name "${package_name}"
exit
fi