27 lines
702 B
Text
Executable file
27 lines
702 B
Text
Executable file
#!/bin/python
|
|
|
|
import os
|
|
from os import listdir
|
|
from os.path import isfile, join
|
|
|
|
userdir = os.path.expanduser("~")
|
|
nomaddir = userdir+"/.nomadnetwork"
|
|
|
|
|
|
print("> PRINTERS")
|
|
printers = [f for f in listdir(nomaddir+'/storage/plugins/print3d/printers')]
|
|
if len(printers) == 0:
|
|
print("no printer config files available :(")
|
|
print("add printer config files to: ~/.nomadnetwork/storage/plugins/print3d/printers/")
|
|
|
|
else:
|
|
for p in printers:
|
|
print("""`<^|printer|{p}`>`b {p}""".format(p=p))
|
|
|
|
print("\n")
|
|
print("> FILE")
|
|
print("print file URL: `B444`<url`>`b")
|
|
print("\n")
|
|
print("> SUBMIT")
|
|
print("""`!`[>SUBMIT<`:/page/print3d/submit_remote.mu`printer|url|nomad_dir={ndir}]`!""".format(ndir=nomaddir))
|
|
|