We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I am using the go library where a terminal isn't available. It works fine without color, but is throwing error when I set color flag to true
Error:
your terminal supports neither 24-bit nor 8-bit colors. Other coloring options aren't available
Code:
width, err := strconv.Atoi(os.Getenv("WIDTH")) if err != nil { panic(err) } color := os.Getenv("COLOR") if len(color) == 0 { color = "false" } color_bool, err := strconv.ParseBool(os.Getenv("COLOR")) if err != nil { panic(err) } fmt.Println("filename: " + file) flags := aic_package.DefaultFlags() flags.SaveImagePath = "." flags.Colored = color_bool flags.OnlySave = true flags.Dimensions = []int{width * 2, width} fmt.Println("the flags are "+ strconv.FormatBool(flags.OnlySave)) asciiArt, err := aic_package.Convert(file, flags) if err != nil { fmt.Println(err) } if (len(asciiArt)>0){ fmt.Printf("the converted file is %v\n", asciiArt) }
How can I save a colored ASCII file?
The text was updated successfully, but these errors were encountered:
Looks like solution to this would be applicable for issue #31 as well. I'll release an update for this as soon as I get time.
Sorry, something went wrong.
No branches or pull requests
I am using the go library where a terminal isn't available. It works fine without color, but is throwing error when I set color flag to true
Error:
Code:
How can I save a colored ASCII file?
The text was updated successfully, but these errors were encountered: