Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Display file with escaped color codes Post 302646673 by ripat on Friday 25th of May 2012 12:00:15 PM
Old 05-25-2012
Display file with escaped color codes

Hi,

I have a file containing color codes:
Code:
Fri May 25 17:13:04 2012: [....] Starting MTA: exim4^[[?25l^[[?1c^[7^[[1G[^[[32m ok ^[[39;49m^[8^[[?25h^[[?0c.
Fri May 25 17:13:05 2012: [....] Loading cpufreq kernel modules...^[[?25l^[[?1c^[7^[[1G[^[[32m ok ^[[39;49m^[8^[[?25h^[[?0cdone (acpi-cpufreq).

How can I display it colorized on a linux terminal?
 

6 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

How to have color coded Terminal display,(like linux)

Hi all, I would like to know how to have a color display in the terminal... In the sense that, In many linux terminals,we have color coded for each file type, green for executable ,blue for dirs and so on... I wanted to know how i can have the same arrangement in solaris(b-79a) I am not... (5 Replies)
Discussion started by: wrapster
5 Replies

2. 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

3. 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

4. UNIX for Dummies Questions & Answers

Display Console errors in Red color

I browsed the forums but i couldn't find the best answer.so,i'm posting here again.. I have a parent bash script which calls another child script and the child script is used to deploy the tar file using weblogic deployer. The script is used to display the output on the console and sent to a log... (5 Replies)
Discussion started by: ramse8pc
5 Replies

5. 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

6. 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
KLD(3)							   BSD Library Functions Manual 						    KLD(3)

NAME
kld_isloaded, kld_load -- kld utility functions LIBRARY
System Utilities Library (libutil, -lutil) SYNOPSIS
#include <libutil.h> int kld_isloaded(const char *name); int kld_load(const char *name); DESCRIPTION
These functions facilitate loading kernel modules from userland applications. The kld_isloaded() function takes a name and returns a non-zero value if a module of that name is currently loaded. The name can be either the name of a module file (cpufreq.ko), the same name without the .ko extension (cpufreq), or the name of a module contained within that file (cpu/ichss). Only the latter will return correct results if the module is compiled into the kernel. The kld_load() function is a simple wrapper around the kldload(2) function. It returns zero if and only if the corresponding kldload() call succeeded or returned EEXIST (signifying that the requested module was already loaded). SEE ALSO
kldfirstmod(2), kldload(2), kldnext(2), kldstat(2), modfnext(2), modstat(2), kld(4) HISTORY
The kld_isloaded() and kld_load() functions first appeared in FreeBSD 6.3. AUTHORS
The kld_isloaded() and kld_load() functions and this manual page were written by Dag-Erling Smorgrav <des@FreeBSD.org>. BSD
February 18, 2006 BSD
All times are GMT -4. The time now is 09:40 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy