Find the answer to your Linux question:
Results 1 to 2 of 2
Hi, I want to write a script that I can invoke to zip up files in a particular directory. The script would be rather simple. I basically need to make ...
  1. #1
    Just Joined!
    Join Date
    Jul 2004
    Posts
    94

    Need help with a password script

    Hi,

    I want to write a script that I can invoke to zip up files in a particular directory. The script would be rather simple. I basically need to make the following system call:

    $ zip -e MyArchive.zip *

    The problem is that when I make the call from the command line, I am then prompted for a password, and then again for the verification of the password. How can I write a script that will supply the passwords to the shell at the right time?

    Thanks a lot for your help.

    *****

    Sorry, a quick addition. I am using Bash in Fedora Core 6.

  2. #2
    Linux Guru anomie's Avatar
    Join Date
    Mar 2005
    Location
    Texas
    Posts
    1,692
    I don't know of a way to script this using zip.

    Are you interested in using gnupg for this? The zip program provides weak encryption anyway.

Posting Permissions

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