Falldog / pyconcrete

Protect your python script, encrypt it as .pye and decrypt when import it
Apache License 2.0
692 stars 149 forks source link

Pyconcrete for Reusable Django Apps #59

Closed lucreziopancrazio closed 5 years ago

lucreziopancrazio commented 5 years ago

Hi it's possible to use it for reusable apps? I followed this guide https://docs.djangoproject.com/en/2.2/intro/reusable-apps/

Everything works fine and I've built pip packages. I want to protect my code so I've installed pyconcrete in main project and executed 'pyconcrete-admin compile etc'. It works and gave me pye files so I tried 'pyconcrete-admin release' and pyconcrete created a tar.gz packag. But if I extract the code is in clear. How can I encrypt this code?

Falldog commented 5 years ago

Sorry, the purpose of pyconcrete-admin release is for release pyconcrete project, not for your django project.

Django reusable-apps package by setup.py sdist. If you want package your own project (not pyconcrete), you should read setup.py document, study how to collect the files/scripts you want.

lucreziopancrazio commented 5 years ago

Thanks for the answer. I found some documentation about collecting files for setup.py (just include all interested files in MANIFEST.in) so in package I put every pye file, but during pip installation they are ignored. Do you have any suggestion?

Falldog commented 5 years ago

You can try to customize install class reference https://github.com/Falldog/pyconcrete/blob/master/setup.py#L250