File tree 4 files changed +10
-10
lines changed
4 files changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -170,10 +170,10 @@ def _last_future(self:ModuleMaker, cells):
170
170
except ValueError : return 0
171
171
172
172
# %% ../nbs/api/02_maker.ipynb
173
- def _import2relative (cells , lib_name = None ):
174
- "Converts `cells` to use `import2relative` based on `lib_name `"
175
- if lib_name is None : lib_name = get_config ().lib_name
176
- for cell in cells : cell .import2relative (lib_name )
173
+ def _import2relative (cells , lib_path = None ):
174
+ "Converts `cells` to use `import2relative` based on `lib_path `"
175
+ if lib_path is None : lib_path = get_config ().lib_path
176
+ for cell in cells : cell .import2relative (lib_path )
177
177
178
178
# %% ../nbs/api/02_maker.ipynb
179
179
def _retr_mdoc (cells ):
Original file line number Diff line number Diff line change @@ -251,5 +251,5 @@ def colab_link(path):
251
251
from IPython .display import Markdown
252
252
cfg = get_config ()
253
253
pre = 'https://colab.research.google.com/github/'
254
- res = f'{ pre } { cfg .user } /{ cfg .lib_name } /blob/{ cfg .branch } /{ cfg .nbs_path .name } /{ path } .ipynb'
254
+ res = f'{ pre } { cfg .user } /{ cfg .repo } /blob/{ cfg .branch } /{ cfg .nbs_path .name } /{ path } .ipynb'
255
255
display (Markdown (f'[Open `{ path } ` in Colab]({ res } )' ))
Original file line number Diff line number Diff line change 455
455
"outputs" : [],
456
456
"source" : [
457
457
" #|export\n " ,
458
- " def _import2relative(cells, lib_name =None):\n " ,
459
- " \" Converts `cells` to use `import2relative` based on `lib_name `\"\n " ,
460
- " if lib_name is None: lib_name = get_config().lib_name \n " ,
461
- " for cell in cells: cell.import2relative(lib_name )"
458
+ " def _import2relative(cells, lib_path =None):\n " ,
459
+ " \" Converts `cells` to use `import2relative` based on `lib_path `\"\n " ,
460
+ " if lib_path is None: lib_path = get_config().lib_path \n " ,
461
+ " for cell in cells: cell.import2relative(lib_path )"
462
462
]
463
463
},
464
464
{
Original file line number Diff line number Diff line change 1291
1291
" from IPython.display import Markdown\n " ,
1292
1292
" cfg = get_config()\n " ,
1293
1293
" pre = 'https://colab.research.google.com/github/'\n " ,
1294
- " res = f'{pre}{cfg.user}/{cfg.lib_name }/blob/{cfg.branch}/{cfg.nbs_path.name}/{path}.ipynb'\n " ,
1294
+ " res = f'{pre}{cfg.user}/{cfg.repo }/blob/{cfg.branch}/{cfg.nbs_path.name}/{path}.ipynb'\n " ,
1295
1295
" display(Markdown(f'[Open `{path}` in Colab]({res})'))"
1296
1296
]
1297
1297
},
You can’t perform that action at this time.
0 commit comments