Skip to content

Commit 8d39f8b

Browse files
committed
added directions for directory use
1 parent 3dc094f commit 8d39f8b

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,4 @@ build
1212
.DS_Store
1313
promptlab.spec
1414
__pycache__/
15+
*.zip

README.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,12 @@ promptlab dump --source=prompts > key-points.md
6666

6767
# Installation
6868

69-
Promptlab uses Pyinstaller to create a single executable file. To install it, [download the latest release](https://github.com/oreillymedia/promptlab/releases) and put it somewhere in your path. You will likely also need to [enable it to run on a mac by changing the permissions](https://iboysoft.com/howto/cannot-be-opened-because-it-is-from-an-unidentified-developer.html).
69+
Promptlab uses Pyinstaller to create a single executable file. To install it, [download the latest release](https://github.com/oreillymedia/promptlab/releases), unzip it, and then put it somewhere in your path. You will likely also need to [enable it to run on a mac by changing the permissions](https://iboysoft.com/howto/cannot-be-opened-because-it-is-from-an-unidentified-developer.html).
7070

7171
To test that it's working correctly, run:
7272

7373
```
74-
promptlab version
74+
./promptlab/promptlab/promptlab version
7575
```
7676

7777
Note that it's pretty slow to start. This is an artifact of the way Pyinstaller works when it builds a single file for distribution. Once it's running, it's pretty fast. I should probably make a REPL for it.
@@ -448,3 +448,11 @@ pyinstaller \
448448
main.py
449449

450450
```
451+
452+
To view the sizes of the included files, cd into the `dist/_internal` directory and run:
453+
454+
```
455+
du -hs *
456+
```
457+
458+
Originally, I compiled this using `--onefile` but found that it became incredibly slow to start up. Ths seems to be a common complaint about pyinstaller. I think it also has to do with a virus scanner, which has to scan each file in the package as it's unzipped every time. So, I started just directibuting the dist folder. It's less convenient and clear, but gives an acceptable startup time.

0 commit comments

Comments
 (0)