diff --git a/Library/Contributions/brew_bash_completion.sh b/Library/Contributions/brew_bash_completion.sh
index 43511654025c859794a6a75f4660bc33cac736a8..089872a1560b178f3faa3aa7a55f0c9065ce1417 100644
--- a/Library/Contributions/brew_bash_completion.sh
+++ b/Library/Contributions/brew_bash_completion.sh
@@ -375,9 +375,9 @@ _brew ()
     done
 
     if [[ $i -eq $COMP_CWORD ]]; then
-        local ext=$(\ls $(brew --repository)/Library/Contributions/cmds \
+        local ext=$(\ls -p $(brew --repository)/Library/Contributions/cmds \
                 2>/dev/null | sed -e "s/\.rb//g" -e "s/brew-//g" \
-                -e "s/.*\.css.*//g" -e "s/.*\.erb.*//g")
+                -e "s/.*\///g")
         __brewcomp "
             --cache --cellar --config
             --env --prefix --repository
diff --git a/Library/Contributions/cmds/brew-test-bot.rb b/Library/Contributions/cmds/brew-test-bot.rb
index f927333f8d575e64873a15cd6f9cc0476aa7e922..dab91805a9a2410d450eea4a5dc1956dad82967f 100755
--- a/Library/Contributions/cmds/brew-test-bot.rb
+++ b/Library/Contributions/cmds/brew-test-bot.rb
@@ -108,7 +108,7 @@ class Test
 
     if ARGV.include? "--html" and not @@css
       require 'erb'
-      root = HOMEBREW_CONTRIBUTED_CMDS
+      root = HOMEBREW_CONTRIBUTED_CMDS/"brew-test-bot"
       @@css = IO.read root + "brew-test-bot.css"
       @@index_html = ERB.new IO.read root + "brew-test-bot.index.html.erb"
       @@commit_html = ERB.new IO.read root + "brew-test-bot.commit.html.erb"
diff --git a/Library/Contributions/cmds/brew-test-bot.commit.html.erb b/Library/Contributions/cmds/brew-test-bot/brew-test-bot.commit.html.erb
similarity index 100%
rename from Library/Contributions/cmds/brew-test-bot.commit.html.erb
rename to Library/Contributions/cmds/brew-test-bot/brew-test-bot.commit.html.erb
diff --git a/Library/Contributions/cmds/brew-test-bot.css b/Library/Contributions/cmds/brew-test-bot/brew-test-bot.css
similarity index 100%
rename from Library/Contributions/cmds/brew-test-bot.css
rename to Library/Contributions/cmds/brew-test-bot/brew-test-bot.css
diff --git a/Library/Contributions/cmds/brew-test-bot.index.html.erb b/Library/Contributions/cmds/brew-test-bot/brew-test-bot.index.html.erb
similarity index 100%
rename from Library/Contributions/cmds/brew-test-bot.index.html.erb
rename to Library/Contributions/cmds/brew-test-bot/brew-test-bot.index.html.erb