Skip to main content

Parse and analyze your vim plugins

Project description

Rust vim-plugin-metadata

Parse and analyze your vim plugins, from Rust!

WARNING: This library is early alpha, still missing tons of functionality, and probably has serious bugs. Use at your own risk.

Usage

cargo add it to your project, point it at a file, get metadata:

use vim_plugin_metadata::VimParser;

const VIMSCRIPT_CODE: &str = r#"
""
" Standalone header comment

""
" Does something cool.
func MyFunc() abort
  ...
endfunc
"#;

fn main() {
    let mut parser = VimParser::new();
    let module = parser.parse_module(VIMSCRIPT_CODE).unwrap();
    println!("{module:#?}");
}
VimModule {
    nodes: [
        StandaloneDocComment(
            "Standalone header comment",
        ),
        Function {
            name: "MyFunc",
            doc: Some(
                "Does something cool.",
            ),
        },
    ],
}

See tests in src/lib.rs for more usage examples.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vim_plugin_metadata-0.1.0.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

vim_plugin_metadata-0.1.0-cp312-cp312-manylinux_2_34_x86_64.whl (474.9 kB view details)

Uploaded CPython 3.12 manylinux: glibc 2.34+ x86-64

File details

Details for the file vim_plugin_metadata-0.1.0.tar.gz.

File metadata

File hashes

Hashes for vim_plugin_metadata-0.1.0.tar.gz
Algorithm Hash digest
SHA256 e181bc9137e0524eaa4203e68dc99997316014c413638f3fbca0ec24168b873a
MD5 a4d3906384b235eeb956106e06a4e4f4
BLAKE2b-256 443c3627111249377cff117f5423a19d882248e0cc4fa22a35008dd3cb16603f

See more details on using hashes here.

File details

Details for the file vim_plugin_metadata-0.1.0-cp312-cp312-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for vim_plugin_metadata-0.1.0-cp312-cp312-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 6f5b0b193bbb1a494f575ec67c6e50cd9f30c94913abd5140dc2406d4049bca5
MD5 3b18a42fd3c2552a78436488588ea086
BLAKE2b-256 93c4158c6b841c98e4a6d6873264374cfc84a7506e41b9ebd46a3c2778b0997d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page