Files
vimdir/documentation/developer_quide.md
2025-01-26 18:16:58 +01:00

1.3 KiB

Vimdir developer guide

Files

Name Description
kvec.h Vector library.
dictate.* IO library.
remove_all.* Recursive remove library.
global.h Global variables from flags and the environment. There are only a few and it shall be kept like that.
main.c Project core. Implements global.h.
opts.* Flag and environment handler. Fills up global.h
error.* Simplifies and unifies error handling. All error messages are dispatched from within here.
directive.* Responsible for creating parsing entries.
file_utils.* File operations. This is where directive.* delegates commands to. Responsible for respecting dry-runs.

LS_COLORS

Using the ls_colors Make target, we can statically render the vim highlighting script. Tcl is used to generate the vim commands. Plug is used to insert it into .vim/syntax/vimdir.vim. .vim/syntax/vimdir.vim is version controlled for user convenience.

Debugging

If the $DEBUG environment variable is set to 1, a clean build will produce a debug version executable of Vimdir. Debug builds contain DRARF symbols, may output extra info and use ./vimdir_test_file.vimdir as a tmpfile.

Tests require ./vimdir_test_file.vimdir, therefor they will only succeed on debug builds.