You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
34 lines
591 B
Python
34 lines
591 B
Python
3 months ago
|
import sys
|
||
|
import requests
|
||
|
import toml
|
||
|
import os
|
||
|
|
||
|
"""
|
||
|
|
||
|
Excel-Test:
|
||
|
|
||
|
=HYPERLINK("qgs://test")
|
||
|
|
||
|
"""
|
||
|
|
||
|
|
||
|
file_path = os.path.dirname(os.path.realpath(__file__))
|
||
|
|
||
|
with open(file_path + '\\config.toml', 'r') as f:
|
||
|
config = toml.load(f)
|
||
|
|
||
|
#print ('argument list', sys.argv)
|
||
|
call = sys.argv[1].replace("qgs://","")
|
||
|
|
||
|
#print ("Hello {}. How are you?".format(name))
|
||
|
print("Befehl:")
|
||
|
print("{}".format(call))
|
||
|
print("")
|
||
|
|
||
|
requests.get("http://{}:{}/{}".format(config['iface']['host'],config['iface']['port'],call))
|
||
|
|
||
|
if config['iface']['debug']:
|
||
|
os.system("pause")
|
||
|
|
||
|
|