git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [RFC/GSOC] Git Beginner | Warnings for potentially destructive commands (v2)

From
Remi Galan Alfonso <remi.galan-alfonso@ensimag.grenoble-inp.fr>
Date
Mar 31, 2016, 07:59 UTC
Message-ID
<1915268342.2536406.1459411178113.JavaMail.zimbra@ensimag.grenoble-inp.fr>
In-Reply-To
<56FBF760.3040106@gmail.com>
Sidhant Sharma <tigerkid001@gmail.com> wrote:
Show 15 quoted lines
> $ ggit push --force
> 
> Pushing changes to $REMOTE/$BRANCH
> [WARNING] You are about to purge commits from the $REMOTE/$BRANCH branch and
> overwrite it's history to match yours.
> For instance, assume the following history exists where 'origin' is
> a configured remote and the current branch is master:
> 
>         o---o---o---A---B  origin/master
>              \
>               X---Y---Z  your master
> 
> After force push:
> 
>         o---o---o---X---Y---Z  origin/master and your master
It should be:
        o---o---X---Y---Z  origin/master and your master
(The last 'o' commit should have been overwritten by the force push)

Thanks, Rémi

Previous: Sidhant Sharma
Message 8 of 8 in “[RFC/GSOC] Git Beginner | Warnings for potentially destructive commands”
  1. Sidhant SharmaMar 25, 2016
  2. Junio C HamanoMar 25, 2016
  3. Jacob KellerMar 25, 2016
  4. Matthieu MoyMar 26, 2016
  5. Jacob KellerMar 27, 2016
  6. Sidhant SharmaMar 29, 2016
  7. [RFC/GSOC] Git Beginner | Warnings for potentially destructive commands (v2)Sidhant Sharma, Mar 30, 2016
  8. Remi Galan AlfonsoMar 31, 2016

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.