aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKonstantin Ryabitsev <konstantin@linuxfoundation.org>2023-01-10 17:35:54 -0500
committerKonstantin Ryabitsev <konstantin@linuxfoundation.org>2023-01-10 17:39:22 -0500
commitd001fef0b344c8d95d3be51dc96a024ae3ef3119 (patch)
tree31f0a594edff2eaa66d11e8633b0f9804d6600ce
parent2aa399523258ec7751c751ad9a447930aaf83e72 (diff)
downloadb4-stable-0.11.y.tar.gz
ez: refuse to invoke send if repo is not cleanstable-0.11.y
Since a "send" operation will require repo modification when we tag it, refuse to operate if repo status is not clean. Reported-by: Rob Herring <robh@kernel.org> Link: https://msgid.link/CAL_JsqLU8qb-aNGDZ45mq8_e=Oin6QY+8vBdfyUSPBFDVCFJEA@mail.gmail.com Signed-off-by: Konstantin Ryabitsev <konstantin@linuxfoundation.org>
-rw-r--r--b4/ez.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/b4/ez.py b/b4/ez.py
index 08a1924..fb80238 100644
--- a/b4/ez.py
+++ b/b4/ez.py
@@ -1282,6 +1282,12 @@ def cmd_send(cmdargs: argparse.Namespace) -> None:
logger.info('---')
sys.exit(1)
+ status = b4.git_get_repo_status()
+ if len(status):
+ logger.critical('CRITICAL: Repository contains uncommitted changes.')
+ logger.critical(' Stash or commit them first.')
+ sys.exit(1)
+
try:
todests, ccdests, tag_msg, patches = get_prep_branch_as_patches(
hide_cover_to_cc=cmdargs.hide_cover_to_cc)