Is there an easier way to do the following:
echo "|||||||" | sed 's/||/|0|/g; s/||/|0|/g'
which would give the following
|0|0|0|0|0|0|
If it is not run twice it will not pick up the second occurance of the || and leave it empty as in
echo "|||||||" | sed 's/||/|0|/g'
which would give... (3 Replies)
Hello
My file looks like that =>
12.56 have then 7888778.2566 what 44454.54545
878787.66565 if else 4445.54545455
I want to change all '.' on ',' .
I'm trying to do it with sed but I don't know chow to build regular expression to
change 454.4466 on 454,4466 ? (13 Replies)
hi
is it possible to cut this two semicolon separated sed commands
echo "string2 string3 string1" | sed s'/string1//g;s/string2//g'
output: " string3 "
to just one sed command without semicolon?
thanks in advance
funksen (10 Replies)
I have a file
CREATE TABLE DDD_EXT --- 1000
(
val u1
val u1
);
CREATE TABLE dsdasd_EXT --- 1323
(
val u1
val u1
);
CREATE TABLE AAAAAA_EXT --- 1222
(
val u1
val u1
);
CREATE TABLE E_EXT --- 11
(
val u1
val u1 (2 Replies)
I have a log output with a format similar to this:
a=1, b= 2
c=0, d= 45, e=100
... and so on.
I figure I can just use awk or something to pipe the file to sed, but I'm trying to replace all the values above with 0.
I've tried:
cat blah | sed 's/=\(.*\),/0/'but that didn't work. ... (6 Replies)
I have the following line an in input file I want to digest with sed and simple replace the bold part with a variable defined in my bash script. I can do this in several sed operations but I know there must be a way to do it in a single sed line. What is the syntax?
Line in file:... (1 Reply)
Cheers!
In /etc/syslog.conf, if an error type is not specified, is it logged anywhere (most preferable is it logged to /var/log/messages) or not?
To be more precise I am interested in error and critical level messages. At default these errors are not specified in syslog.conf, and I need to... (6 Replies)
Discussion started by: dr1zzt3r
6 Replies
LEARN ABOUT LINUX
irsend
IRSEND(1) User Commands IRSEND(1)NAME
irsend - basic LIRC program to send infra-red commands
SYNOPSIS
irsend [options] DIRECTIVE REMOTE CODE [CODE...]
DESCRIPTION
Asks the lircd daemon to send one or more CIR (Consumer Infra-Red) commands. This is intended for remote control of electronic devices such
as TV boxes, HiFi sets, etc.
DIRECTIVE can be:
SEND_ONCE - send CODE [CODE ...] once
SEND_START - start repeating CODE
SEND_STOP - stop repeating CODE
LIST - list configured remote items
SET_TRANSMITTERS - set transmitters NUM [NUM ...]
SIMULATE - simulate IR event
REMOTE is the name of a remote, as described in the lircd configuration file.
CODE is the name of a remote control key of REMOTE, as it appears in the lircd configuration file.
NUM is the transmitter number of the hardware device.
For the LIST DIRECTIVE, REMOTE and/or CODE can be empty:
LIST "" "" - list all configured remote names
LIST REMOTE "" - list all codes of REMOTE
LIST REMOTE CODE - list only CODE of REMOTE
The SIMULATE command only works if it has been explicitly enabled in lircd.
-h --help
display usage summary
-v --version
display version
-d --device
use given lircd socket [/var/run/lirc/lircd]
-a --address=host[:port]
connect to lircd at this address
-# --count=n
send command n times
EXAMPLES
irsend LIST DenonTuner ""
irsend SEND_ONCE DenonTuner PROG-SCAN
irsend SEND_ONCE OnkyoAmpli VOL-UP VOL-UP VOL-UP VOL-UP
irsend SEND_START OnkyoAmpli VOL-DOWN ; sleep 3
irsend SEND_STOP OnkyoAmpli VOL-DOWN
irsend SET_TRANSMITTERS 1
irsend SET_TRANSMITTERS 1 3 4
irsend SIMULATE "0000000000000476 00 OK TECHNISAT_ST3004S"
FILES
/etc/lirc/lircd.conf
Default lircd configuration file. It should contain all the remotes, their infra-red codes and the corresponding timing and wave-
form details.
DIAGNOSTICS
If lircd is not running (or /var/run/lirc/lircd lacks write permissions) irsend aborts with the following diagnostics:
"irsend: could not connect to socket"
"irsend: Connection refused" (or "Permission denied").
SEE ALSO
The documentation for lirc is maintained as html pages. They are located under html/ in the documentation directory.
lircd(8), mode2(1), smode2(1), xmode2(1), irrecord(1), irw(1), http://www.lirc.org.
irsend 0.9.0-pre1 October 2010 IRSEND(1)