Website Summary Files Commits Branches @commit @diff @stats
path: root / deploy.php
blob: 9035b6362c4815b391f0c84fd7b3bafc7fc330d5 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
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>';