Solved

how can I get color matching in grub in freebsd?

Posted on 2008-10-23
5
735 Views
Last Modified: 2013-12-06
In linux this seems to be working great..

GREP_OPTIONS='--color=auto' ; export GREP_OPTIONS

now sure how to achieve this in freebsd.. can someone help me to get 'color' matched pattern in freebsd

this is what I get in freebsd..

$grep --color=auto
grep: unrecognized option `--color=auto'
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
0
Comment
Question by:beer9
  • 3
  • 2
5 Comments
 
LVL 29

Accepted Solution

by:
TeRReF earned 125 total points
ID: 22784270
instead of color use colour...

So,

$grep --colour=auto

should work :-)
0
 

Author Comment

by:beer9
ID: 22784299
Again same issue.. --colour is not recognized keyword in grep [freebsd,solaris]
0
 
LVL 29

Expert Comment

by:TeRReF
ID: 22784350
This is my grep version:

grep --version
grep (GNU grep) 2.5.1-FreeBSD

This is the output when I use --colour:

grep --colour=auto file *
d:upload_max_filesize => 2M => 2M
d:Supported handlers => cdb cdb_make inifile flatfile
d:Supported filetypes => JPEG,TIFF
d:fileinfo
d:fileinfo support => enabled
etc...

And file is highlighted nicely.

What version do you use? Did you do a:
man grep

To check if your version does/ does not support the --colour option?

If not, maybe it's time to update your version...
0
 

Author Comment

by:beer9
ID: 22785355
I had a version 2.4, tested in grep version 2.5, working nice!
Thank you :)
0
 
LVL 29

Expert Comment

by:TeRReF
ID: 22785400
You're welcome :)
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

A metadevice consists of one or more devices (slices). It can be expanded by adding slices. Then, it can be grown to fill a larger space while the file system is in use. However, not all UNIX file systems (UFS) can be expanded this way. The conca…
I have been running these systems for a few years now and I am just very happy with them.   I just wanted to share the manual that I have created for upgrades and other things.  Oooh yes! FreeBSD makes me happy (as a server), no maintenance and I al…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now