Skip to content

Conversation

@SandrineP
Copy link
Collaborator

Improve status output:

  • add "nothing to commit" message
  • correct the output of untracked files

// }
// }

if (!sl.has_tobecommited_header() & (sl.has_notstagged_header() | sl.has_untracked_header()))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think these should be && and || (logical operators) rather than & and | (bitwise operators).

}
}

if (!sl.has_notstagged_header() & !sl.has_untracked_header())
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar here.

// "No changes added to commit (use \"git add\" and/or \"git commit -a\")"
// (use \"git restore --staged <file>...\" to unstage)\n
// (use \"git reset HEAD <file>...\" to unstage)\n";
const std::string ignored_header = "Ignored files:\n Ignored files:\n (use \"git add -f <file>...\" to include in what will be committed)\n";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the repeat of "Ignored files:\n" intended here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, I'll remove one. I'll also comment it as it's not used so far.

Copy link
Member

@ianthomas23 ianthomas23 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @SandrineP

@ianthomas23 ianthomas23 merged commit 6667003 into QuantStack:main Nov 10, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants