sponsor Vim development Vim logo Vim Book Ad

Mesonic : A Vim plugin for Meson build system

 script karma  Rating 12/9, Downloaded by 545  Comments, bugs, improvements  Vim wiki

created by
Ivan Gankevich
 
script type
ftplugin
 
description
Mesonic is a plugin that uses Vim compiler infrastructure to integrate Meson build system (http://mesonbuild.com/) into an editor with special handling of out-of-source builds. It sets 'makeprg', 'errorformat' options and provides syntax highlighting for meson.build files.

Use :MesonInit to initialise build directory for the first time. After that you can issue :make command as usual, which produces correct quickfix list no matter what current directory is. All commands work as expected from any subdirectory of your project.

You can customise meson and ninja commands with the following variables, which can be either global or buffer local. Defaults are listed below.

let b:meson_command = 'meson'
let b:meson_ninja_command = 'ninja'

If you want to switch between build directories, issue :MesonInit command with an argument. For example, to switch to 'build-special' directory, issue

:MesonInit 'build-special'

The directory will be initialised if it does not exist or does not contain build.ninja file. As of the current version Meson options can be added only via b:meson_command variable.

Mesonic assumes that build directory is a subdirectory of top-level directory of your project, i.e. build directory is located in the same directory where your main meson.build file is. In all other cases it may produce wrong file paths in quickfix list.

This plugin was created as a result of my passion for Vim and C++ programming, and as a consequence of reading "Learn Vimscript the Hard Way" by Steve Losh (http://learnvimscriptthehardway.stevelosh.com/). Feel free to contribute or post a bug at GitHub project page (https://github.com/igankevich/mesonic).
 
install details
Install via your favourite plugin manager as 'igankevich/mesonic' or download the package here, unpack it and move all directories to your ~/.vim folder.
 

rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
mesonic-1.0.0.tar.gz 1.0 2016-04-27 7.0 Ivan Gankevich Initial upload
ip used for rating: 3.236.239.91

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
   
OSDN