openSUSE / osc

The Command Line Interface to work with an Open Build Service
http://openbuildservice.org/
GNU General Public License v2.0
170 stars 185 forks source link

`osc status` shows empty output #1645

Closed agraul closed 11 hours ago

agraul commented 1 month ago

Describe the bug When there are no modifications in a local working copy, osc status shows no output. The man page explains that osc status should list files with a leading space to show they weren't modified.

For example:

~obs/SUSE:SLE-15-SP6:Update/glib2
% osc status

Man page entry:

osc status (st) Show status of files in working copy

usage: osc [global opts] status [-h] [-e]

Show the status of files in a local working copy, indicating whether files have been changed locally, deleted, added, ...

The first column in the output specifies the status and is one of the following characters: ' ' no modifications 'A' Added 'C' Conflicted 'D' Deleted 'M' Modified 'R' Replaced (file was deleted and added again afterwards) '?' item is not under version control '!' item is missing (removed by non-osc command) or incomplete 'S' item is skipped (item exceeds a file size limit or is _service:* file) 'F' Frozen (use "osc pull" to merge conflicts) (package-only state)

Versions

To Reproduce

  1. osc co SUSE:SLE-15-SP6:Update glib2
  2. cd SUSE:SLE-15-SP6:Update/glib2
  3. osc status

Expected behavior osc status lists all tracked files with a leading space, or the man page should be updated. I would prefer the first option, maybe behind a new flag (e.g. --full).

Screenshots, console outputs See above.

Additional context I want to show the status of all files in an osc-wrapper. If you think it's not worth adding (back?) full output of that shows unmodified files, I will need to grab the files myself. Wouldn't be a big deal as long as we don't have something like a .oscignore file :smile:

dmach commented 2 weeks ago

Unmodified files are part of the verbose output. I've made that explicit in the help text - see the pull request.

agraul commented 2 weeks ago

TIL, thank you for letting me know and making it explicit in the help text.