Skip to content

Commit

Permalink
guix: Expose GIT_COMMON_DIR in container as readonly
Browse files Browse the repository at this point in the history
When using worktrees or submodules, you'll see a `.git' plain text file
at the root of your working tree instead of the usual `.git' directory.

This plain text file will point to the real GIT_DIR, under the
GIT_COMMON_DIR. From experimentation, the full GIT_COMMON_DIR is
required to exist for operations such as git-archive(1), so we expose it
as readonly inside the container.
  • Loading branch information
dongcarl committed Apr 28, 2020
1 parent f5a6ac4 commit 1470160
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions contrib/guix/guix-build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ for host in ${HOSTS=x86_64-linux-gnu arm-linux-gnueabihf aarch64-linux-gnu riscv
--pure \
--no-cwd \
--share="$PWD"=/bitcoin \
--expose="$(git rev-parse --git-common-dir)" \
${SOURCES_PATH:+--share="$SOURCES_PATH"} \
${ADDITIONAL_GUIX_ENVIRONMENT_FLAGS} \
-- env HOST="$host" \
Expand Down

0 comments on commit 1470160

Please sign in to comment.