Skip to content

Instantly share code, notes, and snippets.

@tOverney
Last active December 6, 2016 13:56
Show Gist options
  • Save tOverney/67698b511cdadbd58e9ee9f3cf38b07e to your computer and use it in GitHub Desktop.
Save tOverney/67698b511cdadbd58e9ee9f3cf38b07e to your computer and use it in GitHub Desktop.
from subprocess import Popen, PIPE
computerName = Popen(["scutil","--get","ComputerName"], stdout=PIPE).communicate()[0]
print "Hello " + computerName + ", how are you?"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment