Re: On git 1.6 (novice's opinion)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ulrich Windl a écrit :
3) "git undo": If possible undo the effects of the last command.

If impossible, add confirmations for some "dangerous" (non-obvious) commands before doing possibly harmful things. Maybe adding a kind of "user-level setting" (novice, expert, guro) could control such confirmations.

Why ?
All objects stored are immutable, and some tools keep informations (ORIGIN_HEAD, refs/original) to allow a undo hand-made. Moreover the reflog (and stash if you want to use it for this use) store informations during time...

So it's possible to provide a generic undo for all commands that change refs.

Maybe an "undo" directory in $GIT_DIR, which will a keep a copy version of all refs. Every commands store the current refs in this folder _before_
to change anything, and the undo restore them all.
At least, a "lastcmd" (for example) file could be added in this directory to allow an more clever undo.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux