Skip to content

Commit db4318a

Browse files
committed
save
1 parent 011b01f commit db4318a

File tree

3 files changed

+36
-0
lines changed

3 files changed

+36
-0
lines changed

.idea/inspectionProfiles/profiles_settings.xml

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/modules.xml

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Test.py

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
#!/usr/bin/python
2+
import mysql.connector
3+
import os
4+
import subprocess
5+
import sys
6+
7+
#subprocess.call("date")
8+
9+
f = os.popen('date')
10+
now = f.read()
11+
print ("Today is ", now)
12+
##subprocess.call(["cat", "/etc/resolv.conf"])
13+
14+
cmdping = "ping -c2 peshal.com.np"
15+
p = subprocess.Popen(cmdping, shell=True, stderr=subprocess.PIPE)
16+
while True:
17+
out = p.stderr.read(1)
18+
if out == '' and p.poll() != None:
19+
break
20+
if out != '':
21+
sys.stdout.write(out)
22+
sys.stdout.flush()

0 commit comments

Comments
 (0)