mirror of
https://github.com/gohugoio/hugo.git
synced 2024-12-24 12:21:21 +00:00
releaser: Improve docs submodule handling
Still not optimal.
This commit is contained in:
parent
0e1bda34c3
commit
3aade08977
1 changed files with 11 additions and 3 deletions
|
@ -142,9 +142,17 @@ func (r *ReleaseHandler) Run() error {
|
|||
}
|
||||
|
||||
if r.shouldPrepareVersions() {
|
||||
// Make sure the docs submodule is up to date.
|
||||
if _, err := git("submodule", "update", "--remote", "--merge"); err != nil {
|
||||
return err
|
||||
if newVersion.PatchLevel == 0 {
|
||||
// Make sure the docs submodule is up to date.
|
||||
// TODO(bep) improve this. Maybe it was not such a good idea to do
|
||||
// this in the sobmodule directly.
|
||||
if _, err := git("submodule", "update", "--init"); err != nil {
|
||||
return err
|
||||
}
|
||||
//git submodule update
|
||||
if _, err := git("submodule", "update", "--remote", "--merge"); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
// TODO(bep) the above may not have changed anything.
|
||||
if _, err := git("commit", "-a", "-m", fmt.Sprintf("%s Update /docs [ci skip]", commitPrefix)); err != nil {
|
||||
|
|
Loading…
Reference in a new issue