Skip to content

Commit

Permalink
Update build script and add some more details to README
Browse files Browse the repository at this point in the history
  • Loading branch information
AlvinKuruvilla committed Feb 17, 2024
1 parent db6d52e commit 67f3617
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 5 deletions.
9 changes: 7 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ The .env file contains the following variables:
See sample.env for an example .env configuration

```diff
- NOTE: If you decide to change the names of the environment variables make sure that they do not conflict with an Operating System specific predefined variables. For example USER in MacOS and USERNAME in Windows -
NOTE: If you decide to change the names of the environment variables make sure that they do not conflict with an Operating System specific predefined variables. For example USER in MacOS and USERNAME in Windows -
```

## MySQL Installation
Expand Down Expand Up @@ -173,18 +173,23 @@ git clone https://github.com/AlvinKuruvilla/kmlog.git
pip3 -r requirements.txt
```

3. Build the executable
3. Create the kmlog.spec file and build the executable

```bash
./build.sh
```
> This puts the executable in the dist/ folder
4. Run kmlog

```bash
./kmlog
```

To fix any problems with input recording, give your terminal or the executable Input Monitoring access

On Apple devices, navigate to System Preferences > Go to Privacy and Security > Go to the Input Monitoring tab > Select your terminal application or kmlog executable (if they are not already there) and then toggle one of them on.

### Running from Github release

1. Download the binary from the release page.
Expand Down
5 changes: 4 additions & 1 deletion build.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash

echo "Creating spec file..."
pyi-makespec src/kmlog.py

echo "Building executable..."
pyinstaller -F --clean --onefile kmlog.spec
pyinstaller --clean kmlog.spec
4 changes: 2 additions & 2 deletions src/tools/process_utilities.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2021 - 2022, Alvin Kuruvilla <[email protected]>, Dr. Rajesh Kumar <[email protected]>
# Copyright 2021 - 2023, Alvin Kuruvilla <[email protected]>, Dr. Rajesh Kumar <[email protected]>

# Use of this source code is governed by an MIT-style
# license that can be found in the LICENSE file or at
Expand All @@ -7,9 +7,9 @@
# This is a small debug utility to print the pid KMLogger is
# running on to help with profiling
import os
from base.displayer import block_text
from setproctitle import setproctitle, getproctitle
import psutil
from base.displayer import block_text


def set_process_title(title: str):
Expand Down

0 comments on commit 67f3617

Please sign in to comment.