Jump to content

Snippet trigger does not work as a placeholder

Recommended Posts

I have created a workflow so that with a Snippet it generates me textually the next month taking as reference today.
I wanted to attach the workflow but it only allows me to attach images. 


I tried to do it this way, because from the Snippets section, the defined placeholders did not give the result I needed.








Now, I go to "Snippets" and I want to create, together with another text string, the result of this workflow. I add images as well:




If I type the snippet "\\MM" in any text field, it executes without problems. But if I run the snippet ">nb" it doesn't return the value.
I have tried other snippets I have using the placeholder {snippet:keyword} and they work correctly.
I have no conflicts using the same name with other snippets and I always use prefixes.


I hope you can help me, thank you very much.




Link to comment

@Miltrin Welcome to the forum!


It's not possible to use a Snippet Trigger in a workflow embedded within a standard snippet due to their complex and open ended nature.


Think of Snippet Triggers in a workflow as a trigger to run a workflow to do anything at all, but from a typed phrase in any app. It just so happens that you can also paste this back to macOS using a Copy to Clipboard, essentially making a scripted snippet in your case.


To achieve what you'd like to do, set the snippet trigger to what you'd like to use (e.g. "nb" in your example), then place the "jrnl bujo -contains --change-time {query}" in the Paste to Clipboard output object.


It's also worth noting that you don't need the "Arg and Vars" object.


Let us know how you get on or if you need any further help with the workflow :) 

Link to comment

Hi, @Vero

Thank you very much for your answer, I think I understood you well and I will share my result with you. Because I would like to ask you, if you would know why I get a line break at the end.










Forget the "APIs/" thing, it's an autocomplete given by Warp. But when executing the snippet it makes that line break.


Thank you again for your help.



Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...