SUSTech-data / neopyter

The bridge between Neovim and Jupyterlab
BSD 3-Clause "New" or "Revised" License
80 stars 0 forks source link

Question: Going from ipynb to .ju.py #8

Open thecontinium opened 2 months ago

thecontinium commented 2 months ago

Hi @AbaoFromCUG

Thanks for putting this together.

I'm interested how you work with current notebook files that you want to edit and keep in sync.

Thanks

AbaoFromCUG commented 2 months ago

This is my work flow

  1. prepare work
    • start jupyter lab via jupyter lab command and open in browser, different jupyter lab port identify different project
    • start neovim in terminal, write neopyter's config in .neoconf.json , see https://github.com/SUSTech-data/neopyter/blob/master/.neoconf.json
    • Notice: the current work directories of neopyter and JupyterLab could be different, because JupyterLab may run in server in my case
  2. new .ju.py
    • create same name .ipynb in jupyterlab side
    • create same name .ju.py in neovim
    • Start edit
  3. open .ju.py
    • if there is a same name .ipynb, which will be opened in jupyterlab automatically
    • if there is not the same name notebook, I will execute :Neopyter sync current to force sync with current opened notebook (In temporary use case)

Currently, .ipynb is temporary file, should only be used to preview/execute