From d64b8d3166440306193f1ed818a9e969f5de7387 Mon Sep 17 00:00:00 2001 From: Sverre Rabbelier Date: Mon, 26 May 2008 11:44:44 +0200 Subject: [PATCH] gitstats: Created a script to setup a repo to test metrics on. The script is very simple, it creates a new directory in which it creates a series of linear commits. Later when a more complex commit history is required the script may be adjusted to reflect this. --- src/scripts/setupRepo.sh | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100755 src/scripts/setupRepo.sh diff --git a/src/scripts/setupRepo.sh b/src/scripts/setupRepo.sh new file mode 100755 index 0000000..655c17d --- /dev/null +++ b/src/scripts/setupRepo.sh @@ -0,0 +1,31 @@ +#!/bin/bash + +repodir=repo$$ + +echo "Setting up repo in $repodir." + +# Set up the repo +mkdir $repodir +cd $repodir +git init + +git config user.email "sverre@rabbelier.nl" +git config user.name "Sverre Rabbelier" + +echo "Initial commit" >> content.txt +git add content.txt +git commit -m "Initial commit" + +# Create some commits +for ((i=2; i < 10;i++)) do + echo "Change $i." >> content.txt + git commit -a -m "Commit $i" +done + +# Create the last commit +echo "Last commit" >> content.txt +git commit -a -m "Last commit" + +# Done +echo "Done." + -- 2.11.4.GIT