Commit 0e5c6695 authored by M33's avatar M33 💬
Browse files

Merge branch 'alrs/radiobot-py-alrs-silence-hashtag-spam' into 'master'

deal with hashtags vs spam equilibrium

See merge request !2
parents d59d3074 3e8c3552
......@@ -18,16 +18,24 @@ posting_delay=1
# Solar image
solar_pics=["http://www.hamqsl.com/solarmap.php", "http://www.hamqsl.com/solar101vhfper.php", "https://www.sws.bom.gov.au/Images/HF%20Systems/Global%20HF/HAP%20Charts/New%20York%20LDOCF.gif"]
toot_body="Solar data from http://www.hamqsl.com https://www.sws.bom.gov.au/"
toot_body="Solar data from http://www.hamqsl.com https://www.sws.bom.gov.au"
hashtags="#SolarData #Propagation #AmateurRadio #CBradio"
# Program logic below this line
if len(sys.argv) < 2:
print("Usage: radiobot.py [config file]")
if len(sys.argv) < 3:
print("Usage: radiobot.py [config file] [--with-hashtags OR --without-hashtags]")
print("All arguments are mandatory")
sys.exit(1)
auth_file=sys.argv[1]
auth_session=auth_file+'.secret'
wiwo_hashtags=sys.argv[2]
# Will we mark this toot with hashtages or not ?
# Hastag are usefull for search results in current (3.X) Mastodon
if wiwo_hashtags == "--with-hashtags":
toot_body = toot_body + " " + hashtags
# Returns the parameter from the specified file
def get_config(parameter, file_path):
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment