07-24-2017
awk: cmd. line:1: warning: escape sequence `\>' treated as plain `>'
awk: cmd. line:1: warning: escape sequence `\<' treated as plain `<'
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I am attempting to convert rewrite rules to Nginx, and since due to the mass amount of rewrites we must convert, I've been trying to write a script to help me on a specific part, easily.
So far I have this:
rewrite ^action/static/(+)/$ staticPage.php?pg=$1&%$query_string;
What I want done... (5 Replies)
Discussion started by: EXT3FSCK
5 Replies
2. Shell Programming and Scripting
I want to block all special characters except alphanumerics.. and "."(dot ) character
currently am using //
I want to even block only single dot or multiple dots..
ex:
. or .............. should be blocked.
please provide me the reg ex.
---------- Post updated at 05:11 AM... (10 Replies)
Discussion started by: shams11
10 Replies
3. UNIX for Advanced & Expert Users
I have a large file encoded in Unicode that I need to convert to CSV. In general, I know how to do this by regular expression substitutions using sed or Perl, but one problem I am having is that I need to put a quotation mark at the end of each line to protect the last field. The usual regex... (1 Reply)
Discussion started by: thomas.hedden
1 Replies
4. Shell Programming and Scripting
Good morning all!!
In my code I and looking through file /etc/syslog.congf and printing every line that has /var/log in it. I need to turn the if 9$line) into a regex code instead.
#!/usr/bin/perl
@file= 'cat /etc/syslog.conf'; //when
foreach $line (@file){
if ($line =~... (3 Replies)
Discussion started by: bigben1220
3 Replies
5. Shell Programming and Scripting
I am trying to grep the following line in a file using a bash shell:
(..)
admin1::14959::::::
(..)
It works with the following expression (as expected)
# cat file | grep ^*::
admin1::14959::::::
but it does not work with (not expected)
# cat /etc/shadow | grep ^+::
I assume the... (2 Replies)
Discussion started by: schms
2 Replies
6. Shell Programming and Scripting
Hello,
Could someone explain why this one returns nothing:
$ x=/jon/
$ echo jon | awk -v xa=$x '$1~xa {print}'
$
while the following works fine:
$ x=jon
$ echo jon | awk -v xa=$x '$1==xa {print}'
$ jon
and the following works fine:
$ echo jon | awk '$1~/jon/ {print}'
$ jon
... (3 Replies)
Discussion started by: vilius
3 Replies
7. Programming
Hi all,
How am I read a file, find the match regular expression and overwrite to the same files.
open DESTINATION_FILE, "<tmptravl.dat" or die "tmptravl.dat";
open NEW_DESTINATION_FILE, ">new_tmptravl.dat" or die "new_tmptravl.dat";
while (<DESTINATION_FILE>)
{
# print... (1 Reply)
Discussion started by: jessy83
1 Replies
8. Emergency UNIX and Linux Support
Hi,
Server - MEDIAWIKI - MYSQL - CENTOS 5 - PHP5
I have a database import of close to a million pages into my wiki, mediawiki site,
the format that were left with is not pretty, and I need to find a way to clean this up and present it nicely...
I think regex is the best option as I can... (1 Reply)
Discussion started by: lawstudent
1 Replies
9. Shell Programming and Scripting
# check host value regex='^(||1|2|25)(\.(||1|2|25)){3}$' if ')" != "" ]; then if ]; then echo host $host not found exit 4 fi elif ]; then echo $host is an invalid host address exit 5 fi (1 Reply)
Discussion started by: kevin298
1 Replies
10. UNIX for Beginners Questions & Answers
I am trying to add word in last of particular line.
the same command syntex is running on prompt. but in bash script give error."sed: -e expression #1, char 20: unterminated address regex"
Please help.
for i in `cat servername`;
do
ssh -q -t root@$i sed -i '/simple_allow_groups =/s/$/,... (4 Replies)
Discussion started by: yash_message
4 Replies
jaio(7I) Ioctl Requests jaio(7I)
NAME
jaio - interface to Japanese I/O modules
SYNOPSIS
#include <sys/jaio.h>
DESCRIPTION
This interface is implemented in pushable STREAMS modules that handle Japanese I/O. These are used to query or change the third character
of the three character ISO escape sequence for announcing data.
These calls take an argument, which is expected to be a pointer to a "kioc" structure, defined in the header file sys/jaio.h, as follows:
struct kioc {
char ki;
char ko;
}:
IOCTLS
JA_SKIOC This call changes the 3rd characters of JIS Kanji-In/Out ISO announcement sequences.
JA_GKIOC This call returns the 3rd characters of JIS Kanji-In/Out ISO announcement sequences in the "kioc" structure.
EXAMPLES
Example 1: The following is an example of using these ioctls:
#include <sys/jaio.h>
struct kioc ja_kio;
struct strioctl cmd;
.
.
ja_kio.ki = '[input escape char]';
ja_kio.ko = '[output escape char]';
cmd.ic_cmd = JA_SKIOC;
cmd.ic_timout = 0;
cmd.ic_len = sizeof(kioc_t);
cmd.ic_dp = (char *)&ja_kio;
ioctl(0, I_STR, &cmd);
.
.
FILES
/sys/jaio.h
SEE ALSO
jtty(1), jconv7(7M), jconv8(7M)
SunOS 5.10 13 Aug 1998 jaio(7I)