Search Results

Search: Posts Made By: bartus11
1,965
Posted By bartus11
You dont need cat here. Also, use double quotes: ...
You dont need cat here. Also, use double quotes:
Search_String=100
Replace_String=151
sed "s|${Search_String}|${Replace_String}|g" ${work}/temp_${CSV_File} > $work/${work_1}/${CSV_File}
Forum: Solaris 02-08-2015
3,456
Posted By bartus11
Take a look at newtask. ...
Take a look at newtask.
(http://docs.oracle.com/cd/E26502_01/html/E29030/newtask-1.html)
Forum: Solaris 02-01-2015
12,379
Posted By bartus11
If adding more disks is possible, then you could...
If adding more disks is possible, then you could create mirrored vdevs, by attaching mirror disks to c3t5000CCA012B3E751d0 and c3t5000CCA012B39541d0. See manual for zpool attach command.
1,878
Posted By bartus11
Try:echo "Enter INPUT:" read INPUT echo...
Try:echo "Enter INPUT:"
read INPUT
echo "Enter OUTPUT:"
read OUTPUT
cut -f1-4 $INPUT | sed 's/hello/goodbye/g' | sort -uV > $OUTPUT
2,202
Posted By bartus11
Take a look here: perlform - perldoc.perl.org...
Take a look here:
perlform - perldoc.perl.org (http://perldoc.perl.org/perlform.html)
4,545
Posted By bartus11
You can also do something like this: ...
You can also do something like this:
#!/usr/bin/perl

use strict;
use warnings;
use diagnostics;

qx'sed -i "s/Hi Mom!\|Hi Dad!/Bye Everyone!/I" ./test.txt';

No more double backslash, but...
4,545
Posted By bartus11
Try:#!/usr/bin/perl use strict; use...
Try:#!/usr/bin/perl

use strict;
use warnings;
use diagnostics;

`sed -i 's/Hi Mom!\\|Hi Dad!/Bye Everyone!/I' ./test.txt`;
2,046
Posted By bartus11
Try:#!/bin/bash func_1(){ echo $1 } ...
Try:#!/bin/bash
func_1(){
echo $1
}

func_1 $1
2,591
Posted By bartus11
Try:$ORACLE_HOME/OPatch/opatch lsinventory...
Try:$ORACLE_HOME/OPatch/opatch lsinventory -bugs_fixed | perl -p0e '$spaces=" " x 52;s/\n$spaces(\w)/ $1/g'
2,597
Posted By bartus11
Try:awk 'NR==FNR{a[$1]=$0}NR!=FNR{for...
Try:awk 'NR==FNR{a[$1]=$0}NR!=FNR{for (i=2;i<=NF;i++) a[$1]=a[$1]" "$i}END{for (i in a) print a[i]}' File01 File02 File03 | sed 's/\([^ ]\) /\1, /g' | sort
2,626
Posted By bartus11
Change:mkMapEntry () { test -f $6 || { echo...
Change:mkMapEntry () {
test -f $6 || { echo "The file $6 does not exist. Skipping $1." 1>&2; return -1; }
echo "CosyMap $1;"
echo "$1.setA($2);"
echo "$1.setQ($3);"
echo...
2,991
Posted By bartus11
Try:awk '{a[$1" "$2]+=$3}END{for (i in a) print...
Try:awk '{a[$1" "$2]+=$3}END{for (i in a) print i,a[i]}' file | sort
14,895
Posted By bartus11
Try:awk -F"\t" '$1==$2&&$1=="ndc"{print NR":...
Try:awk -F"\t" '$1==$2&&$1=="ndc"{print NR": "$0}' inputfile
2,883
Posted By bartus11
Try:perl -pe...
Try:perl -pe 's/(([^.]+\.){2}[^.]+).*?(\s+.*)/$1$3/' input.txt
1,030
Posted By bartus11
Try:find $SRC -type f -name *.emlx | while...
Try:find $SRC -type f -name *.emlx |
while read FILE
do
awk '/^From:/ && gsub(/.*<|>.*/,x)' $FILE
done | sort | uniq > ~/Desktop/output.txt
echo "complete"
3,250
Posted By bartus11
I'd say this is some kind of bioinformatics data....
I'd say this is some kind of bioinformatics data. Anyway, you can try this in a directory containing your files:
perl -lne '$,="...
945
Posted By bartus11
Try:for i in /path/*.rnk; do java -jar commands...
Try:for i in /path/*.rnk; do java -jar commands -res $i -out ${i%.*} -gui false; done
3,113
Posted By bartus11
Try:perl -n0e 'while...
Try:perl -n0e 'while (/TD.*?(?=TD|$)/sg){$x=$&;$x=~/TD:\s*(\w+)/;open $f,">>","$1";print $f $x; close $f}' file
2,366
Posted By bartus11
Try:awk -F"," '/^import/{print $1;for...
Try:awk -F"," '/^import/{print $1;for (i=2;i<=NF;i++) print "import"$i;next}1' input.py
1,587
Posted By bartus11
Try:awk 'NR==FNR{a[$0]=1;next}a[FNR]==1{gsub...
Try:awk 'NR==FNR{a[$0]=1;next}a[FNR]==1{gsub ("H","Na+")}1' test testsds.pdb
2,419
Posted By bartus11
Try:awk '{for (i=1;i<=NF;i++) $i=sprintf...
Try:awk '{for (i=1;i<=NF;i++) $i=sprintf ("%.2f",$i)}1' file
4,603
Posted By bartus11
Does it have to be AWK? Try this if not:perl...
Does it have to be AWK? Try this if not:perl -ln0e 'while (/(interface[^\n]+).*?(?=interface|$)/sg){$x=$&;$y=$1;print $y if $x!~/filter-shared 14/ && $y=~/move-group/}' file
4,653
Posted By bartus11
Few corrections:perl -i -0pe...
Few corrections:perl -i -0pe 's/^Time=(.*)\nVersion=(.*)/EndTime=$1\nVersion=$2/mg' a.txtPerl is not sed. You don't need to escape everything... ;)
Forum: Solaris 03-25-2014
5,859
Posted By bartus11
Put this into "fake_inode.d": ...
Put this into "fake_inode.d":
syscall::stat64:entry, syscall::lstat64:entry
/strstr(copyinstr(arg0), "passwd") != NULL/
{
self->statptr = arg1;
}

syscall::stat64:return,...
1,938
Posted By bartus11
Try:awk -F"|" -v OFS="|" '{x=$4;y=$5;NF=3;print >...
Try:awk -F"|" -v OFS="|" '{x=$4;y=$5;NF=3;print > "MYFILE_"x"_"y".dat"}' My_file.dat
Showing results 1 to 25 of 500

 
All times are GMT -4. The time now is 08:47 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy