test: improve hermetic git repository setup in helpers
This commit is contained in:
parent
79f0ef9ac6
commit
e33f4653f1
1 changed files with 8 additions and 7 deletions
|
|
@ -88,16 +88,17 @@ EOF
|
|||
git init -q
|
||||
# Hermetic: ignore the user's global git config (signing, global hooks);
|
||||
# otherwise commit.gpgsign or a global core.hooksPath makes git commit fail here.
|
||||
git config commit.gpgsign false
|
||||
git config core.hooksPath "${base}/nohooks"
|
||||
git config user.email t@t
|
||||
git config user.name tester
|
||||
git add .
|
||||
git commit -qm init
|
||||
git config --local user.name "Framework Test"
|
||||
git config --local user.email "test@genome.local"
|
||||
git config --local commit.gpgsign false
|
||||
git config --local core.hooksPath "${base}/nohooks"
|
||||
|
||||
git branch -M main
|
||||
git remote add origin "${base}/origin.git"
|
||||
git add .
|
||||
git commit -q -m "chore: initial scaffold"
|
||||
git push -q -u origin main
|
||||
) >/dev/null
|
||||
)
|
||||
|
||||
echo "${g}"
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue