Plugin New | Vault
Before running vault plugin new, ensure your environment is ready:
| Requirement | Description |
|-------------|-------------|
| Vault CLI | Version 1.11.0 or higher. Check with vault -v. |
| Go (1.21+) | Vault plugins are written in Go. |
| Make / GCC | For compiling the plugin binary. |
| Git | For fetching dependencies. |
| Vault Dev Server | For testing (recommended). | vault plugin new
Install Vault on macOS, Linux, or WSL2. Windows is not officially supported for plugin development. Before running vault plugin new , ensure your
You must calculate the SHA256 checksum of the binary and register it with Vault's catalog. This is a security measure to ensure the binary hasn't been tampered with. You must calculate the SHA256 checksum of the
# Calculate SHA256
SHA256=$(sha256sum /opt/vault/plugins/my-custom-plugin | cut -d ' ' -f1)
# Register the plugin in the catalog
vault plugin register \
-sha256=$SHA256 \
-command="my-custom-plugin" \
secret \
my-custom-plugin
// backend_test.go func TestBackend(t *testing.T) { b, _ := Factory(context.Background(), &logical.BackendConfig{ StorageView: &logical.InmemStorage{}, })// Test write req := &logical.Request{ Operation: logical.UpdateOperation, Path: "config", Data: map[string]interface{} "api_key": "test", , Storage: b.(*framework.Backend).Storage(), } resp, err := b.HandleRequest(context.Background(), req) if err != nil || resp != nil t.Fatal("failed to write config")
}
| Feature | Description |
|---------|-------------|
| Auto-filing | Moves notes to predefined folders when a specific tag (e.g., #science) or link is detected. |
| Rule-based engine | Create rules like: if note has tag #projects/work, move to Projects/Work/. |
| Tag & link triggers | Supports tags, internal links, and frontmatter properties as triggers. |
| Folder templates | Option to create subfolders dynamically (e.g., #daily/2025 → Journal/2025/). |
| Manual override | Prevent auto-move for certain notes via frontmatter (topic-vault: false). |
| Bulk processing | Run rules against existing notes to reorganize your vault retroactively. |
| Conflict handling | If multiple rules match, you choose priority or prompt. |