Skip to content

Commit

Permalink
Merge pull request #544 from fastai/revert-542-master
Browse files Browse the repository at this point in the history
  • Loading branch information
jph00 authored Apr 26, 2024
2 parents 76a2ad5 + ff9534d commit df28237
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions fastcore/xtras.py
Original file line number Diff line number Diff line change
Expand Up @@ -559,9 +559,9 @@ def console_help(
libname:str): # name of library for console script listing
"Show help for all console scripts from `libname`"
from fastcore.style import S
from importlib.metadata import entry_points as ep_il
for e in ep_il(group='console_scripts'):
if e.value == libname or e.value.startswith(libname+'.'):
from pkg_resources import iter_entry_points as ep
for e in ep('console_scripts'):
if e.module_name == libname or e.module_name.startswith(libname+'.'):
nm = S.bold.light_blue(e.name)
print(f'{nm:45}{e.load().__doc__}')

6 changes: 3 additions & 3 deletions nbs/03_xtras.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2357,9 +2357,9 @@
" libname:str): # name of library for console script listing\n",
" \"Show help for all console scripts from `libname`\"\n",
" from fastcore.style import S\n",
" from importlib.metadata import entry_points as ep_il\n",
" for e in ep_il(group='console_scripts'): \n",
" if e.value == libname or e.value.startswith(libname+'.'): \n",
" from pkg_resources import iter_entry_points as ep\n",
" for e in ep('console_scripts'): \n",
" if e.module_name == libname or e.module_name.startswith(libname+'.'): \n",
" nm = S.bold.light_blue(e.name)\n",
" print(f'{nm:45}{e.load().__doc__}')\n"
]
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from packaging.version import Version
from pkg_resources import parse_version
from configparser import ConfigParser
import setuptools,re,sys
assert Version(setuptools.__version__)>=Version('36.2')
assert parse_version(setuptools.__version__)>=parse_version('36.2')

# note: all settings are in settings.ini; edit there, not here
config = ConfigParser(delimiters=['='])
Expand Down

0 comments on commit df28237

Please sign in to comment.