10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
hi,
how can i take the file names from a directory and store only the filenames in the file.
suppose i have a directory which contains the following files and subdirectories.
$ ls -ltr
total 16
-rw-rw-r-- 1 adm etc 4 Aug 6 20:37 s1.txt
-rw-rw-r-- 1 adm etc 4 Aug 6 20:37 s2.txt... (11 Replies)
Discussion started by: Little
11 Replies
2. Programming
How do I print all the file names in current directory in C? (6 Replies)
Discussion started by: omega666
6 Replies
3. Shell Programming and Scripting
I am writing a script below, which has 2 loops. The outer one reads file sufffixed with a number and inner inside which loop through each line of the file and display each space delimited string. However, i find that the string printed out in the inner loop includes not only the delimited string in... (2 Replies)
Discussion started by: martie
2 Replies
4. UNIX for Dummies Questions & Answers
Hi I have abc_ahb_one.v
abc_ahb_two.v
abc_ahb_three.v
........l
like this
-----upto
abc_ahb_ninety.v in some directory.
I need to change those file names to like below.
... (5 Replies)
Discussion started by: praneethk
5 Replies
5. Shell Programming and Scripting
I have many files similar to this one: AC41_AC85_86_AC128_129_MC171_173_SF_207_FMV.pdf.
I want a directory named AC41 and to put the file AC41_AC85_86_AC128_129_MC171_173_SF_207_FMV.pdf into the directory. Next, a directory named AC85 and put the file into it. Also, continue to cycle through... (1 Reply)
Discussion started by: ndnkyd
1 Replies
6. Shell Programming and Scripting
I have a directory of files and each file has a random 5 digit string at the beginning that needs to be removed. Plus, there are some files that will be identically named after the 5 digit string is removed and I want those eliminated or moved.
any ideas? (17 Replies)
Discussion started by: crumb
17 Replies
7. Programming
Hello All,
Background
========
I am creating a virtual appliance console for a software stack on VMware ESXi. I am using Centos 5.x as the Linux distro (Guest OS). I have created a ncurses based application that does the user authentication and present him with some basic controls to do basic... (2 Replies)
Discussion started by: ku@ntum
2 Replies
8. Shell Programming and Scripting
Hi All
I was wondering what is the most efficient way to find files in the current directory(that may contain 100,000's files), that meets a certain specified file type and of a certain age.
I have experimented with the find command in unix but it also searches all sub directories. I have... (2 Replies)
Discussion started by: kewong007
2 Replies
9. Shell Programming and Scripting
hi all,
I have a requirement where in i have to read all the filenames based on a pattern from a directory and concatenate all these file names and write it to another file.
i am using the following code to do this
var1=''
for filename in $_DIR/${FILE_NAME}*
do
if
if
then... (7 Replies)
Discussion started by: nvuradi
7 Replies
10. Shell Programming and Scripting
Hi,
i am very new to UNIX, i am trying to loop thru the files in a directory.
I got the filenames into a variable using
$files=`ls`
Here $files will contain
<filename1> <filename2> <filename3>
I want to get one filename at a time and append it to some some text.
forexample, ... (1 Reply)
Discussion started by: silas.john
1 Replies