Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

🐞 Git's Discard All Changes Not Correct

Open
#1,786 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
git, swift
Domain
desktop, devtools

Research direction

Start by locating the CodeEdit entry point for “Discard All Changes” and the current git restore . invocation. Read GitHub Desktop’s linked discard-changes implementation document, then verify that unstaged, staged, added, modified, and removed files are handled as expected, including moving applicable files to the trash.

Written by the indexing model from the issue text.

Description

bug source control
Description

The "Discard All Changes" functionality isn't quite correct. Right now it just runs git restore . which doesn't handle cases. We can make this feature even better by moving modified and added files to the trash similar to GH Desktop. See their implementation doc here for more details on how this should be handled.

To Reproduce

.

Expected Behavior

CodeEdit's discard changes successfully discards all changes, whether they're unstaged, staged, added, modified, or removed files.

Version Information

CodeEdit: 0.1.0

Additional Context

No response

Screenshots

No response

Dominant language
Swift
Stars
23k
Forks
1.2k
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from CodeEditApp/CodeEdit

All issues in CodeEditApp/CodeEdit

Similar issues

More Swift issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.