05-14-2009
One line shell command to retrieve subdirectory names
Here is a brute force way to retrieve sub-directories in shell script:
ls -R | grep ":" | sed "s/://"
Any files named with a colon ":" will cause a false positive.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi!
I'd like to list my files recursively BUT:
I want them in this format, so that I can use them as options for commands like ftp->put or del
./directory1/file1.tar
./directory1/file2.tar
./directory1/file3.tar
./directory2/file1.tar
./directory2/file2.tar
./directory2/file3.tar... (9 Replies)
Discussion started by: roberthawke
9 Replies
2. Shell Programming and Scripting
Hi,
I would need to go through all the subdirectories, find each file and would need to check them out(using clearcase, which I know).
But could you please help me how to find all the files under all subdirectories.. there could be multiple directories and subdirs...
Sas (3 Replies)
Discussion started by: shajiasalim
3 Replies
3. UNIX for Dummies Questions & Answers
I'm trying to concatenate files in subdirectories with the same folder name. Say concatenate all the files in the 'current' subdirectories in 'Literature' parent directory.
Literature/USA/current/
Literature/Europe/current/
Can anyone help with it? Thanks a lot! (2 Replies)
Discussion started by: joyce007
2 Replies
4. UNIX for Advanced & Expert Users
I'm trying to concatenate files in subdirectories with the same folder name. Say concatenate all the files in the 'current' subdirectories in 'Literature' parent directory.
Literature/USA/current/
Literature/Europe/current/
Can anyone help with it? Thanks a lot! (2 Replies)
Discussion started by: joyce007
2 Replies
5. Shell Programming and Scripting
Hi,
I have a very big directory structure that consists of many sub-directories inside.There are around 50 ".gz" files under this dir structure.
I want to copy all the gz files alone to a seperate location.
Plz help me. (2 Replies)
Discussion started by: villain41
2 Replies
6. Shell Programming and Scripting
Dear all,
I have a dir structure like
main_dir
At_nn Ag_js Nf_hc ....
mcd32 mgd43... mcd32 mgd43... mcd32 mgd43...
and each subdir (e.g. mcd32, mgd43) contains files.
Now, i... (15 Replies)
Discussion started by: yogeshkumkar
15 Replies
7. Shell Programming and Scripting
Hi all,
how to recursively search for a list of keywords in a given directory??
for example:
suppose i have kept all the keywords in a file called "procnamelist" (in separate line)
and i have to search recursively in a directory called "target/dir"
if i am not doing recursive search then... (4 Replies)
Discussion started by: neelmani
4 Replies
8. UNIX for Advanced & Expert Users
Hello,
I wanted to
list all files in subdirectories which are modifiled recently. need to display all files with full details like hpw it display with ls -l ( date, size,..)
Thanks
Bala (3 Replies)
Discussion started by: balareddy
3 Replies
9. UNIX for Dummies Questions & Answers
Hi, I'm currently trying to print the names of all the .txt files in the subdirectories that contain the string I'm searching.
I tried with this code, but it seems that it searches for the names that matches the string instead of searching for the string in the individual files and printing the... (2 Replies)
Discussion started by: nuclearpenguin
2 Replies
10. UNIX for Beginners Questions & Answers
Hi Team,
Am a newbie to Unix. As I would like to see the Server Name,Owner Name ( not numeric form), Group Name ( not numeric ID), ROOT path.
I would like to send this list as an attachment to my personal mail. Can any one please help me out to to resolve this .
Here is the sample result... (6 Replies)
Discussion started by: vasuvv
6 Replies
LEARN ABOUT DEBIAN
jocamlprof
JOCAMLPROF(1) General Commands Manual JOCAMLPROF(1)
NAME
jocamlprof - The JoCaml profiler
SYNOPSIS
jocamlprof [ -f dump-file ] [ -F text ] filename ...
DESCRIPTION
The jocamlprof command prints execution counts gathered during the execution of a Objective Caml program instrumented with jocamlcp(1).
It produces a source listing of the program modules given as arguments where execution counts have been inserted as comments. For instance,
jocamlprof foo.ml
prints the source code for the foo module, with comments indicating how many times the functions in this module have been called. Natu-
rally, this information is accurate only if the source file has not been modified since the profiling execution took place.
OPTIONS
-f dumpfile
Specifies an alternate dump file of profiling information.
-F string
Specifies an additional string to be output with profiling information. By default, jocamlprof(1) will annotate programs with com-
ments of the form (* n *) where n is the counter value for a profiling point. With option -F s the annotation will be (* sn *)
-impl filename
Compile the file filename as an implementation file, even if its extension is not .ml.
-intf filename
Compile the file filename as an interface file, even if its extension is not .mli.
-version
Print the version number of jocamlprof and exit.
-help or --help
Display a short usage summary and exit.
SEE ALSO
jocamlcp(1).
The Objective Caml user's manual, chapter "Profiling".
JOCAMLPROF(1)