diff --git a/tools/build-linux/appimage/run_in_docker.sh b/tools/build-linux/appimage/run_in_docker.sh index d841403..8733244 100755 --- a/tools/build-linux/appimage/run_in_docker.sh +++ b/tools/build-linux/appimage/run_in_docker.sh @@ -26,6 +26,7 @@ PY_VER_MAJOR="3.10" # as it appears in fs paths PKG2APPIMAGE_COMMIT="a9c85b7e61a3a883f4a35c41c5decb5af88b6b5d" VERSION=$(git describe --tags --dirty --always) +list_dirty_files APPIMAGE="$DISTDIR/bitcoin_safe-$VERSION-x86_64.AppImage" rm -rf "$BUILDDIR" diff --git a/tools/build-mac/make_osx.sh b/tools/build-mac/make_osx.sh index 1ece3f7..15cec06 100755 --- a/tools/build-mac/make_osx.sh +++ b/tools/build-mac/make_osx.sh @@ -106,7 +106,7 @@ brew install autoconf automake libtool gettext coreutils pkgconfig # ====================== info "Using Poetry to install local project dependencies" # Optionally ensure Poetry does not create its own .venv: -poetry config virtualenvs.create false --local +poetry config virtualenvs.create false # ...But we are already inside a venv, so Poetry *should* install into this environment: poetry install --with main,build_mac @@ -218,6 +218,7 @@ info "Faking timestamps..." find . -exec sudo touch -t '200101220000' {} + || true VERSION=$(git describe --tags --dirty --always) +list_dirty_files info "Running PyInstaller to create macOS .app" BITCOIN_SAFE_VERSION=$VERSION \ diff --git a/tools/build-mac/sign_osx.sh b/tools/build-mac/sign_osx.sh index f1324fa..66e8141 100755 --- a/tools/build-mac/sign_osx.sh +++ b/tools/build-mac/sign_osx.sh @@ -60,6 +60,7 @@ function DoCodeSignMaybe { # ARGS: infoName fileOrDirName } VERSION=$(git describe --tags --dirty --always) +list_dirty_files DoCodeSignMaybe "app bundle" "dist/${PACKAGE}.app" diff --git a/tools/build-wine/build_exe.sh b/tools/build-wine/build_exe.sh index dc09656..4c26302 100755 --- a/tools/build-wine/build_exe.sh +++ b/tools/build-wine/build_exe.sh @@ -13,6 +13,7 @@ set -e pushd "$WINEPREFIX/drive_c/$NAME_ROOT" VERSION=$(git describe --tags --dirty --always) +list_dirty_files info "Last commit: $VERSION" find -exec touch -h -d '2000-11-11T11:11:11+00:00' {} + diff --git a/tools/build_tools_util.sh b/tools/build_tools_util.sh index efd189c..8f6c1bf 100755 --- a/tools/build_tools_util.sh +++ b/tools/build_tools_util.sh @@ -258,3 +258,21 @@ move_and_overwrite() { return 1 } } + + + +list_dirty_files() { + # Retrieve the current git version including tags and state + local temp_version=$(git describe --tags --dirty --always) + + # Check if the string 'dirty' is in the version + if [[ "$temp_version" == *dirty* ]]; then + warn "Repository is dirty. Listing modified files:" + # List files that are modified but not yet staged for commit + git diff --name-only + # List files that are staged but not yet committed + git diff --name-only --cached + else + info "Repository is clean version: $temp_version" + fi +}