Skip to content

diskonaut leaves terminal unclean if non-existing dir #105

@hydrargyrum

Description

@hydrargyrum

When running diskonaut on a non-existing dir, it exits with an error and leaves the terminal in an unclean state. When running for example "ls" after it, the columns are not aligned as they were before running diskonaut:

% ls        
1  4  7  10  13  16  19  22  25  28  31  34  37  40  43  46  49
2  5  8  11  14  17  20  23  26  29  32  35  38  41  44  47  50
3  6  9  12  15  18  21  24  27  30  33  36  39  42  45  48  
% diskonaut non-existing
Error: Folder 'non-existing' does not exist
                                           %                                    % ls                    
1  4  7  10  13  16  19  22  25  28  31  34  37  40  43  46  49
                                                               2  5  8  11  14  17  20  23  26  29  32  35  38  41  44  47  50
                                              3  6  9  12  15  18  21  24  27  30  33  36  39  42  45  48  
                           %                                                    % 


and BTW, when diskonaut exits cleanly, the terminal is not garbled, but no newline is emitted at the end (after some real characters are left), which not be reacted well to by shells

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions