Changed working dir for conf file :D
This commit is contained in:
parent
fca78832d8
commit
040e52d060
15
HTTPy.py
15
HTTPy.py
@ -22,6 +22,7 @@ pingOn = "p"
|
|||||||
whoOn = "W"
|
whoOn = "W"
|
||||||
phrases = ["ping", "whois", "quit", "clear", "help", "nameserver"]
|
phrases = ["ping", "whois", "quit", "clear", "help", "nameserver"]
|
||||||
|
|
||||||
|
|
||||||
def openFile(filename):
|
def openFile(filename):
|
||||||
try:
|
try:
|
||||||
myfile = open(filename)
|
myfile = open(filename)
|
||||||
@ -54,14 +55,9 @@ def splitLines(confline):
|
|||||||
|
|
||||||
testFile = openFile('.httpy')
|
testFile = openFile('.httpy')
|
||||||
test = testFile.read()
|
test = testFile.read()
|
||||||
test1, test2 = splitLines(test)
|
|
||||||
|
|
||||||
for t1 in test1:
|
|
||||||
print "dig " + t1
|
|
||||||
|
|
||||||
for t2 in test2:
|
|
||||||
print "dig " + t2
|
|
||||||
closeFile(testFile)
|
closeFile(testFile)
|
||||||
|
rec2check, sub2check = splitLines(test)
|
||||||
|
|
||||||
|
|
||||||
def printHelp():
|
def printHelp():
|
||||||
print bcolors.BLUE + "========================================================"
|
print bcolors.BLUE + "========================================================"
|
||||||
@ -223,6 +219,11 @@ def getInput():
|
|||||||
running = 0
|
running = 0
|
||||||
|
|
||||||
#Main Loop
|
#Main Loop
|
||||||
|
testFile = openFile('~/.httpy')
|
||||||
|
test = testFile.read()
|
||||||
|
closeFile(testFile)
|
||||||
|
rec2check, sub2check = splitLines(test)
|
||||||
|
|
||||||
while running == 1:
|
while running == 1:
|
||||||
getInput()
|
getInput()
|
||||||
if checkPhrase(inInput) == 1 or len(partDomain) == 1:
|
if checkPhrase(inInput) == 1 or len(partDomain) == 1:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user