Skip to content

Commit 2338acc

Browse files
committed
Hopefully smoothing auto-documentation process
# Conflicts: # docs
1 parent cbefe8c commit 2338acc

2 files changed

Lines changed: 11 additions & 7 deletions

File tree

docs

Submodule docs updated from 9746de7 to f90b76b

makeDocs.php

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,13 @@
1010
}
1111

1212

13+
echo "Clearing git status...";
14+
echo exec("cd " . __DIR__ . "/docs && git reset --hard && git checkout master");
15+
echo " Complete.\n";
16+
17+
1318
echo "Running PHPDoc Analysis...";
14-
exec("php " . PHPDOC_PHAR_FILENAME . " run -d src -t docs/ --template=\"xml\"");
19+
exec("cd .. && php " . PHPDOC_PHAR_FILENAME . " run -d src -t docs/ --template=\"xml\"");
1520
echo " Complete\n";
1621

1722

@@ -37,13 +42,12 @@
3742
exit(0);
3843
}
3944

40-
41-
echo "Committing and pushing to Repository...";
42-
echo exec("cd " . __DIR__ . "/docs && git add *.md && git commit -m \"Auto-Updated Documentation\"");
43-
echo " Complete.\n";
44-
4545
// if --push is set, push the changes.
4646
if (in_array("--push", $argv)) {
47+
echo "Committing and pushing to Repository...";
48+
echo exec("cd " . __DIR__ . "/docs && git add *.md && git commit -m \"Auto-Updated Documentation\"");
49+
echo " Complete.\n";
50+
4751
echo "Pushing to remote repository...";
4852
echo exec("cd " . __DIR__ . "/docs && git push");
4953
echo " Complete.\n";

0 commit comments

Comments
 (0)