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

I want to run pye in a script #79

Closed KohnoseLami closed 3 years ago

KohnoseLami commented 3 years ago

I have a question about "pyconcrete", is it possible to call it from a different file like import? I want to run pye in an environment that cannot be called from the console.

Falldog commented 3 years ago

You could import pyconcreate python package as library

import pyconcrete
if __name__ == '__main__':
    pass

You could not import pyconcrete exec file, rather that you can execute it in command line linux shell script

$! /bin/bash
echo "before run"
pyconcrete main.pye
echo "after run"
KohnoseLami commented 3 years ago

I'm sorry, this question is, "Can you execute pye like pyc?" ...

"pyc" can be imported as a module from another file, can "pye" do the same?

Falldog commented 3 years ago

If you want to share your module to others, must share with pyconcrete module. Because the encryption key store in _pyconcrete.so build on your machine when you install pyconcrete.