Skip to content

Commit

Permalink
More information in README.md.
Browse files Browse the repository at this point in the history
  • Loading branch information
pmgagne committed Feb 25, 2020
1 parent 96da374 commit 1750ea2
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ __pycache__/
*$py.class

# C extensions
*.so
#*.so

# Distribution / packaging
.Python
Expand Down
16 changes: 15 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,21 @@ It is a domain public project.

## What this repository is about

It package TkinterDnD2 and tkdnd2 into a standard python module
It package TkinterDnD2 and tkdnd2 into a standard python module.

When the extension is imported in python its location will be automatically added to the Tk search path.

# Installation

Nothing fancy:

python setup.py install

You can then import tkinterdnd2 in your project. See examples in folder "demos".

## pyinstaller

If you want to use pyinstaller, you should use the hook-tkinterdnd2.py file included. Copy it in the base directory of your project, then:

pyinstaller -F -w myproject/myproject.py --additional-hooks-dir=.

12 changes: 12 additions & 0 deletions hook-tkinterdnd2.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
"""pyinstaller hook file.
You need to use this hook-file if you are packaging a project using tkinterdnd2.
Just put hook-tkinterdnd2.py in the same directory where you call pyinstaller and type:
pyinstaller myproject/myproject.py --additional-hooks-dir=.
"""

from PyInstaller.utils.hooks import collect_data_files, eval_statement


datas = collect_data_files('tkinterdnd2')

0 comments on commit 1750ea2

Please sign in to comment.