•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the Shell Scripting section within the Software Development category of DaniWeb, a massive community of 455,865 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,649 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Shell Scripting advertiser: Programming Forums
Views: 927 | Replies: 4 | Solved
•
•
Join Date: Jun 2008
Posts: 15
Reputation:
Rep Power: 1
Solved Threads: 0
I'm trying to add colors to this bash script, can anyone help?
Here are the errors:
#!/bin/bash # Script to connect to the sprint network # Colors # ESC_SEQ=“\x1b[“ COL_RESET=$ESC_SEQ“39;49;00m“ COL_RED=$ESC_SEQ“31;01m“ COL_GREEN=$ESC_SEQ“32;01m“ COL_YELLOW=$ESC_SEQ“33;01m“ COL_BLUE=$ESC_SEQ“34;01m“ COL_MAGENTA=$ESC_SEQ“35;01m“ COL_CYAN=$ESC_SEQ“36;01m“ case "$1" in connect) pppd call sprint updetach echo -e $COL_GREEN"**You are now connected to the sprint network!"$COL_RESET ;; disconnect) killall pppd echo -e $COL_RED"**You have disconnected from the sprint network!"$COL_RESET ;; esac
Here are the errors:
root@mybox:~/Scripts# ./sprint disconnect ./sprint: line 6: 49: command not found ./sprint: line 6: 00m“: command not found ./sprint: line 7: 01m“: command not found ./sprint: line 8: 01m“: command not found ./sprint: line 9: 01m“: command not found ./sprint: line 10: 01m“: command not found ./sprint: line 11: 01m“: command not found ./sprint: line 12: 01m“: command not found “31**You have disconnected from the sprint network!“39
•
•
•
•
•
•
•
•
DaniWeb Shell Scripting Marketplace
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Other Threads in the Shell Scripting Forum
- Previous Thread: .bat - Direct stdout to console AND file
- Next Thread: compare and remove older files



Threaded Mode