Bug 935525

Summary: zypper option --no-color doesn't suppress ANSI escape codes
Product: [openSUSE] openSUSE Distribution Reporter: Forgotten User 7XRNh5WElB <forgotten_7XRNh5WElB>
Component: libzyppAssignee: E-mail List <zypp-maintainers>
Status: RESOLVED DUPLICATE QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None    
Version: 13.2   
Target Milestone: ---   
Hardware: Other   
OS: openSUSE 13.2   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Forgotten User 7XRNh5WElB 2015-06-21 09:08:32 UTC
Even with the --no-color option, the output of zypper is littered with ANSI escape codes which makes it very hard to parse the output.

Here is the output of "zypper --no-color in alpine", as seen by vi:

> Loading repository data...
> Reading installed packages...
> Resolving package dependencies...
> 
> The following 2 NEW packages are going to be installed:^[[0m
>   a^[[0mlpine a^[[0mlpine-branding-openSUSE 
> 
> 2^[[0m new packages to install.
> Overall download size: 1.8 MiB. Already cached: 0 B  After the operation, additional 8.9 MiB will be used.
> Continue? [y^[[0m/n^[[0m/?^[[0m shows all options] (y^[[0m): ^[[0mInvalid answer 'no'. [y^[[0m/n^[[0m/?^[[0m shows all options] (y^[[0m): ^[[0m

Using zypper 1.11.23 on openSUSE 13.2.
Comment 1 Michael Andres 2015-06-22 07:40:19 UTC
fixed in 1.11.26

*** This bug has been marked as a duplicate of bug 925678 ***