Python Drehbuch Superuser
sudo chown root:root /usr/bin/speech-test.py
sudo chmod 4755 /usr/bin/speech-test.py
Hurt Hamerkop
sudo chown root:root /usr/bin/speech-test.py
sudo chmod 4755 /usr/bin/speech-test.py
#!/usr/bin/env python
import sys
import pyttsx
def main():
print 'running speech-text.py...'
engine = pyttsx.init()
str = "Hi..."
if len(sys.argv) > 1:
str = sys.argv[1]
engine.say(str)
engine.runAndWait()
if __name__ == '__main__':
main()