Subir archivos a "/"

This commit is contained in:
nix 2025-03-24 12:50:09 +00:00
commit 7b81f7177d
2 changed files with 18 additions and 0 deletions

14
modulecli.py Normal file
View File

@ -0,0 +1,14 @@
import click
from picomc.cli.main import picomc_cli
def run_command(command):
try:
picomc_cli.main(args=command.split())
except SystemExit as e:
# Handle the SystemExit exception to prevent the script from exiting
if e.code != 0:
raise
if __name__ == "__main__":
import sys
run_command(" ".join(sys.argv[1:]))

4
test.py Normal file
View File

@ -0,0 +1,4 @@
import modulecli
# Example: Run the 'play' command with version '1.16.5'
modulecli.run_command("play 1.16.5")