diff --git a/buildroot/share/git/mfdoc b/buildroot/share/git/mfdoc index 89bc5a9f1..3880c6dac 100755 --- a/buildroot/share/git/mfdoc +++ b/buildroot/share/git/mfdoc @@ -37,7 +37,7 @@ opensite() { echo "Previewing MarlinDocumentation..." # wait to open the url for about 8s -( sleep 8; opensite ) & +( sleep 45; opensite ) & bundle exec jekyll serve --watch --incremental diff --git a/buildroot/share/git/mfqp b/buildroot/share/git/mfqp index 2420f4888..67a385c2e 100755 --- a/buildroot/share/git/mfqp +++ b/buildroot/share/git/mfqp @@ -8,6 +8,10 @@ MFINFO=$(mfinfo) || exit IFS=' ' read -a INFO <<< "$MFINFO" +if [[ ${INFO[4]} == "(no" ]]; then + echo "Branch is unavailable!" ; exit 1 +fi + case "$#" in 0 ) ;; * ) echo "Usage: `basename $0`" 1>&2 ; exit 1 ;; @@ -15,5 +19,14 @@ esac git add * .travis.yml git commit -m "patch" -mfrb -git push -f + +if [[ ${INFO[3]} == ${INFO[4]} ]]; then + if [[ ${INFO[2]} == "MarlinDocumentation" ]]; then + git rebase -i HEAD~2 + else + echo "Don't alter the PR target branch."; exit 1 + fi +else + mfrb + git push -f +fi