A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2008-February/077245.html below:

[Python-Dev] getpass and stdin

[Python-Dev] getpass and stdin [Python-Dev] getpass and stdinLeif Walsh adlaiff6 at gmail.com
Tue Feb 26 19:20:09 CET 2008
On Tue, Feb 26, 2008 at 1:18 PM, Shaya Potter <spotter at cs.columbia.edu> wrote:
>  I want to run a program within a bash script, essentially daemonize a
>  program that doesn't have a daemon mode.
>
>  #!/bin/sh
>
>  echo "What Is Your Passsword: "
>  stty_orig=`stty -g`
>  stty -echo
>  read -r PASSWORD
>  stty $stty_orig
>
>  TIMEOUT=600
>
>  while [ 1 ]
>  do
>         echo $PASSWORD | program

So...why won't `program -p $PASSWORD' work here?

>         sleep $TIMEOUT
>  done

-- 
Cheers,
Leif
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4