sourcegit-scm / sourcegit

Windows/macOS/Linux GUI client for GIT users
MIT License
1.14k stars 109 forks source link

Amend - STAGED empty #206

Closed lgranie closed 3 months ago

lgranie commented 3 months ago

Hi,

I do not know if it is a bug or a new feature : when amending the STAGED part is empty. It is very useful to be able to know what a commit contents and edit it while amending like unstaging some modifications, not only add new modifications from UNSTAGED.

Is it possible to have all the commit modifications in STAGED when click on Amend?

Another : when I unselect Amend, the commit message & comment are not cleaned

love-linger commented 3 months ago

This app does nothing but set a variable that tells to use --amend argument in commit command. It's not a BUG or a feature. Just the way we do it in command line.

lgranie commented 3 months ago

This app does nothing but set a variable that tells to use --amend argument in commit command. It's not a BUG or a feature. Just the way we do it in command line.

Will it be possible to add / think about this new feature?

gadfly3173 commented 3 months ago

You can use the "Reset to Here" function to meet your needs.

love-linger commented 3 months ago

Will it be possible to add / think about this new feature?

This feature is not in development plans, at least not in the near future.

In my opinion, --amend is designed to continuously patch HEAD commit. We are still working on the HEAD's snapshot. For incorrect submissions, it is not necessary to take out the submitted CHANGES and then correct them from the staged group, but to directly modify those files and commit them with --amend option.

If there are too many errors, or if you need to commit other completed content that is not related to the HEAD commit, I still recommend you running reset --soft first and then recommit those files.