Skip to content

Commit

Permalink
Add docments
Browse files Browse the repository at this point in the history
  • Loading branch information
Isaac-Flath committed Sep 24, 2024
1 parent 0c60690 commit 2d61b50
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion nbdev/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,11 @@ def nb_export_cli(nbname,

# %% ../nbs/api/13_cli.ipynb
@call_parse
def watch_export(nbs:str=None, lib:str=None, force:bool=False):
def watch_export(nbs:str=None, # Nb directory to watch for changes
lib:str=None, # Export directory to write py files to
force:bool=False # Ignore nbdev config if in nbdev project
):
'''Use `nb_export` on ipynb files in `nbs` directory on changes using nbdev config if available'''
cfg = get_config() if is_nbdev() else None
nbs = nbs or (cfg.nbs_path if cfg else '.')
lib = lib or (cfg.lib_path if cfg else '.')
Expand Down
6 changes: 5 additions & 1 deletion nbs/api/13_cli.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,11 @@
"source": [
"#|export\n",
"@call_parse\n",
"def watch_export(nbs:str=None, lib:str=None, force:bool=False):\n",
"def watch_export(nbs:str=None, # Nb directory to watch for changes\n",
" lib:str=None, # Export directory to write py files to\n",
" force:bool=False # Ignore nbdev config if in nbdev project\n",
" ):\n",
" '''Use `nb_export` on ipynb files in `nbs` directory on changes using nbdev config if available'''\n",
" cfg = get_config() if is_nbdev() else None\n",
" nbs = nbs or (cfg.nbs_path if cfg else '.')\n",
" lib = lib or (cfg.lib_path if cfg else '.')\n",
Expand Down

0 comments on commit 2d61b50

Please sign in to comment.