+# DONT - flatpak hates symlinks
+def link(c):
+ # c.run(f"ls -al {link_to}")
+ if os.path.isdir(link_to):
+ print("Moving existing files...")
+ c.run(f"mv {link_to} {easy_dir}")
+ if not os.path.isdir(easy_dir):
+ raise ValueError(f"{easy_dir} not found.")
+ if os.path.exists(link_to):
+ print(f"Doing nothing. {link_to} exists.")
+ if os.path.isdir(easy_dir) and not os.path.exists(link_to):
+ print("Linking...")
+ c.run(f"ln -s {easy_dir} {link_to}")
+ # c.run(f"ls -al {link_to}")
+
+@task
+def status(c):
+ print(f"+ Minetest data assumed to be at {link_to}")
+ print(f"+ Easy folder assumed to be {easy_dir}")
+ print(f"+ ls ---")
+ c.run(f"ls -ald {link_to} | grep minetest")
+
+
+@task
+def games(c):
+ print(f"+ List Games ---")
+ cmd = f"{run_mt} --gameid list"
+ c.run(cmd)
+
+@task
+def worlds(c):
+ print(f"+ List Worlds ---")
+ cmd = f"{run_mt} --gameid minetest --worldlist path"
+ c.run(cmd)
+