displaying directory in html


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers displaying directory in html
# 8  
Old 10-31-2003
im trying to test csh scripts on windows using cygwin, but its saying that

bash: csh: command not found.


How do i get cygwin working so that i can use it like a unix shell?
# 9  
Old 10-31-2003
Im still trying to do the csh script that displays the directory in html

This is what ive got so far: (cant test it due to my cygwin not doing what i want it to)

#!/bin/csh -f

ls


This should list the files in the current directory, but what do i write to make it output in html to a html file?

A working example would help me.
# 10  
Old 11-03-2003
I don't use csh, but this might work...
Code:
ls | awk 'BEGIN{print "<HTML><HEAD></HEAD><BODY><PRE>"}1;END{print "</PRE></BODY></HTML>"}' >dirlist.html

 
Login or Register to Ask a Question

Previous Thread | Next Thread

8 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Directory not displaying (strange)

Hi All. I am facing a strange scenario (c13:pq1:/pq1/buffer>) ll ../dataCS/* ls: cannot access ../dataCS: No such file or directory (c13:pq1:/pq1/buffer>) cd ../dataCS (c13:pq1:/pq1/dataCS>) ll * -rw-rw-r-- 1 pq1 pq10 Mar 1 13:43 test (c13:pq1:/pq1/dataCS>) ll ../dataCS/* -rw-rw-r--... (3 Replies)
Discussion started by: arunkumar_mca
3 Replies

2. Shell Programming and Scripting

Parse multiple html files in directory

I have downloaded source code for 97 files using: wget -x -i link.txt then run a rename loop: for file in * do mv $file $file.txt done to keep the html tags but make the file a text that can be parsed. In each of the 97 txt files the gene # is variable, but the gene is associated... (15 Replies)
Discussion started by: cmccabe
15 Replies

3. Shell Programming and Scripting

Need script to remove millions of tmp files in /html/cache/ directory

Hello, I just saw that on my vps (centOS) my oscommerce with a seo script has created millions of tmp files inside the /html/cache/ directory. I would need to remove all those files (millions), I tried via shell but the vps loads goes to very high and it hangs, is there some way to do a... (7 Replies)
Discussion started by: andymc1
7 Replies

4. UNIX for Dummies Questions & Answers

Displaying the current working directory in prompt

Hi, I want that the prompt that is being displayed (i.e $ sign) should display always the current directory I am working in instead of that $ sign example: as we use PS1=patric and the prompt changes from $ to patric OR if we write the command PS1=`pwd` it will display the current... (5 Replies)
Discussion started by: premjotsingh
5 Replies

5. Shell Programming and Scripting

Displaying file in html loses format

I have a bash script to output the contents of a text file to html. Everything outputs ok, except this: ###################################################################### # # # PRIVATE/PROPRIETARY # # # # ANY UNAUTHORIZED ACCESS TO, OR MISUSE OF ABC COMPANY # # SYSTEMS OR DATA MAY... (2 Replies)
Discussion started by: numele
2 Replies

6. Web Development

html link to images in /tmp directory

Because of permission issues, I need to link to images in my web page which are stored in /tmp which of course is located in the root directory but my actual html page is much further down in another directory. I thought the the following code should work, but the image comes up as a broken link:... (2 Replies)
Discussion started by: Solerous
2 Replies

7. Shell Programming and Scripting

displaying 3 directory listings in 3 separate columns.

i having problems figuring out how to 'read' in 3 different directory listings and then display them on the screen into 3 separate columns. i thought i could use a 'for' loop to grab each directory and then assign a unique variable to each line 'read' in. of course, as you experts all know,... (16 Replies)
Discussion started by: mjays
16 Replies

8. UNIX for Dummies Questions & Answers

Displaying files in a directory

Dear Experts, I am new to UNIX and I have a script below and in this test case I am reading the names of the files in the present directory into a variable and then looping through each file name and displaying the name back to the screen. The problem I have is although there are 5 files in the... (4 Replies)
Discussion started by: markjohnlowe
4 Replies
Login or Register to Ask a Question