How to call a shell script from python code?

This is how to How to call a shell script from python code


import subprocess
subprocess.call(['sh shell_script.sh arguments'])


or





import sys, os
os.system("sh shell_script.sh arguments")

Output Example

‎AWS Cloud Practitioner PRO
‎AWS Cloud Practitioner PRO
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot


‎AWS Cloud Practitioner PRO
‎AWS Cloud Practitioner PRO
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot
  • ‎AWS Cloud Practitioner PRO Screenshot