Skip to content
New issue

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

Text coloring in "echo" function [Feature] #306

Open
SegUun opened this issue Jul 14, 2024 · 1 comment
Open

Text coloring in "echo" function [Feature] #306

SegUun opened this issue Jul 14, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@SegUun
Copy link

SegUun commented Jul 14, 2024

Hi!
I want to colorize my text using the "echo" function. Like in the default "echo" command but simpler.
In default "echo" it looks like this

RED='\033[0;31m'
NC='\033[0m'
echo -e "I ${RED}love${NC} Stack Overflow"

But maybe it might be easier. Like this.

echo "Hi Red!"@Red
echo "Hi Blue!"@#0000FF
@SegUun SegUun added the enhancement New feature or request label Jul 14, 2024
@b1ek
Copy link
Member

b1ek commented Jul 14, 2024

why not do it the normal way?

let red = "\x1b[31m"
let rst = "\x1b[0m"

echo "I {red}love{rst} stackoverflow!"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants