-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathview.status.php
More file actions
27 lines (25 loc) · 1.03 KB
/
view.status.php
File metadata and controls
27 lines (25 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<h1>Status</h1>
<pre><?php echo $out?></pre>
<?php if (!stristr($out,'nothing to commit')) { ?>
<h2>Commit changes</h2>
<p>If you see any files that you don't want to add you should adjust your .gitignore file or remove unwanted files. Try not to check anything huge into the git repo and play nice.</p>
<form method=post action="index.php" id="form1">
<input type="hidden" name="view" value="status" id="stat">
<input type="text" class="form-control" name="message" placeholder="Enter your commit message here"><br>
<input type="checkbox" name="push" value="pushit"> Push commit to origin server<br>
<button type="button" id="add_and_commit" class="btn btn-primary">Add new files and commit</button>
<button type="button" id="commit" class="btn btn-success">Commit changed files only</button>
</form>
<script>
$(document).ready(function(){
$("#add_and_commit").click(function(){
$("#stat").val('add');
$("#form1").submit();
});
$("#commit").click(function(){
$("#stat").val('commit');
$("#form1").submit();
});
});
</script>
<?php } ?>