4

How can I add descriptions like version, copyright, file description etc. to a single file (exe)

enter image description here

python pyinstaller.py -F -w -i favicon.ico C:\Projekte\Eclipse\MyApp\app.pyw
Seppo
  • 189
  • 4
  • 10

3 Answers3

1

--version-file=versioninfo.txt

Example: PATH_TO\PyInstaller-2.1\tests\basic\test_pkg_structures-version.txt

Read the Manual "Capturing Windows Version Data".

Nuno André
  • 4,739
  • 1
  • 33
  • 46
HIGH-Zen
  • 11
  • 1
  • There's not a section called exactly that, but a good place to start is http://www.pyinstaller.org/export/develop/project/doc/Manual.html#grabversion-windows – Chris Rae Jun 20 '14 at 08:35
1

PyInstaller ships with some utilities, including:

  1. pyi-grab_version
  2. pyi-set_version

The first will get version information from an EXE file and save it to a text file. The second will get the version information from a text file and embed it inside of an EXE file.

These utilities are in the Scripts subfolder of your Python installation (at least on a Windows install). You can run them from the command line (DOS prompt). You can either add the Scripts subfolder to your path to be able to run these commands or you'll have to type the entire path from whatever path you're in.

I recommend you use the pyi-grab_version utility on your EXE file. It will save a new file called file_version_info.txt. You can edit this file to change values and descriptions to what you want. Then you can either modify your EXE file with pyi-set_version or you can remake your EXE file, but now use the --version-file switch as described here.

bfris
  • 5,272
  • 1
  • 20
  • 37
0

I recomend to you that read this thread, Comprehensive tutorial on Pyinstaller?. Would be help to you. By the other hand, I used py2exe, if you use py2exe is most powerfull, i left to you a setup.py of py2exe, on this setup.py you see the properties that you want to get to you app.exe.

from distutils.core import setup
import py2exe, sys 
import glob

setup(
    name='AppName',
    version='1.0',
    scripts=['src\modInicio\inicio_class.py'],
    windows=['src\modInicio\inicio_class.py'],
    data_files=[('glade', glob.glob('interface\Sname.glade')), ('', glob.glob('gui/config.ini'))],
    packages=['src\modules'],
    options={'py2exe':{'packages':'encodings,reportlab',                        
                       'includes':'gtk,gtk.glade,cairo,pango, pangocairo, atk,gobject, logging, sqlalchemy,sqlalchemy.ext.sqlsoup'                       
                     },
            'sdist':{'formats':'zip'}
           }
 )

I leave you here this link, http://www.pyinstaller.org/export/develop/project/doc/Manual.html ,in it documentation appear things like this

    Windows specific options:
--version-file=FILE
     add a version resource from FILE to the exe
-m FILE, -m XML, --manifest=FILE, --manifest=XML
     add manifest FILE or XML to the exe
Community
  • 1
  • 1
  • 1
    I know the documentation. I am searching something about VersionInfo respectively how the file is built (content of the file) – Seppo Apr 08 '13 at 13:47
  • If you build your .exe with py2exe i will help to you so much better than it. Let me know. – Maykel Llanes Garcia Apr 08 '13 at 14:50
  • I dont know specifics of the pyinstaller , but i recomend py2exe is mot powerfull and markable. – Maykel Llanes Garcia Apr 08 '13 at 14:55
  • If I build a single file exe with py2exe - so the file size is about 25MB. With pyinstaller the exe. file size is 12MB... – Seppo Apr 09 '13 at 06:02
  • Well if you have this requirements of space, so you can't use py2exe, but i can not believe ,What is de diference ? only 13 mb , today when the hard drives outweigh 1 terabytes. Think about this? If py2exe represent the solution of your problem with 13 mb more. – Maykel Llanes Garcia Apr 10 '13 at 12:25