alpine-docker / git

A useful simple git container running in alpine linux, especially for tiny linux distro, such as RancherOS, which don't have package manager.
Apache License 2.0
155 stars 86 forks source link

Git output with ANSI escape codes are not handled (e.g., diff) #11

Closed stuckj closed 5 years ago

stuckj commented 5 years ago

By default, git outputs diff output with ANSI escape codes to colorize it. While, this can be disabled, it is convenient. However, with this container the output shows the code rather than actually handling them. I believe this requires some configuration in the image to be able to properly handle the ANSI escape codes (potentially changing the pager).

ozbillwang commented 5 years ago

Can you run with option --no-color with log or show command?

docker run -ti --rm -v ${HOME}:/root -v $(pwd):/git alpine/git diff --no-color

This option works for log, show, and other subcommands as well.

Maybe we need update the README for this usage.

stuckj commented 5 years ago

Potentially. I can (and have for now) disabled color via the ui = false setting in the [color] section of .gitconfig. However...colorization is really helpful so it would be nice if it was supported. :)

ozbillwang commented 5 years ago

fixed with #12