Search Results

Search: Posts Made By: shellscripting
5,442
Posted By shellscripting
Confusion with the concept of wc -c and wc -m
Is wc -c and wc -m same ?

Shellscript::cat file1
hello
Shellscript::cat file1 | wc -c
6
Shellscript::cat file1 | wc -m
6
Shellscript::file file1
file1: ASCII text
Shellscript::uname -a...
1,634
Posted By shellscripting
GoodMorning Everybody, This is what i did....
GoodMorning Everybody,

This is what i did. Right click and "Open in Terminal". I have only opened a single terminal.

Test 1 with infinite.sh
==================

Shellscript:ls
infinite.sh...
1,634
Posted By shellscripting
Below is the system information that i get ...
Below is the system information that i get
Shellscript:echo $SHELL
/bin/bash
Shellscript:uname -a
Linux was85host 2.6.27.45-0.1-vmi #1 SMP 2010-02-22 16:49:47 +0100 i686 i686 i386 GNU/Linux
1,634
Posted By shellscripting
Background job not working as expected
Hello Unix Buddies,


cat infinite.sh

#!/bin/sh
while true
do
echo "Infinite loop"
doneI am running it in the background
$ ./infinite.sh > /dev/null &
[1] 31634Then i do an exit or...
1,359
Posted By shellscripting
Thank you Cero for the concept. I will google for...
Thank you Cero for the concept. I will google for LC_ALL and LC_COLLATE.
I got my desired output.

shellscript:cat sort.txt
aaa
bbb
ddd
AAA
eee
GGG
ggg
shellscript:sort sort.txt
aaa
AAA...
1,359
Posted By shellscripting
Sort concept confusion
By default, sort reorders lines in ASCII collating sequence --- whitespace first, then numerals,uppercase letters and finally lowercase letters.

Shellscript:cat sort.txt
aaa
bbb
ddd
AAA
eee...
868
Posted By shellscripting
Thank you both for explaining it with examples
Thank you both for explaining it with examples
868
Posted By shellscripting
Help in backreferences
# cat file
Hello world
Hello earth
"Hello" world hello world 'hello'
hello "world"
hello 'world'
hello hello
hello hello helloTarget :- For more than one occurence of hello[Below code works...
1,546
Posted By shellscripting
I am a beginner and i am learning. I will get...
I am a beginner and i am learning. I will get back on this,when i learn enough to write it.

Please no more replies to this thread. Moderator can close this thread if they feel necessary.
1,546
Posted By shellscripting
No this is not a home work assignment. I am not...
No this is not a home work assignment. I am not able to figure it out at all.
I am using bash shell and linux operating system
1,546
Posted By shellscripting
Pattern Matching and replacement
Hello Everybody,

I need a help in the below pattern matching and replacement issue
I have a file : emp.txt
21356 suresh 12/12/2012
23511 ramesh 11/06/2011
31456 biswajit 09/08/2013
53134...
797
Posted By shellscripting
Thank you very Scrutinizer for the help. Code...
Thank you very Scrutinizer for the help.
Code works for me.

It would be highly helpful if you can explain a bit of what is done.

Thanks
797
Posted By shellscripting
data in file 2 will be compared with column 1 of...
data in file 2 will be compared with column 1 of file 1, and if it matches, data of file3 will be replaced with the data, in column 2 of file1

I hope i am able to make some sense now.
797
Posted By shellscripting
Thank you Bharat for the quick reply. Let me...
Thank you Bharat for the quick reply.

Let me frame the question once more with a new dataset with the expected output

Hello everybody,

I need a help on this.
I have a 3 files

file 1
a ...
797
Posted By shellscripting
Replacement code
Hello everybody,

I am new to this forum and i need some input for the below issue


I have 3 files

file 1

a mumbai 32344
m bangalore 4211
x delhi 4345
e chennai ...
Showing results 1 to 15 of 15

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