help required in program


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting help required in program
# 15  
Old 11-06-2011
Please see below the command and its output.

Code:
[root@abcd xyz]# find . -perm 777 -type d -exec find {} -name "*.php" \;
./u24/sdfd/bash11.php
./u24/sdfd/bash11.php

# 16  
Old 11-06-2011
See this... Smilie... I have given 777 permission to directory a and b...
Code:
root@bt:/tmp/test# find . -perm 777 -type d -exec find {} -name "*.c" \;
./a/aa.c
./a/a.c
./b/bb.c
./b/b.c

which is your OS?...
# 17  
Old 11-06-2011
i have 777 permission to directory and 644 to file


Code:
[root@abcd xyz]# find . -perm 777 -type d -exec find {} -name "*.php" \;
./u24/sdfd/bash11.php
./u24/sdfd/bash11.php

[root@abcd xyz]# ls -l ./u24/sdfd/bash11.php

-rw-r--r-- 1 root root 0 Nov  6  2011 ./u24/sdfd/bash11.php

i am using fedora 15.
# 18  
Old 11-06-2011
can you paste the output of
Code:
cd /u24/sdfd/
ls -lrt

--ahamed
# 19  
Old 11-06-2011
here it is

Code:
# ls -ltr |more
total 106516

-rwxr-xr-x 1 root       root     60910 Oct 22 18:31 1278.jpg
-rwxr-xr-x 1 root       root     83672 Oct 22 18:31 12782115.jpg
-rwxr-xr-x 1 root       root     79711 Oct 22 18:31 1278220.jpg
-rw-r--r-- 1 root       root    167950 Oct 22 18:31 1291317.jpg
-rw-r--r-- 1 root       root     24878 Oct 22 18:31 1318434.jpg

# 20  
Old 11-06-2011
Sorry pal... may be experts here can help you out... good luck...

--ahamed
# 21  
Old 11-06-2011
Ok thanks ahmed brother, i am waiting for others to see this post and give me right direction.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Perl program get a response before the program quits

I created a program, so a kid can practice there math on it. It dispenses varies math problems and the kid must input an answer. I also want it to grade the work they have done, but I can't find the best place for it to print out the grade. I have: if ( $response =~ m/^/ ) { $user_wants_to_quit... (1 Reply)
Discussion started by: germany1517
1 Replies

2. Homework & Coursework Questions

Calling compiled C program with Perl program

Long story short: I'm working inside of a Unix SSH under a bash shell. I have to code a C program that generates a random number. Then I have to call the compiled C program with a Perl program to run the C program 20 times and put all the generated random #s into a text file, then print that text... (1 Reply)
Discussion started by: jdkirby
1 Replies

3. Programming

Python program faster than C++ program.

I wrote a simple program that generates a random word 10,000,000 times. I wrote it in python, then in C++ and compared the two completion times. The python script was faster! Is that normal? Why would the python script be faster? I was under the impression that C++ was faster. What are some of... (2 Replies)
Discussion started by: cbreiny
2 Replies

4. Programming

Why is required to leave an empty line at the end of a C program?

I know it looks like a stupid question, but i really wanna know the reason. Actually, i think it's because the c compiler will detect it as the end of file "EOF" of the program, but, am i wrong? because it compiles it anyway, but keep showing warnings like "no new line at the end of file". I... (8 Replies)
Discussion started by: semash!
8 Replies

5. Shell Programming and Scripting

simple program help required

The circumfrence of a circle is #!/usr/bin/perl print 2 * 3.141592654 * 12.50 \n"; # pi= 3.141592654 # r= 12.50 I need a simple program showing me all the steps..to modify the above to prompt for and accept a radius from the person running the... (3 Replies)
Discussion started by: Q2wert
3 Replies

6. Shell Programming and Scripting

Getting required fields from a test file in required fromat in unix

My data is something like shown below. date1 date2 aaa bbbb ccccc date3 date4 dddd eeeeeee ffffffffff ggggg hh I want the output like this date1date2 aaa eeeeee I serached in the forum but didn't find the exact matching solution. Please help. (7 Replies)
Discussion started by: rdhanek
7 Replies

7. UNIX for Dummies Questions & Answers

Script to open program and send/execute command in program

Hi, i want to write a script that executes a program (exec?) . this program then requires a filename as input. how do i give it this input in the script so the program will be complete run and close by the script. e.g. exec prog.exe program then asks for filename "enter filename:"... (1 Reply)
Discussion started by: tuathan
1 Replies

8. UNIX for Dummies Questions & Answers

Shell program:Help required on file formating

I have two files file1 and file2 as shown below: file1: name nameabc bcd nameabcdefg file2: age age1111 age2345 age6743 I have pasted one file on the other with the delimiter "|" and the resulttant file is: name|age nameabc|age1111 bcd|age2345 nameabcdefg|age6743 (6 Replies)
Discussion started by: udiptya
6 Replies

9. Shell Programming and Scripting

Very Urgent help required in Shell Program

How do I Ftp, and rename multiple files in one unix script. I have to send it with .tmp extension , then rename it to .txt after FTP is done . I need to do a Mass rename of more than 1 file in a shell script , Urgent help required. (1 Reply)
Discussion started by: Suppandi
1 Replies

10. Programming

A C program required for portability

I have to solve a problem for my wife who is engaged in Research in Breast Cancer. 1. She has frequently to search a long single line of alphabetic characters (lower case) for an exact match of a string. e.g.... (1 Reply)
Discussion started by: nmsinghe
1 Replies
Login or Register to Ask a Question