LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 06-30-2006, 09:12 AM   #1
yaru22
LQ Newbie
 
Registered: Aug 2005
Location: Toronto, Ontario, Canada
Distribution: Red Hat Linux 9.0
Posts: 1

Rep: Reputation: 0
does "find -exec" not recognize built-in command?


Hello.

I'm wondering if find -exec does not recognize shell built-in command.

For example, I was trying to execute the following command:

find ./ -name "*42005*" -exec setenv fgl `pwd`/{} \;

However, it says "find: setenv: No such file or directory"

Is there any way that I can execute those shell built-in command in "find" command?

Thanks in advance.

Regards,

Brian
 
Old 06-30-2006, 10:35 AM   #2
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian Squeeze
Posts: 5,743

Rep: Reputation: 299Reputation: 299Reputation: 299
Looks like an issue of command syntax. You have find looking for -exec, setenv, fgl, and `pwd`/{} \;. Find choked up.

Maybe a pipe to -exec is what you need.

find ./ -name "*42005*" | -exec setenv fgl `pwd`/{} \;

I'm guessing. I haven't tried it.

Last edited by bigrigdriver; 06-30-2006 at 10:36 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Shell Script: Find "Word" Run "Command" granatica Linux - Software 5 07-25-2007 07:42 AM
No UTMPX entry, You must EXEC "login" for the lowest "shell" ooihc Solaris / OpenSolaris 7 03-12-2007 02:09 PM
Can't exec "firefox 1.5", "prompts glibc detected" SPo2 Linux - General 1 06-04-2006 11:02 PM
Several "find -exec" and "find | xargs" questions thanhvn Programming 4 12-02-2005 01:04 PM
Doesnt recognize "start-pppoe" command? grazak Linux - Software 1 03-29-2005 11:43 AM


All times are GMT -5. The time now is 07:15 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration