mirror of
https://github.com/pi-hole/pi-hole.git
synced 2025-04-22 07:10:19 +00:00
Update local and remote versions at the same time
Signed-off-by: Christian König <ckoenig@posteo.de>
This commit is contained in:
parent
56527e5dd9
commit
18d28533eb
5 changed files with 60 additions and 66 deletions
|
@ -42,11 +42,6 @@ warning1() {
|
|||
esac
|
||||
}
|
||||
|
||||
updateCheckFunc() {
|
||||
/opt/pihole/updatecheck.sh
|
||||
/opt/pihole/updatecheck.sh x remote
|
||||
}
|
||||
|
||||
checkout() {
|
||||
local corebranches
|
||||
local webbranches
|
||||
|
@ -169,8 +164,8 @@ checkout() {
|
|||
exit 1
|
||||
fi
|
||||
checkout_pull_branch "${webInterfaceDir}" "${2}"
|
||||
# Force an update of the updatechecker
|
||||
updateCheckFunc
|
||||
# Update local and remote versions via updatechecker
|
||||
/opt/pihole/updatecheck.sh
|
||||
elif [[ "${1}" == "ftl" ]] ; then
|
||||
local path
|
||||
local oldbranch
|
||||
|
@ -185,8 +180,8 @@ checkout() {
|
|||
FTLinstall "${binary}"
|
||||
restart_service pihole-FTL
|
||||
enable_service pihole-FTL
|
||||
# Force an update of the updatechecker
|
||||
updateCheckFunc
|
||||
# Update local and remote versions via updatechecker
|
||||
/opt/pihole/updatecheck.sh
|
||||
else
|
||||
echo " ${CROSS} Requested branch \"${2}\" is not available"
|
||||
ftlbranches=( $(git ls-remote https://github.com/pi-hole/ftl | grep 'heads' | sed 's/refs\/heads\///;s/ //g' | awk '{print $2}') )
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue