Find the answer to your Linux question:
Results 1 to 2 of 2
Hi Friends, I want a script(batch or ant) that should run on linux and it should ask the user to input a value and that value should be stored in ...
  1. #1
    Just Joined!
    Join Date
    Jul 2005
    Posts
    11

    Very simple script needed

    Hi Friends,
    I want a script(batch or ant) that should run on linux and it should ask the user to input a value and that value should be stored in a text file.

    Does anyone know how to accomplish this...would appreciate that...any links??

    Thanks

  2. #2
    Trusted Penguin Cabhan's Avatar
    Join Date
    Jan 2005
    Location
    Seattle, WA, USA
    Posts
    3,230
    Batch or Ant? Firstly, Batch is MS-DOS scripting, and is unique to Windows. Ant, are you referring to the Java-installation-doohickey? If so, not sure what you mean...

    Are you familiar at all with the Bash shell? The command to print something to the screen is 'echo', and to read input is 'read'. You can then use I/O redirection to echo to a file.

    Here is a basic guide to Bash scripting:
    http://tldp.org/LDP/Bash-Beginners-G...ers-Guide.html
    DISTRO=Arch
    Registered Linux User #388732

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...