LinuxQuestions.org
Help answer threads with 0 replies.
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 04-18-2011, 02:22 PM   #1
chi99
LQ Newbie
 
Registered: Apr 2011
Posts: 2

Rep: Reputation: 0
Smile read in parameter and make it as keyboard output


Hello all,

I am trying to write a script (especially C-shell) to execute a fortran code that reads in parameters from keyboard typing. I will have to process this .F code for many times with the parameters the same for all my data files, therefore, I don't have to type in everytime I execute the .F code.
But I don't know what is the command in c shell to read in a text files that contains all the parameters I want and can make the shell read in appropriately to feed the .F code. I will be really appreciate if people here can help me deal with the problem I am facing now.

thanks,
TC
 
Old 04-18-2011, 02:57 PM   #2
Thor_2.0
Senior Member
 
Registered: Nov 2007
Location: Somewhere on my hard drive...
Distribution: Manjaro
Posts: 2,210
Blog Entries: 23

Rep: Reputation: 279Reputation: 279Reputation: 279
Hmm, how about this... (maybe, dont kill me, please?)

Quote:
yourProgram.f < file_with_command
where file_with_command is a plain text file with the required commands...

Hope this helped;

Thor
 
1 members found this post helpful.
Old 04-18-2011, 11:28 PM   #3
chi99
LQ Newbie
 
Registered: Apr 2011
Posts: 2

Original Poster
Rep: Reputation: 0
Hi Thor,

Thanks for your reply. It is really great information!
It worked! thank you.
 
Old 04-19-2011, 09:49 AM   #4
Thor_2.0
Senior Member
 
Registered: Nov 2007
Location: Somewhere on my hard drive...
Distribution: Manjaro
Posts: 2,210
Blog Entries: 23

Rep: Reputation: 279Reputation: 279Reputation: 279
You're welcome!
 
  


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
How to pipe output to another command parameter? FireRaven Linux - Newbie 2 07-20-2009 07:44 AM
need help to make alpha (shape parameter) in mrtg dencar_girl87 Linux - Networking 2 06-23-2008 11:44 PM
cant make 'read' work with grepped output johnfman Programming 6 11-12-2007 08:05 AM
read config file parameter values sharathkv25 Programming 2 02-15-2007 01:55 AM
xterm will not produce output with -lf parameter jarobman Linux - General 2 03-06-2005 02:12 AM


All times are GMT -5. The time now is 05:52 PM.

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