Changed output to columns
This commit is contained in:
parent
fe2055e89d
commit
c93920f4c5
10
app.py
10
app.py
@ -1,5 +1,6 @@
|
|||||||
#!/usr/bin/python3
|
#!/usr/bin/python3
|
||||||
import sys
|
import sys
|
||||||
|
import cmd
|
||||||
|
|
||||||
sys.path.append("/opt/homebrew/lib/python3.11/site-packages")
|
sys.path.append("/opt/homebrew/lib/python3.11/site-packages")
|
||||||
import sqlite3
|
import sqlite3
|
||||||
@ -37,14 +38,11 @@ def parse():
|
|||||||
final_list = the_list.sort() # sorts normally by alphabetical order
|
final_list = the_list.sort() # sorts normally by alphabetical order
|
||||||
the_list = sorted(the_list, key=len, reverse=False)
|
the_list = sorted(the_list, key=len, reverse=False)
|
||||||
if len(the_list) > 0:
|
if len(the_list) > 0:
|
||||||
print(*the_list, sep="\n")
|
out = cmd.Cmd()
|
||||||
|
out.columnize(the_list, displaywidth=80)
|
||||||
else:
|
else:
|
||||||
print("No expired domains with the length citeria you wanted!")
|
print("No expired domains with the length citeria you wanted!")
|
||||||
|
|
||||||
|
|
||||||
def main():
|
|
||||||
parse()
|
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
main()
|
parse()
|
||||||
|
Loading…
Reference in New Issue
Block a user