Command to view files in Directory


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Command to view files in Directory
# 1  
Old 09-23-2009
Command to view files in Directory

Hi,

Can u provide me the command to view files in a directory.Urgent Pls.

-Vamsi
# 2  
Old 09-23-2009
Code:
NAME
       ls - list directory contents

SYNOPSIS
       ls [OPTION]... [FILE]...

DESCRIPTION
       List  information  about  the  FILEs (the current directory by default).  Sort entries alphabetically if
       none of -cftuSUX nor --sort.

       Mandatory arguments to long options are mandatory for short options too.

       -a, --all
              do not hide entries starting with .

...more not included here...

# 3  
Old 09-23-2009
Hi I have a directory named Labtest1 and inside that I have 4 subdirectories named group_a, group_b, group_c and roup_d. I have created 4 files namely questions1, questions2, questions3 and questions4. I have also entered some text in these files and saved. Now i have copied the questions1 file to group_a using the command

cp questions1 ../group_a

will the content inside the questions1 file be now available in group_a?
If so how should i view the same? I wanna see if my directory group_a has the questions1 and its contents.
Please help
# 4  
Old 09-23-2009
ls (that is lower case LS) is still the answer. What happens when you try what you propose?
# 5  
Old 09-23-2009
I have used ls -lg.Now it works :-).Thanks

Thanks
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Cd to another directory to view a log file

Hi guys Today I have been working on a script to execute to view entries within a log file. I have successfully got the command I want to execute within the script itself. I want to view the last 5 entries within a log file and see just the last numbers. The file name would change depending... (5 Replies)
Discussion started by: simpsa27
5 Replies

2. UNIX for Advanced & Expert Users

Using vim to view the contents of a directory

When I use this command: vi /home/bob/.vimI expect to see. " ============================================================================ " Netrw Directory Listing (netrw v149) " /home/bob/.vim " Sorted by name " Sort sequence:... (4 Replies)
Discussion started by: cokedude
4 Replies

3. Solaris

Command to list or view the files in .pkg (solaris) and how to extract without installing

In Linux for .rpm we can list or view the files using the command rpm -qpl <file.rpm> and to extract, the command is rpm2cpio <file.rpm> | cpio -idvh I would like to know the commands which has same functionality as above for solaris ( .pkg) Thanks in Advance (5 Replies)
Discussion started by: frintocf
5 Replies

4. Shell Programming and Scripting

Apply 'awk' to all files in a directory or individual files from a command line

Hi All, I am using the awk command to replace ',' by '\t' (tabs) in a csv file. I would like to apply this to all .csv files in a directory and create .txt files with the tabs. How would I do this in a script? I have the following script called "csvtabs": awk 'BEGIN { FS... (4 Replies)
Discussion started by: ScKaSx
4 Replies

5. Shell Programming and Scripting

Command to view files in Directory

Hi, Can you help me in providing me a command to view all files present in a directory. Thanks a lot. -Vamsi (1 Reply)
Discussion started by: VamsiVasili
1 Replies

6. UNIX for Dummies Questions & Answers

Unable to view files in a particular directory under /opt

Hi Everybody, I am Unable to view files in a particular directory under /opt. But, when I reboot the server, I am able to view the files.. Its happening daily. Do u 've n e answers/suggestions. Kindly help.. :eek: (1 Reply)
Discussion started by: its.simron
1 Replies

7. Linux

Unable to view files in a particular directory under /opt

Hi Everybody, I am Unable to view files in a particular directory under /opt. But, when I reboot the server, I am able to view the files.. Its happening daily. Do u 've n e answers/suggestions. Kindly help.. :confused: (1 Reply)
Discussion started by: its.simron
1 Replies

8. UNIX for Advanced & Expert Users

Can't view directory content - SUNOS

Hi, The app I support has a directory used for debugg files. It has just come to light there are no files in there. Or is there :confused: Changing into the directory and completing an ls -lta you get no files. This is truly not right for the application. If I go up one directory the... (2 Replies)
Discussion started by: nhatch
2 Replies

9. UNIX for Dummies Questions & Answers

view user permissions on directory

Hello, and thanks in advance- I just installled red hat and pinged my machine and got a reply. When i go to http://myIPhere from my other machine it asks for a password and username. It doesnt accepts the username and passwords I use to login to my linux box. I therefore think its a premissions... (1 Reply)
Discussion started by: 99miles
1 Replies

10. UNIX for Dummies Questions & Answers

Unable to view contents of a directory

Hi, first post here be gentle. Very new to Unix. Using HP-UX 10.20 I CD into a remote directory on one machine $ cd /net/remote hostname yet when I do an ll in this directory none of the contents appear. It just is empty. when I do the same command from another machine, $ cd... (13 Replies)
Discussion started by: maddave
13 Replies
Login or Register to Ask a Question