<li><strong>Bitwise operators require objects to have and(), or() and xor() special methods, unlike logical operators that work on all types of objects.</strong></li>
$ pyinstaller script.py <spanclass="hljs-comment"># Compiles into './dist/script' directory.</span>
$ pyinstaller script.py --onefile <spanclass="hljs-comment"># Compiles into './dist/script' console app.</span>
$ pyinstaller script.py --windowed<spanclass="hljs-comment"># Compiles into './dist/script' windowed app.</span>
$ pyinstaller script.py --add-data '<path>:.'<spanclass="hljs-comment"># Adds file to the root of the executable.</span>
<div><h3id="virtualenvironments">Virtual Environments</h3><p><strong>System for installing libraries directly into project's directory.</strong></p><pre><codeclass="bash language-bash hljs">$ python3 -m venv <name><spanclass="hljs-comment"># Creates virtual environment in current directory.</span>
$ <spanclass="hljs-built_in">source</span><name>/bin/activate<spanclass="hljs-comment"># Activates venv. On Windows run `<name>\Scripts\activate`.</span>
$ pip3 install <library><spanclass="hljs-comment"># Installs the library into active environment.</span>
$ python3 <path><spanclass="hljs-comment"># Runs the script in active environment. Also `./<path>`.</span>
<li><strong>File paths need to be updated to <codeclass="python hljs"><spanclass="hljs-string">'os.path.join(sys._MEIPASS, <path>)'</span></code>.</strong></li>