Browse Source

Add simple script for the git commit hook

Aaron Mueller 7 years ago
parent
commit
507e5d920b
2 changed files with 9 additions and 0 deletions
  1. 1
    0
      .gitignore
  2. 8
    0
      update.php

+ 1
- 0
.gitignore View File

@@ -1 +1,2 @@
1 1
 public_html/
2
+update_token

+ 8
- 0
update.php View File

@@ -0,0 +1,8 @@
1
+<?php
2
+
3
+$token = trim(file_get_contents('update_token'));
4
+if (empty($_GET['token']) || $_GET['token'] !== $token) die();
5
+
6
+exec('git pull');
7
+exec('git submodule update');
8
+exec('scripts/generate_pages.rb');

Loading…
Cancel
Save