10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
If I have a file like the following
abc.1
abc
abc_1
abc..1
abc*1
abc@1
abc def ghr
def......
ddef 5466 def ed
def** 123445
I`m trying to find exact words from the list
abc
def (4 Replies)
Discussion started by: ritakadm
4 Replies
2. UNIX for Dummies Questions & Answers
Hi
I have a file which has sequences which look like this
>String1
aqwertrtrytytyuuijhgddfghhhghhgjhjhhsswekrkmygppdslxmvbnhkwqalldrtjbllnlnlnnnvc
>String2
qwwerrtyuiopasdfghjmnbvfklzxerbvcwghjjkoowwqerrtggbddqsdfgaqwcxzakjtyugfsdefrtgyhujiknbbbbcdcdcxsxsx zxzxcvcfcdcg
>String3... (5 Replies)
Discussion started by: sa@@
5 Replies
3. Shell Programming and Scripting
Hi
I have a file and need to extract lines starting with "grep ^"
I tried with quotes single/double before/after but no luck.
suggestion pls, thanks! (2 Replies)
Discussion started by: magnus29
2 Replies
4. UNIX for Dummies Questions & Answers
Hi All,
Could you please help to resolve my following issues:
Problem Description:
Suppose my user name is "MI90".
i.e. $USER = MI90
when i run below command, i get all the processes running on the system containing name MQ.
ps -ef | grep MQ
But sometimes it lists... (8 Replies)
Discussion started by: KDMishra
8 Replies
5. UNIX for Dummies Questions & Answers
Hello,
In my directory i have got a list of files like below
unix1a.csv
unix1b.csv
unix1c.csv
unix1d.csv
unix1y.csv
I have done ls -lrt unix1.csv, how can i get my unix1y.csv also get listed along with this.. (5 Replies)
Discussion started by: sathyaonnuix
5 Replies
6. Shell Programming and Scripting
In the kornshell you can get the length of a string with
$ x=abc
$ print ${#x}
3
If the current locale is a multibyte locale, like de_AT.UTF-8, you get the length of the string in bytes, not characters:
$ x=für
$ print ${#x}
4
Is there an easy way to get the length of a... (8 Replies)
Discussion started by: hergp
8 Replies
7. UNIX for Dummies Questions & Answers
This is what I have to do:
Display the full file name (including the full path) and file size of all files whose name (excluding the path) is exactly 3 characters long.
This is the code I have:
find / -printf "Name: %f Path: %h Size: %s (bytes)\n" 2>/dev/null | grep -E "Name: .{3,} Path" |... (7 Replies)
Discussion started by: Joesgrrrl
7 Replies
8. UNIX for Dummies Questions & Answers
hello all,
iam new to shell scripting.I have searched the forum and could'nd find a close enough answer and hence this post:
I want to list all the file names whose names don't start as abc.
For example if my folder constains files with names: abc123.txt,erdf23.rdf,ed45r.fmb
i want a... (13 Replies)
Discussion started by: valluvan
13 Replies
9. UNIX for Dummies Questions & Answers
Does any one know how to get a recursive directory listing in long format (showing owner, group, permission etc) without listing the files contained in the directories.
The following command also shows the files but I only want to see the directories.
ls -lrtR * (4 Replies)
Discussion started by: psingh
4 Replies
10. UNIX for Dummies Questions & Answers
I want to grep from a file an exact character match.
I tried grep -c "$a $b" $file
where a=6 and b=2
the problem is that I get: 6 2 and 6 20
I just need a count of the occurrence.
I'm using the Bourne shell.
I've also tried grep -c '$a $b' $file;
not sure how to do this - any suggestions? (3 Replies)
Discussion started by: jrdnoland1
3 Replies