Chris Messina Posted April 5, 2023 Share Posted April 5, 2023 🔥🔥🔥 Link to comment Share on other sites More sharing options...
luckman212 Posted April 5, 2023 Author Share Posted April 5, 2023 Wow - most underrated feature announcement ever-- This is great! Â Do you know if the keyword1||keyword2 would work in variable substitution mode? i.e. set myVar = "apple||banana" and then set keyword trigger to {var:myVar} ? Â Link to comment Share on other sites More sharing options...
vitor Posted April 5, 2023 Share Posted April 5, 2023 Yes, it works as a variable. Which means that if your workflow has user-configurable keywords, the user themselves can make that value have multiple keywords by using the ||. Chris Messina, iandol and luckman212 3 Link to comment Share on other sites More sharing options...
luckman212 Posted April 8, 2023 Author Share Posted April 8, 2023 (edited) One small thing I noticed: Â If you have multiple trigger keywords defined as "foo||bar", you can search "?bar" using Alfred and he will find the workflow, but typing "bar" in Alfred Preferences search does not find it (only finds "foo" or "foo||bar"). This is as of 5.1.2130. Â Edited April 10, 2023 by luckman212 Link to comment Share on other sites More sharing options...
Andrew Posted April 11, 2023 Share Posted April 11, 2023 @luckman212 ah thanks for spotting, I'll get this fixed in the next build Link to comment Share on other sites More sharing options...
luckman212 Posted April 16, 2023 Author Share Posted April 16, 2023 Thanks for fixing! Looks like it works fine on 5.1.2133 🙂 Andrew 1 Link to comment Share on other sites More sharing options...
Terminal Posted May 23, 2023 Share Posted May 23, 2023 On 4/5/2023 at 5:22 PM, vitor said: Starting from Alfred 5.1 (currently in pre-release), multiple keywords are supported. This support still seems haphazard. I see that it is using the common || operator found in many programming languages. But now the keyword field cant use || as a keyword trigger ? Which I used to use for a custom terminal command. Why wasn’t the keyword updated to just support a list interface like list filters or similar. Where you can clearly define many keywords, not have to worry about them being slammed together into a tiny text field, and also not be restricted by character usage. Link to comment Share on other sites More sharing options...
vitor Posted May 23, 2023 Share Posted May 23, 2023 You may disagree with the implementation, but no feature in Alfred is implemented haphazardly. In software there’s always a tradeoff and shoving a list interface into every object that allows a keyword (it’s not just Keywords) would complicate both the interface (user side) and the framework (development side) for something which though highly desired is comparatively niche. Thus we had to reach a compromise. One which both allowed the feature to exist but not be overwhelming (in multiple senses of the word). We arrived at the double pipe as the separator because it’s an incredibly rare choice as a keyword and makes sense due to its use in other contexts. Ideally it wouldn’t clash with any use case, but realistically the alternative would have been for the feature to not exist at all. It’s no different to saying you can’t have your keyword be {var:something}. While technically correct, it being that way allows for much more powerful interactions in a greater array of cases. Link to comment Share on other sites More sharing options...
Jasondm007 Posted May 31, 2023 Share Posted May 31, 2023 @vitor Any chances that multiple keyword support will get added for snippet-based workflow triggers? Thanks! Link to comment Share on other sites More sharing options...
Andrew Posted June 1, 2023 Share Posted June 1, 2023 @Jasondm007Â this may come in the future, but involves some framework rework, which is why it wasn't included as part of the || update. Link to comment Share on other sites More sharing options...
Jasondm007 Posted June 1, 2023 Share Posted June 1, 2023 No problem, @Andrew. Thanks for the update!! Link to comment Share on other sites More sharing options...
andy4222 Posted June 2, 2023 Share Posted June 2, 2023 16 hours ago, Andrew said: @Jasondm007 this may come in the future, but involves some framework rework, which is why it wasn't included as part of the || update.  @Andrew This sounds exciting! Maybe you already have it in the pipeline but I really hope we can also enjoy the feature where Snippets respect text casing. e.g., if the snippet keyword is "hello" and it expand to "hello world", it should also expand "Hello" to "Hello world". It was also discussed on another thread that I cannot find right now. Link to comment Share on other sites More sharing options...
andy4222 Posted June 8, 2023 Share Posted June 8, 2023 This is exactly what I’m looking for https://espanso.org/docs/matches/basics/#case-propagation Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now