Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion pickora.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def excepthook(etype, value, tb):

sys.excepthook = excepthook

if __name__ == "__main__":
def cli():
description = "A toy compiler that can convert Python scripts to pickle bytecode."
epilog = "Documentation can be found at https://github.com/splitline/Pickora"
parser = argparse.ArgumentParser(description=description, epilog=epilog)
Expand Down Expand Up @@ -59,3 +59,6 @@ def excepthook(etype, value, tb):
if args.eval:
ret = pickle.loads(bytecode)
print("[+] pickle.loads returns:", repr(ret))

if __name__ == "__main__":
cli()
20 changes: 20 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
[tool.poetry]
name = "pickora"
version = "0.1.0"
description = "A toy compiler that can convert Python scripts to pickle bytecode."
documentation = "https://github.com/splitline/Pickora"
authors = ["splitline <[email protected]>"]
include = ["compiler.py", "helper.py"]

[tool.poetry.dependencies]
python = "^3.8"

[tool.poetry.scripts]
pickora = 'pickora:cli'

[tool.poetry.urls]
"Documentation" = "https://github.com/splitline/Pickora"

[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"