I've been trying to learn Python via "Learn Python the Hard Way", and in ex46 he told us to put a script in bin and install it with setup.py.
My script name was script1.py Here is my setup.py file:
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
config = [
'description': 'My Project',
'author': 'My Name',
'url': 'URL to get it at.',
'download_url': 'Where to download it.',
'author_email': 'My email.',
'version': '0.1',
'install_requires': ['nose'],
'packages': ['NAME'],
'scripts': ['bin/script1.py'],
'name': 'projectname'
]
setup(**config)
Output:
File "setup.py", line 7
'description': 'My Project',
^
SyntaxError: invalid syntax
- I am using ubuntu 16.04 and python 2.7.13
python3command - it is preinstalled as most of the Python scripts on the operating system require Python 3.