Skip to content

Instantly share code, notes, and snippets.

@perryism
Created January 11, 2023 06:08
Show Gist options
  • Save perryism/29222cd8ef737bda47ca042de804e6d7 to your computer and use it in GitHub Desktop.
Save perryism/29222cd8ef737bda47ca042de804e6d7 to your computer and use it in GitHub Desktop.
Make python package executable
def run():
print('Hello world')
from setuptools import setup
setup(
name='myscript',
version='0.0.1',
entry_points={
'console_scripts': [
'myscript=myscript:run'
]
}
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment