Website Summary Files Commits Branches @commit @diff @stats
path: root / deploy.php
diff options
context:
space:
mode:
1 files changed, 17 insertions, 0 deletions
-rw-r--r--deploy.php17
diff --git a/deploy.php b/deploy.php
new file mode 100644
index 0000000..e4c2853
--- /dev/null
+++ b/deploy.php
@@ -0,0 +1,17 @@
+<?php
+
+/**
+ * Get the latest version of the master branch
+ */
+// echo shell_exec( 'git fetch origin master; ');
+// echo shell_exec( 'git checkout master; ');
+echo shell_exec( 'git pull origin master; ');
+echo shell_exec( 'wp cache flush ');
+
+// Load WordPress
+require_once( 'wp-load.php' );
+
+// Display a link to the homepage
+echo '<div>';
+echo 'You are ready to check the <a href="' . home_url( '/' ) . '">Homepage</a>';
+echo '</div>'; \ No newline at end of file