Skip to content

Commit

Permalink
add ntk.exe and installer for generate exe file
Browse files Browse the repository at this point in the history
  • Loading branch information
reloadsweety committed Feb 13, 2025
1 parent 67d0995 commit 1a6821c
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
Binary file added dist/ntk.exe
Binary file not shown.
19 changes: 19 additions & 0 deletions ntk/installer.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import os
import subprocess

Check warning on line 2 in ntk/installer.py

View check run for this annotation

Codecov / codecov/patch

ntk/installer.py#L1-L2

Added lines #L1 - L2 were not covered by tests

# Required: Install PyInstaller before using this script
# Install with: pip install pyinstaller

# This script is used to create a command alias (`ntk`) for running a Python module (`ntk`) more easily.

# To generate an executable using PyInstaller, use the following command:
# python -m PyInstaller --onefile --console .\ntk\installer.py -n n

if __name__ == "__main__":
subprocess.run(['python', '-m', 'pip', 'install', 'next-theme-kit'])

Check warning on line 13 in ntk/installer.py

View check run for this annotation

Codecov / codecov/patch

ntk/installer.py#L12-L13

Added lines #L12 - L13 were not covered by tests

# Set up a command alias: 'ntk' will execute 'python -m ntk' with any passed arguments
os.system("doskey ntk=python -m ntk.ntk $*")

Check warning on line 16 in ntk/installer.py

View check run for this annotation

Codecov / codecov/patch

ntk/installer.py#L16

Added line #L16 was not covered by tests

# Open a new command prompt window and keep it open
os.system("cmd /k")

Check warning on line 19 in ntk/installer.py

View check run for this annotation

Codecov / codecov/patch

ntk/installer.py#L19

Added line #L19 was not covered by tests

0 comments on commit 1a6821c

Please sign in to comment.