Skip to content

Instantly share code, notes, and snippets.

@pechitook
Created November 19, 2016 20:40
Show Gist options
  • Save pechitook/3674ff2d18afe39132e8916e8dec6373 to your computer and use it in GitHub Desktop.
Save pechitook/3674ff2d18afe39132e8916e8dec6373 to your computer and use it in GitHub Desktop.
Push to deploy en hosting compartido con PHP

Crear archivo /pull.php

<?php

shell_exec('./pull.sh 2>&1');
echo "Done.";

crear otro archivo /pull.sh

git pull origin master

Agregarlo al gitignore y crear el hook de push que le pegue a midominio.com/pull.php 💩

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment