Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

how to print using .sh file from python

import subprocess
import shlex
subprocess.call(shlex.split('./test.sh param1 param2'))

#with test.sh in the same folder:

#!/bin/sh
echo $1
echo $2
exit 0
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #print #file #python
ADD COMMENT
Topic
Name
4+9 =