diff --git a/makepackage b/makepackage
index 1e0df8638e17151285ce4204ea4ad0ba1d604ba8..8e7ce76aff2b175658af03ff2ce01d1991d5ea7b 100644
--- a/makepackage
+++ b/makepackage
@@ -46,31 +46,34 @@ REPOSITORY=$PWD/repos/$CODENAME
 HELPERS=$PWD/helpers
 if ! [ -d repos/ ]
 then
-mkdir -p repos/$CODENAME/conf repos/$CODENAME/incoming
-cat << EOF > repos/$CODENAME/conf/distributions
+for i in $(git branch|sed 's/.* //;/master/d')
+do
+mkdir -p repos/$REPO/conf repos/$REPO/incoming
+cat << EOF > repos/$REPO/conf/distributions
 Origin: Trisquel
 Label: Trisquel
-Suite: $CODENAME
+Suite: $REPO
 Version: 42
-Codename: $CODENAME
+Codename: $REPO
 Architectures: i386 amd64 source
 Components: main
 UDebComponents: main
 DebIndices: Packages Release . .gz .bz2
 UDebIndices: Packages . .gz .bz2
 DscIndices: Sources Release .gz .bz2
-Log: $CODENAME.log
+Log: $REPO.log
 Description: Trisquel GNU/Linux packages for the $UPSTREAM based release
 EOF
 
 if gpg -K | grep -q $GPGKEY
 then
-    echo "SignWith: $GPGKEY" >> repos/$CODENAME/conf/distributions
+    echo "SignWith: $GPGKEY" >> repos/$REPO/conf/distributions
 fi
 
-cd repos/$CODENAME
+cd repos/$REPO
 reprepro -v export
 cd ../..
+done
 fi
 
 disablescripts(){