Skip to content

Instantly share code, notes, and snippets.

@cirosantilli
Created May 16, 2016 21:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cirosantilli/f7191680a2a6281bdc292c94cda188c4 to your computer and use it in GitHub Desktop.
Save cirosantilli/f7191680a2a6281bdc292c94cda188c4 to your computer and use it in GitHub Desktop.
test-commit-many-parents
#!/usr/bin/env bash
repo='repo'
email='a@a.com'
rm -rf "$repo"
mkdir -p "$repo"
cd "$repo"
n=1000
# Common ancestor required.
git init -q
git remote add origin git@github.com:cirosantilli/test-2.git
touch '0'
git add '0'
git commit -m '0' -q
for i in `seq $n`; do
git checkout -b "$i" -q master
touch '1'
git add '1'
git commit -m "$i" -q
echo "$i"
done
git checkout 'master'
git merge -m 'end' -s 'octopus' -q `seq $n`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment