Sponsored Content
Top Forums UNIX for Beginners Questions & Answers Filter valid hexadecimal color codes Post 303045968 by vgersh99 on Monday 20th of April 2020 11:14:09 AM
Old 04-20-2020
I don't know either...
Most likely because you're using Extended RegEx without telling grep to do so (-E)
could you provide a sample file and a desired output (as always)?
 

6 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Using color escape codes in less

Hi all, Not sure how "for dummies" this question is, but I'd better use understatement... A. My Environment ============== I am using RedHat Linux, version 2.6.18-53.el5. When I type less --version I get: less 394 Copyright (C) 1984-2005 Mark Nudelman ... My terminal is configured... (1 Reply)
Discussion started by: Source2Exe
1 Replies

2. UNIX for Dummies Questions & Answers

Regular expression on hex color codes

I want to have all hex color codes in a given stylesheet in uppercase, so #fff should be converted to #FFF for instance. Here is the regular expression I use to match and convert hex color codes to uppercase: sed -e 's/^#({3}$)|({6}$)/^#({3}$)|({6}$)/' main.css However, no conversion to uppercase... (6 Replies)
Discussion started by: figaro
6 Replies

3. Programming

Using ANSI color codes in gcc compiled program

I have put some yellow color codes and works well. I call the funstion using print_usage(stderr, 0); I would like to know if there is any way, to store the ansi color codes in variables and then call them inside fprintf. Or have a format followed by the strings I want to output. ... (5 Replies)
Discussion started by: kristinu
5 Replies

4. UNIX for Dummies Questions & Answers

Display file with escaped color codes

Hi, I have a file containing color codes: Fri May 25 17:13:04 2012: Starting MTA: exim4^ Loading cpufreq kernel modules...^How can I display it colorized on a linux terminal? (4 Replies)
Discussion started by: ripat
4 Replies

5. Shell Programming and Scripting

Help with awk color codes based on condition

HI i have two files say test and test1 Test.txt Code: Lun01 2TB 1.99TB 99.6% Lun02 2TB 1.99TB 99.5% Lun03 2TB 1.99TB 99.5% Lun04 2TB 1.55TB 89.6% Code: Test1.txt Lun01 2TB 1.99TB 89.5% Lun02 2TB 1.99TB 99.5% Lun03 2TB 1.99TB 99.5% Requirement is to compare... (6 Replies)
Discussion started by: venkitesh
6 Replies

6. Shell Programming and Scripting

Filter Data based on codes

Hello, I have a question on how to filter the data on multiple columns. The problem is I have one table with 25 columns, 4500 rows. I need to filter out the data based on some codes like 'XXXX', I have 25 codes to check on that table. My requirement is that which ever row has this code I... (1 Reply)
Discussion started by: sandeep309
1 Replies
CATCODEC(1)						    BSD General Commands Manual 					       CATCODEC(1)

NAME
catcodec -- An open source tool to decode/encode the sample catalogue for OpenTTD SYNOPSIS
catcodec [-d sample_file] [-e sample_file] DESCRIPTION
catcodec decodes and encodes sample catalogues for OpenTTD. These sample catalogues are not much more than some meta-data (description and file name) and raw PCM data. Decoding a sample catalogue, e.g. sample.cat, results in a sample.sfo that contains the file names and descriptions of the samples and all samples with the file name as specified in the catalogue. Encoding a sample catalogue, e.g. sample.cat, reads sample.sfo for the file names and descriptions. It will then load the samples described in sample.sfo and encodes these into sample.cat. Generally speaking encoding a file and then decoding it results in the same file. Decoding of the original, Transport Tycoon Deluxe, sample format will force the output to be 11025 Hz, 8 bits mono because the meta-data of some of the samples is incorrect or even missing. Only PCM WAVE files with only the format and data chunks are supported. Any other formats need to be converted into this. Furthermore only 11025 Hz, 22050 Hz and 44100 Hz with 8 or 16 bits per sample single channel PCM WAVE files are supported. OPTIONS
-d sample_file Decode the given sample catalogue into its components. The sample_file must have the extension '.cat'. For the output meta- data file the '.cat' is replaced with '.sfo'. The actual samples, in PCM WAVE format, are extracted into files using the file names, including extension, as described in the catalogue or meta-data file. If any of the files already exists a backup is made, by adding '.bak', overwriting the existing backup. -e sample_file Encode the components for the given sample file into a sample catalogue. The sample_file must have the extension '.cat'. For the input meta-data file the '.cat' is replaced with '.sfo'. The actual samples, in PCM WAVE format, are read from files using the file names, including extension, as described in the meta-data file. If the sample_file already exists a backup is made, by adding '.bak', overwriting the existing backup. SEE ALSO
openttd(1) the game that uses these sample catalogues. AUTHORS
Remko Bijker <rubidium@openttd.org> November 05, 2009
All times are GMT -4. The time now is 11:46 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy