I putted the most code in general functions (in the scripts/helper-functions.sh file).

But some parts of the code look like a copy but are not completely the same (or can become different in the future).

I created a repo with a skeleton to start working the Gizra way: build every drupal site like a distribution. I will get the code from it back into this project when I finish it. 
See https://github.com/zero2one/drupal7-skeleton