mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-27 15:54:29 +02:00
Added a function to get the branch we are building.
This commit is contained in:
parent
5c9b747519
commit
1e4881bf43
@ -8,3 +8,11 @@ BUILD=$(grep 'my $pandora_build =' $CODEHOME/pandora_server/lib/PandoraFMS/Confi
|
|||||||
X86_64=`uname -m | grep x86_64`
|
X86_64=`uname -m | grep x86_64`
|
||||||
CONSOLEHOME=$CODEHOME/pandora_console
|
CONSOLEHOME=$CODEHOME/pandora_console
|
||||||
CONSOLEHOME_ENT=$CODEHOME_ENT/pandora_console
|
CONSOLEHOME_ENT=$CODEHOME_ENT/pandora_console
|
||||||
|
|
||||||
|
function get_current_branch {
|
||||||
|
cd "$CODEHOME" || return ""
|
||||||
|
BRANCH=`git branch 2>/dev/null | grep \* | awk '{print $2}'`
|
||||||
|
cd -
|
||||||
|
return $BRANCH
|
||||||
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user