Skip to content

Can't discard submodule with untracked changes #10403

Open

Description

@niik

Describe the bug

When attempting to discard a submodule that is marked as modified (or "dirty") due to the existence of untracked files in the submodule it's impossible to discard it from Desktop.

Version & OS

v2.5.4-beta2. Os-independent

Steps to reproduce the behavior

Using the GitHub Desktop repository as an example

  1. touch app/static/choosealicence.com/untracked-file
  2. Verify that the submodule shows up as a modified entry

image

3. Attempt to discard

image

Expected behavior

The submodule entry goes away and the untracked files in the submodule are moved to the Trash

Actual behavior

The submodule remains "dirty" because git submodule update --recursive --force doesn't concern itself with untracked file.

Additional context

See #8218

Activity

  1. added
    bug
    on Aug 18, 2020
  2. rtxa commented on Sep 14, 2024

    @rtxa

    Are there any workarounds for this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions