feat: implement modular modal editor and isolated Ruby plugins
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
Vamp.plugin "greeting", requires: ["text"]
|
||||
|
||||
Vamp.command "greet" do |editor, args|
|
||||
name = args.empty? ? "world" : args
|
||||
editor.insert "Hello, #{name}!\n"
|
||||
editor.message "Greeting inserted by Ruby"
|
||||
end
|
||||
|
||||
Vamp.command "upper" do |editor, _args|
|
||||
editor.replace editor.text.upcase
|
||||
editor.message "Buffer uppercased by Ruby"
|
||||
end
|
||||
Reference in New Issue
Block a user