adds script and readme

master
nicolas 3 years ago
parent 658936ffb9
commit 7820005967

@ -0,0 +1,27 @@
Script to generate an X amount of commits every day since Y days ago
-------------------------------------------------------------------
Given X and Y > 0
Instruction manual
------------------
- mkdir mynew && cp commit_x_days_ago.sh $_ && cd $_
- git init
- echo "commit_x_days_ago.sh" >> .git/info/exclude
- ./commit_x_days_ago.sh Y X
- git push
Why would you do this?
----------------------
______________________________
/ You get along very well with \
| everyone except animals and |
\ people. /
------------------------------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||

@ -0,0 +1,17 @@
#!/bin/bash
counter=$1
mkdir temp_files && cd $_
while [ $counter -gt 0 ]
do
for commit_number in `seq $2`
do
filename="${counter}_day(s)_ago_${commit_number}.doc"
touch "${filename}"
echo "${counter}_day(s)_ago_${commit_number}" >> "${filename}"
git add .
git commit --date="$counter day/s ago $commit_number" -m "$counter day/s ago $commit_number"
done
counter=$(( $counter - 1 ))
done
Loading…
Cancel
Save