Skip to content

🐞 History Inspector is empty if the git repo doesn't have a remote defined #1743

Description

@simonwhitaker

Description

If I open a folder in CodeEdit that is under version control with Git, but which doesn't have a remote, the History Inspector view for any file is empty.

To Reproduce

  1. Create a local test repo:
    mkdir test && cd test
    git init .
    echo Hello world > test.txt
    git commit -am "First commit"
    
  2. Open the folder you created in CodeEdit
  3. Open test.txt
  4. Open the Inspector view and select the History Inspector tab

Expected Behavior

I should see a single commit for test.txt in the History Inspector

Version Information

CodeEdit: 0.1.0-dev (38)
macOS: 14.5
Xcode: 15.4

Additional Context

I'm pretty sure it's because this line is causing getCommitHistory to throw if there's no remote defined.

Screenshots

Screenshot 2024-06-03 at 3 14 02 PM

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions