public inbox for git@vger.kernel.org 
 help / color / mirror / Atom feed
From: <rsbecker@nexbridge•com>
To: "'Kipras Melnikovas'" <kipras@kipras•org>, <wyattscarpenter@gmail•com>
Cc: <git@vger•kernel.org>
Subject: RE: Short form of --force-with-lease
Date: Thu, 11 Apr 2024 15:21:00 -0400	[thread overview]
Message-ID: <01e101da8c45$66d33240$347996c0$@nexbridge.com> (raw)
In-Reply-To: <20240411173639.81152-2-kipras@kipras.org>

On Thursday, April 11, 2024 1:37 PM, Kipras Melnikovas wrote:
>I'd suggest a config option "push.forceFlagBehavior" that would allow to
configure
>the behavior, one of:
>- "default" / "overwrite", which is currently -f,
>- "lease" for --force-with-lease,
>- "lease-includes"  for --force-with-lease --force-if-includes,
>- possibly others.
>
>Then, upon `git push -f`, the config option would be consulted to determine
the
>behavior.
>
>To get the default behavior, `-f -f` or `-F` could be used.

If this is mostly about saving typing, you could get a similar effect adding
an alias. Something like

git config --global alias.pushfl 'push --force-with-lease'


  reply	other threads:[~2024-04-11 19:21 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-11 17:16 Short form of --force-with-lease Wyatt Carpenter
2024-04-11 17:36 ` Kipras Melnikovas
2024-04-11 19:21   ` rsbecker [this message]
2024-04-11 20:32     ` Kipras Melnikovas
2024-04-11 20:58       ` Kyle Lippincott
2024-04-12  9:00         ` Kipras Melnikovas
2024-04-11 21:30     ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='01e101da8c45$66d33240$347996c0$@nexbridge.com' \
    --to=rsbecker@nexbridge$(echo .)com \
    --cc=git@vger$(echo .)kernel.org \
    --cc=kipras@kipras$(echo .)org \
    --cc=wyattscarpenter@gmail$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox