diff --git a/_config/config.yml b/_config/config.yml
index e2bb3b2..000924a 100644
--- a/_config/config.yml
+++ b/_config/config.yml
@@ -7,4 +7,7 @@ LeftAndMain:
- 'betternavigator/javascript/BN.LeftAndMain.Preview.js'
ContentController:
extensions:
- - BetterNavigator
\ No newline at end of file
+ - BetterNavigator
+DevelopmentAdmin:
+ extensions:
+ - FlushOnDevBuild
\ No newline at end of file
diff --git a/code/FlushOnDevBuild.php b/code/FlushOnDevBuild.php
new file mode 100755
index 0000000..6bdd44a
--- /dev/null
+++ b/code/FlushOnDevBuild.php
@@ -0,0 +1,14 @@
+owner->response->isFinished() && $action=='build' && $request->getVar('flush')){
+ SS_TemplateLoader::instance()->getManifest()->regenerate(true);
+ SSViewer::flush_template_cache();
+ }
+ }
+}
\ No newline at end of file
diff --git a/templates/BetterNavigator.ss b/templates/BetterNavigator.ss
index 721d791..29cf294 100644
--- a/templates/BetterNavigator.ss
+++ b/templates/BetterNavigator.ss
@@ -53,8 +53,8 @@
Dev Mode
<% end_if %>
- Flush Templates
- Build Database
+ Flush
+ Build & Flush
Dev Menu