diff --git a/README.md b/README.md
index 53fdbb50e40f207e71cf0d2005b791cf453cd4c6..519dbab494b1ba2eec3927a6b385372243b2a4f7 100644
--- a/README.md
+++ b/README.md
@@ -15,9 +15,9 @@ docker build -t your-name/pikaur .
 
 2. Put this directory to your server. Assume you're placing this directory to `/srv/my-mirror-site`
 
-3. Create a directory `mirrors/output` (you can name it as anything you want), and modify the `build_outdir` variable in aur-sync.sh. Also change the `recolic-aur` after the `repo-add` command, to your repo name. 
+3. Modify the `build_outdir` and `repo_name` variable in aur-sync.sh. 
 
-You should know how to publish the directory to your web server. 
+You should know how to publish the output directory with your web server. 
 
 4. Add a crontab line and enjoy! 
 
diff --git a/aur-sync.sh b/aur-sync.sh
index 72035a7ee3741b963df5837b1d2c1091a10c4321..218d856feac7f9ff59814c42ca952ebf788f90db 100755
--- a/aur-sync.sh
+++ b/aur-sync.sh
@@ -21,7 +21,8 @@ repo_upstreams=(
 aur_upstreams='pikaur frpc frps azure-cli unzip-iconv create_ap snakesocks teamviewer remarkable goland clion gnome-terminal-transparency'
 # intellij-idea-ce rider graftcp # gractcp failure
 
-build_outdir="mirrors/recolic-aur"
+build_outdir="mirrors/aur"
+repo_name=recolic-aur
 
 function sync_aur () {
     echo "Running aur autobuild..."
@@ -71,11 +72,11 @@ function dedup_and_build_index () {
     cd -
 
     # build index.db
-    sudo docker run -i --rm -v "$(pwd)/$build_outdir":/home/builder/.cache/pikaur/pkg recolic/pikaur      bash -c "chown builder -R /home/builder/.cache/pikaur/pkg && cd /home/builder/.cache/pikaur/pkg && repo-add recolic-aur.db.tar.gz *.pkg.tar.*"
+    sudo docker run -i --rm -v "$(pwd)/$build_outdir":/home/builder/.cache/pikaur/pkg recolic/pikaur      bash -c "chown builder -R /home/builder/.cache/pikaur/pkg && cd /home/builder/.cache/pikaur/pkg && repo-add $repo_name.db.tar.gz *.pkg.tar.*"
     return $?
 }
 
-
+mkdir -p "$build_outdir"
 sync_aur || echo AUR-gg
 sync_repo || echo REPO-gg
 sync_http || echo HTTP-gg