Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 29 additions & 6 deletions drawClass.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,35 @@

foreach ($assignedDates as $item) {
for ($i = 0; $i < COLOR_DEPTH; ++$i) {
file_put_contents(FILENAME, "$item$i");
shell_exec("git add .");
shell_exec("git commit -m $item$i");
shell_exec("git commit --amend --no-edit --date $item$i");
if (file_put_contents(FILENAME, "$item$i") === false) {
echo "Error writing to file: " . FILENAME . "\n";
exit(1);
}
$output = shell_exec("git add .");
if ($output === null) {
echo "Error executing command: git add .\n";
exit(1);
}
$output = shell_exec("git commit -m $item$i");
if ($output === null) {
echo "Error executing command: git commit -m $item$i\n";
exit(1);
}
$output = shell_exec("git commit --amend --no-edit --date $item$i");
if ($output === null) {
echo "Error executing command: git commit --amend --no-edit --date $item$i\n";
exit(1);
}
}
}

shell_exec("git pull --rebase");
shell_exec("git push origin master");
$output = shell_exec("git pull --rebase");
if ($output === null) {
echo "Error executing command: git pull --rebase\n";
exit(1);
}
$output = shell_exec("git push origin master");
if ($output === null) {
echo "Error executing command: git push origin master\n";
exit(1);
}