mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
updated to use function for last commit
This commit is contained in:
@@ -27,7 +27,7 @@ $options = getopt('h:m:i:n:d::a::q');
|
||||
|
||||
if (!isset($options['q'])) {
|
||||
echo $config['project_name_version']." Discovery\n";
|
||||
echo `git log -n 1|grep 'commit '`."\n";
|
||||
echo get_last_commit()."\n";
|
||||
}
|
||||
|
||||
if (isset($options['h'])) {
|
||||
|
@@ -1227,3 +1227,7 @@ function fping($host,$params) {
|
||||
function function_check($function) {
|
||||
return function_exists($function);
|
||||
}
|
||||
|
||||
function get_last_commit() {
|
||||
return `git log -n 1|head -n1`;
|
||||
}//end get_last_commit
|
||||
|
@@ -23,7 +23,7 @@ require 'includes/alerts.inc.php';
|
||||
|
||||
$poller_start = utime();
|
||||
echo $config['project_name_version']." Poller\n";
|
||||
echo `git log -n 1|grep 'commit '`."\n";
|
||||
echo get_last_commit()."\n";
|
||||
|
||||
$options = getopt('h:m:i:n:r::d::a::');
|
||||
|
||||
|
Reference in New Issue
Block a user