Sponsored Content
Full Discussion: Ls For A Directory
Top Forums UNIX for Dummies Questions & Answers Ls For A Directory Post 13455 by jvaladez on Thursday 17th of January 2002 10:10:07 AM
Old 01-17-2002
Tools

Thanks to you all!

JVSmilie
 

9 More Discussions You Might Find Interesting

1. Solaris

Restricting SFTP user to a defined directory and home directory

Hi, I've created solaris user which has both FTP and SFTP Access. Using the "ftpaccess" configuration file options "guest-root" and "restricted-uid", i can restrict the user to a specific directory. But I'm unable to restrict the user when the user is logged in using SFTP. The aim is to... (1 Reply)
Discussion started by: sftpuser
1 Replies

2. Shell Programming and Scripting

Grepping file names, comparing them to a directory of files, and moving them into a new directory

got it figured out :) (1 Reply)
Discussion started by: sHockz
1 Replies

3. Shell Programming and Scripting

Change to directory and search some file in that directory in single command

I am trying to do the following task : export ENV=aaa export ENV_PATH=$(cd /apps | ls | grep $ENV) However, it's not working. What's the way to change to directory and search some file in that directory in single command Please help. (2 Replies)
Discussion started by: saurau
2 Replies

4. Shell Programming and Scripting

Catching the xml tag when only parent directory is known ..not the actual directory

Hi folks, I have an query that is let say i have to search in an xml file an tag that is <abcdef> now this xml file is at /opt/usr/local so one fastest way to achieve this is go to this location by cd /opt/usr/local and then do grep like this... grep -i abcdef but for this I must know the... (4 Replies)
Discussion started by: punpun66
4 Replies

5. Web Development

Directory index forbidden by Options directive error on specific directory with indexing disabled

I am seeing the following error appear numerous times in my Apache error log: I have my Apache config configured as below, so I would expect indexing not to occur on this directory as it falls under the parent /web directory. Strangely all the IP address, including this example, all... (5 Replies)
Discussion started by: crmpicco
5 Replies

6. UNIX for Dummies Questions & Answers

Extract directory name from the full directory path in UNIX using shell scripting

My input is as below : /splunk/scrubbed/rebate/IFIND.REBTE.WROC.txt /splunk/scrubbed/rebate/IFIND.REBTE.WROC.txt /splunk/scrubbed/loyal/IFIND.HELLO.WROC.txt /splunk/scrubbed/triumph/ifind.triumph.txt From the above input I want to extract the file names only . Basically I want to... (5 Replies)
Discussion started by: IshuGupta
5 Replies

7. Shell Programming and Scripting

Shell scripting-I need a script which should watch a directory for a file with specific directory

I need a script which should watch a directory for a file with specific directory. If it finds a file in directory, it should search for few specific keyword in the file. if the keyword exists, it should trim string from specific column. The file should be moved to another directory and the a... (8 Replies)
Discussion started by: akashdeepak
8 Replies

8. AIX

How to set owner and permission for files/directory in directory in this case?

Hi. My example: I have a filesystem /log. Everyday, log files are copied to /log. I'd like to set owner and permission for files and directories in /log like that chown -R log_adm /log/* chmod -R 544 /log/*It's OK, but just at that time. When a new log file or new directory is created in /log,... (8 Replies)
Discussion started by: bobochacha29
8 Replies

9. Shell Programming and Scripting

List files with date, create directory, move to the created directory

Hi all, i have a folder, with tons of files containing as following, on /my/folder/jobs/ some_name_2016-01-17-22-38-58_some name_0_0.zip.done some_name_2016-01-17-22-40-30_some name_0_0.zip.done some_name_2016-01-17-22-48-50_some name_0_0.zip.done and these can be lots of similar files,... (6 Replies)
Discussion started by: charli1
6 Replies
Directory::Scratch::Structured(3pm)			User Contributed Perl Documentation		       Directory::Scratch::Structured(3pm)

NAME
Directory::Scratch::Structured - creates temporary files and directories from a structured description SYNOPSIS
my %tree_structure = ( dir_1 => { subdir_1 =>{}, file_1 =>[], file_a => [], }, dir_2 => { subdir_2 => { file_22 =>[], file_2a =>[], }, file_2 =>[], file_a =>['12345'], file_b =>[], }, file_0 => [] , ) ; use Directory::Scratch::Structured qw(create_structured_tree) ; my $temporary_directory = create_structured_tree(%tree_structure) ; or use Directory::Scratch ; use Directory::Scratch::Structured qw(piggyback_directory_scratch) ; my $temporary_directory = Directory::Scratch->new; $temporary_directory->create_structured_tree(%tree_structure) ; DESCRIPTION
This module adds a create_structured_tree subroutine to the Directory::Scratch. DOCUMENTATION
I needed a subroutine to create a bunch of temporary directories and files while running tests. I used the excellent Directory::Scratch to implement such a functionality. I proposed the subroutine to the Directory::Scratch author but he preferred to implement a subroutine using an unstructured input data based on the fact that Directory::Scratch didn't use structured data. This is, IMHO, flawed design, though it may require slightly less typing. I proposed a hybrid solution to reduce the amount of subroutines and integrate the subroutine using structured input into Directory::Scratch but we didn't reach an agreement on the API. Instead I decided that I would piggyback on Directory::Scratch. You can access create_structured_tree through a subroutine or a method through a Directory::Scratch object. Whichever interface you choose, the argument to the create_structured_tree consists of tuples (hash entries). The key represents the name of the object to create in the directory. If the value is of type: ARRAY A file will be created, it's contents are the contents of the array (See Directory::Scratch) HASH A directory will be created. the element of the hash will also be , recursively, created OTHER The subroutine will croak. SUBROUTINES
/METHODS create_structured_tree use Directory::Scratch::Structured qw(create_structured_tree) ; my $temporary_directory = create_structured_tree(%tree_structure) ; my $base = $temporary_directory->base() ; Returns a default Directory::Scratch object. directory_scratch_create_structured_tree Adds create_structured_tree to Directory::Scratch when you Load Directory::Scratch::Structured with the piggyback_directory_scratch option. use Directory::Scratch ; use Directory::Scratch::Structured qw(piggyback_directory_scratch) ; my $temporary_directory = Directory::Scratch->new; $temporary_directory->create_structured_tree(%tree_structure) ; _create_structured_tree Used internally by both interfaces piggyback Used internally to piggyback Directory::Scratch. BUGS AND LIMITATIONS
None so far. AUTHOR
Khemir Nadim ibn Hamouda CPAN ID: NKH mailto:nadim@khemir.net LICENSE AND COPYRIGHT
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. SUPPORT
You can find documentation for this module with the perldoc command. perldoc Directory::Scratch::Structured You can also look for information at: o AnnoCPAN: Annotated CPAN documentation <http://annocpan.org/dist/Directory-Scratch-Structured> o RT: CPAN's request tracker Please report any bugs or feature requests to L <bug-directory-scratch-structured@rt.cpan.org>. We will be notified, and then you'll automatically be notified of progress on your bug as we make changes. o Search CPAN <http://search.cpan.org/dist/Directory-Scratch-Structured> SEE ALSO
Directory::Scratch perl v5.10.1 2010-03-22 Directory::Scratch::Structured(3pm)
All times are GMT -4. The time now is 07:42 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy