mirror of
https://github.com/opnsense/plugins.git
synced 2026-02-03 20:40:37 -05:00
sysutils/git-backup: fix force push (#4988)
This commit is contained in:
parent
a828890850
commit
416712dbed
1 changed files with 1 additions and 1 deletions
|
|
@ -168,7 +168,7 @@ class Git extends Base implements IBackupProvider
|
|||
}
|
||||
exec("cd {$targetdir} && {$git} remote remove origin");
|
||||
exec("cd {$targetdir} && {$git} remote add origin " . escapeshellarg($url));
|
||||
$force_flag = (string)$mdl->force_push === "1" ? "--force-with-lease " : "";
|
||||
$force_flag = (string)$mdl->force_push === "1" ? "--force " : "";
|
||||
$pushtxt = shell_exec(
|
||||
"(cd {$targetdir} && {$git} push {$force_flag}origin " . escapeshellarg("master:{$mdl->branch}") .
|
||||
" && echo '__exit_ok__') 2>&1"
|
||||
|
|
|
|||
Loading…
Reference in a new issue