Recent Changes · Search:

Dispense


Navigation Tips - Dritte


PmWiki

pmwiki.org

edit SideBar

Docs

< Mujpy.PackageMaintenance | Index | Mujpy.JupiterlabSettings >


  • save a video, see mujpy/docs/save-video
  • all images in docs/_static/
  • sphinx docutil code, with
  • vim:
".vimrc with bfinal autocmd to make html, check the venv name in '~/.mujpy.env/bin/sphinx-build')
" Set compatibility to vim only
set nocompatible
" Show line numbers
set number
" Status bar
set laststatus=2
" Auto-wrap text extending beyond screen length
set wrap 
" Encoding
set encoding=utf-8
set backup
set backupdir=~/.vim/backups//
set writebackup

set undofile
set undodir=~/.vim/undodir

" DBAB and save often
set noswapfile

 " Plugin section
call plug#begin()

    Plug 'kaarmu/typst.vim'
    call plug#end()

"inoremap <> <><Left>
"inoremap () ()<Left>
"inoremap {} {}<Left>
"inoremap [] []<Left>
"inoremap "" ""<Left>
"inoremap '' ''<Left>
"inoremap `` ``<Left>
inoremap <S-Tab> <Esc>
onoremap <S-Tab> <Esc>
nnoremap Y y$

function! RunSphinxBuild() abort
    let l:makefile = findfile('Makefile', expand('%:p:h') . ';')
    if empty(l:makefile)
        echo "Sphinx: no Makefile found."
        return
    endif

    let l:docs_dir = fnamemodify(l:makefile, ':p:h')
    let l:sphinx = expand('~/.mujpy.env/bin/sphinx-build')

    if !executable(l:sphinx)
        echoerr "Sphinx executable not found: " . l:sphinx
        return
    endif

    let l:cmd = 'make -C ' . shellescape(l:docs_dir)
                \ . ' ' . shellescape('SPHINXBUILD=' . l:sphinx)
                \ . ' html 2>&1'

    let l:output = system(l:cmd)
    let l:status = v:shell_error
    let l:log = l:docs_dir . '/sphinx-build.log'
    call writefile(split(l:output, "\n"), l:log)

    if l:status
        echohl ErrorMsg
        echom "Sphinx build failed. See " . l:log
        echohl None
    else
        echom "Sphinx HTML built. Log: " . l:log
    endif
endfunction

augroup SphinxAutoBuild
    autocmd!
    autocmd BufWritePost *mujpy/**/*.rst call RunSphinxBuild()
augroup END

< Mujpy.PackageMaintenance | Index | Mujpy.JupiterlabSettings >

Edit - History - Print - PDF - Recent Changes - Search
Page last modified on October 06, 2026, at 12:39 PM