Jump to content

dfay

Member
  • Content Count

    878
  • Joined

  • Last visited

  • Days Won

    47

Reputation Activity

  1. Like
    dfay reacted to giovanni in snippet expansion   
    This thread may be of help:
     
     
     
  2. Like
    dfay got a reaction from chris in Alfred integration with TouchBar?   
    I’ve updated the title of the older thread since in reality a lot of the discussion is about the kind of things @chris suggests, at the app rather than workflow level.
  3. Like
    dfay reacted to borzov in Snippet Creator   
    Great script, thank you! 
     
    With his help made a big snippet collection of ASCII Emoji. I post the result, suddenly someone also likes good old ASCII Emoji ♥‿♥
     
    Get it here:
    https://github.com/borzov/alfred-snippet-ascii-emoticons
  4. Like
  5. Like
    dfay reacted to woz_one in Recent Items 4.2 for Alfred 3: Docs, Folders, Apps + Custom Categories + Favorites + Interaction with Open/Save Dialogs and more...   
    Yoooooo, thank you so much for this! Not sure how I missed your reply, but just saw this now. Works perfect!
  6. Like
    dfay reacted to vitor in SandwichTimer — Run pomodoros and other timers   
    Thank you for the offer, but I won’t accept it.

    Having an Apple Developer Account and being able to justify paying for one aren’t the same thing. $100 are more useful to me than the account (which would be convenient but I don’t really need).

    When someone pays me to code, I’m committed to an agreement and will do as much or more than was decided, because I’m being compensated for my time.

    When I code for free, even if I build something I will never use (common), I have the freedom to decide how committed I want to be and can abandon the project at any time.

    When someone sends me a tip as a way of thanks, it’s for things I’ve already done, so I retain the freedom to continue sharing or stop.

    But if you paid for one year of an Apple Developer Account, I would get no compensation (all the money would be spent on something I care little about) and I’d be beholden to you (or worse, a group of people) to work on features. It’s the worse of both worlds.

    While I know that’s not in any way your intention, it sounds like a recipe for an unhappy time. No, thank you.
  7. Like
    dfay got a reaction from deanishe in Fantastical 3   
    The issue is that the original post doesn’t say which workflow it refers to.  It should be posted on the thread for that workflow.  Then someone may be able to help with the specific case.
  8. Like
    dfay reacted to bhanquier in Case Converter (including Title Case)   
    Gained a perfectly working workflow in Office, and I finally understand what "Escaping" means in this case. 
    Thanks a bunch! 
  9. Like
    dfay reacted to Jasondm007 in PDF Actions (so far only splitting double pages)   
    @dfay & @xilopaint - Thank you both so much for sharing your workflows for splitting double paged PDFs. You guys are a lifesaver! I have been doing this manually in Adobe Acrobat for eons - and cursing every moment of it. Can't thank you both enough!!
  10. Like
    dfay reacted to deanishe in Possible to fire Action as characters are typed?   
    Then fire an External Trigger from your Script Filter instead of opening an application, and use that to run any actions you want.
  11. Like
    dfay got a reaction from khoker in Possible to fire Action as characters are typed?   
    see also
     
     
  12. Thanks
    dfay got a reaction from cands in Date Snippets - insert upcoming days (next Monday etc.)   
    Updated to v.1.2
    - added first day of next month
    - added external triggers for M of next week and 1st of next month
    - updated so snippets will paste in Alfred (using the trick here: https://www.alfredforum.com/topic/11765-snippet-triggers-triggered-in-alfred-dont-paste-to-alfred/?tab=comments#comment-61652 )
  13. Like
    dfay got a reaction from vanderholm in Nested Snippets (snippets within snippets)   
    I've moved all my snippets from TextExpander to Alfred, and it's actually pretty easy to create the equivalent of a nested snippet using snippet triggers in a workflow .  Not as simple as in TE but easy to do if you don't anticipate continuously creating a lot of new ones (which is still easy but a bit of work.)
     
    Here's an example:
     
    https://www.dropbox.com/s/xu8afkqd4hfzgn2/nested snippets.alfredworkflow?dl=0
     
    The snippet values are stored as environment variables and the first two snippet triggers show how to use them.  The third shows how to use a list filter to replace the address value on the fly.  
     
     
  14. Like
    dfay got a reaction from vanderholm in Snippet Creator   
    See 
     for the background.
     
    Snippet Creator
    adapted from https://github.com/derickfay/import-alfred-snippets
     
    There are two keywords, both of which result in the creation of a new snippet:
     
    sc - (single step) Required fields: name|keyword|content -- separated by |
    sc2 (multi step) - Enter the snippet text, then you'll be prompted for the keyword / name -- in the interest of speed and simplicity the name is set to the keyword.
    sc2 also has triggers to pre-population with selected text or clipboard contents
     
    set prefsPath in the environment variables to the path to your snippets folder - e.g. "/Users/someuser/Dropbox/Sync/Alfred 4/Alfred.alfredpreferences/snippets/"
    and newSnippetFolder to your desired target folder
     
    The workflow posts a notification on success to remind you of your newly created snippet.
     
    https://www.dropbox.com/s/85nc52o241qobvm/snippet creator.alfredworkflow?dl=0
     
    Version 0.2:
    - updated to use a pipe | as a delimiter instead of a comma, and to remove the requirement to enclose text in quotes 
     
    Version 0.1:
     initial
     
     
  15. Like
    dfay got a reaction from Bernardo_V in Fuzzy, self-updating list filter workflow template   
    # fuzzylist
    Fuzzy, self-updating list filter workflow for Alfred 3
    This is a workflow template - it does nothing as is.
     
    ## Usage:
    - create a csv file like you would for an Alfred List Filter
    - name the file *list.csv* and add it to the workflow directory
    On the initial run, the workflow will create a file list.json for output to the fuzzy search.  If list.csv is modified, it will update list.json .  
     
    ## Credits
    - uses fuzzy.py by @deanishe - https://github.com/deanishe/alfred-fuzzy
     
    ## Download
     
    workflow at https://github.com/derickfay/fuzzylist/blob/master/Fuzzy List Filter.alfredworkflow
  16. Like
    dfay reacted to luckman212 in Include object notes in search   
    This is an excellent idea!  Another related thing on my wish list would be a dedicated "Notes" object, which ideally would be a resizable rectangle that could display text notes on the workflow editor area. Something like this:
     

  17. Like
    dfay got a reaction from luckman212 in Include object notes in search   
    It would be great if the preferences search could (optionally) include the notes field of workflow objects.  I have a lot of Hotkey triggers that call scripts, so there's no text that I could search for except the descriptions I've added to the objects.  Here's an example of where this feature would be useful:
     
     
     

  18. Like
    dfay got a reaction from vitor in SwitchAgent — Switch the user agent for your frontmost browser   
    I never needed this until now, but I'm thrilled to see there's a working Alfred-based solution
  19. Like
    dfay reacted to Jasondm007 in Script Filter Output - A Very Basic Question   
    @dfay, @vitor & @deanishe - Thanks for taking the time out to help a coding neophyte, like myself. I really appreciate it. Honestly, I can't thank you guys enough.
     
    Alfred's great, but it wouldn't be the first thing I'd install on a Mac, if it weren't for you guys and others on the forum. I've learned a ton from you guys!
     
    For others who may be struggling with script filters and JSON outputs, I've uploaded a new version of the workflow to use as a learning example: Download Workflow. 
    The workflow combines everyone's suggestions from above: AppleScript, JavaScript & Ruby. All three are nearly identical, with the exception that the JavaScript and Ruby versions lack the prefix "Same Words" in the subtitle. This should be enough to get you started, if you're also struggling to get your head around how script filters' outputs work.
  20. Like
    dfay reacted to Jasondm007 in Script Filter Output - A Very Basic Question   
    @vitor Thanks a ton for the explanation and the two working examples. This was extremely helpful, and it got me thinking that I could probably figure out a way to use my existing AppleScript to generate the list and then feed it into your JavaScript or Ruby script filter examples? It's a pretty complicated AppleScript - for my scripting ability, anyways - that generates the list. To be sure, I don't disagree with any of your statements - or others' on this forum - about AppleScript's 💩 status. But it would take me ages to learn one of these better languages, and then reverse engineer the existing AppleScript. As you can tell, I hardly understand AppleScript 😉
     
    @dfay Thanks for the sources above! One of the first failed variations that I mentioned above came from my hackneyed attempts at pulling out pieces of your windows workflow (the one that works for Preview and a few others apps). When @deanishe mentioned a json.scpt file, I knew that I had seen one in your workflow, so I used it in several iterations. But I could never get any of them to work. However, I completely forgot about your more streamlined workflows for only Preview and Finder. In the multi-app version, I think stringing all those variables together for the different apps got me a little turned around. In any case, I'll go back and take a look at those other versions. Thanks a ton!!
     
    I can't thank you both enough!!
  21. Thanks
    dfay got a reaction from Jasondm007 in Script Filter Output - A Very Basic Question   
    Or to continue with AS, look at the examples here:
     
     
    This is what I used to figure out how to do the recent folders and active folders scripts in 
     
     
     
     
     
    And here's a solution for you:
     
    set theList to {"Red", "Green", "Blue"} # What next? -- import JSON library set workflowFolder to do shell script "pwd" set json to load script POSIX file (workflowFolder & "/json.scpt") -- Create and add items set theItems to {} repeat with i from 1 to count theList set end of theItems to json's createDictWith({{"title", (item i of theList) as text}, {"uid", i},{"arg", (item i of theList) as text}, {"subtitle", "Same Words " & (item i of theList) as text}}) end repeat -- Create root items object and encode to JSON set itemDict to json's createDict() itemDict's setkv("items", theItems) return json's encode(itemDict)  
  22. Like
    dfay got a reaction from moonshot in Clipboard snippets on iOS (iPhone/iPad)? Remote?   
    Sure, but it might take me a week or two before I can get it written up. Feel free to nag me.
  23. Like
    dfay got a reaction from moonshot in Clipboard snippets on iOS (iPhone/iPad)? Remote?   
    I believe this is a problem with iOS 12 Shortcuts and Dropbox.  See https://talk.automators.fm/t/shortcuts-and-dropbox/1917
     
    If you have TextExpander and TE Touch (last non-subscription versions) it's possible to use Hazel and AppleScript to do a one-way sync of snippets from Alfred to TE on the Mac and then use TE Touch on iOS.  At least it works for me - I can provide docs and scripts if there's interest.
  24. Like
    dfay got a reaction from luckman212 in Enumerate all defined Hotkeys across workflows?   
    see keyword hot in
     
     
  25. Thanks
    dfay reacted to biati in Calculate Anything   
    Calculate Anything is a workflow for Alfred 4, that uses natural language and is able to calculate multiple things like currency, time, vat, percentage, etc.
     
    Why?

    There are several workflows out there but i just needed a workflow that worked naturally for example you can open alfred and type 100 + 9 and alfred will give you a result no need for keywords or hotkeys it just works, i wanted to be able to jus type 100 + 16% or 100 euros to usd or 100km to cm or 100 years to hours and a large etc. and so this workflow was created.
     
    Features

    - Natural language - type 100 euros to dollars or 100 euros in usd or 100€ to $ or 100eur usd or 100 euros a dolares. It does not matter, the same result will be displayed.
    - Currency - Up to 168 currencies
    - Cryptocurrency - Support for 100 cryptocurrencies
    - Units - 100 kilometers to meters or 100km to m or maybe 100km m
    - Percentages - 100 + 16% | 100 - 16% etc.
    - PX,Em,Rem,Pt - 12px or 12px to em or 12px pt
    - Time - time +15 years? now plus 15 hours? or need to convert a timestamp?
    - VAT - value added tax calculations, we all need this
    - Translations You can create your own translations to display results in your language
    - Keywords Extend the natural language in the queries so you can type 100 dolares a pesos and the code will see 100usd to mxn
     
    Important
    You will always find the latest version, changelog and updated documentation on Github as is difficult to use the forum to keep track of updates and support. 
     
    Download

    Download directly from Github releases page, make sure to download the latest release. Download here
     
    Base Configuration

    There's only one global configuration and is the language, this configuration will be used to display the messages in your own language. View the Translations secction for the available languaes.
    Configure it with.
     
    calculate configure and select Set base language and enter the language for example es_ES For more information about configuration click here
     
    Currency
     
    You can use natural language or type a few characters and that's all, for example:
    100 usd to mxn 100$ in mxn 100€ to $ 100 euros to dollars 100 euros a dolares (you can also write it in your own language) 100eur (If no target the currency will be converted to the base currency that you configured)  
    All this examples will simply work, you can add spaces between the value and the currency or don't.
     

     
    If by any chance you don't remember the currency symbol or abbreviation simply type calculate list and select "List Available Currencies" (view the gift above)
     
    Currency Options
     
    By default the workflow will use exchangerates api to make the conversion, exchangerates has only support for 32 currencies, if you need support for all the currencies that this worflow includes you need to get a FREE API Key from https://fixer.io it takes less than a minute.
     
    The following options are available for the currency. Simply launch Alfred and type calculate configure and select any of the options below. View the configuration section for more info
     
    Set base currency
    This will become your base currency, if you type 100eur it will automatically be converted to mxn, examples of currency (USD, EUR, MXN, CAD, etc)
     
    Set currency locale
    Used to give format to the converted amount using the money format of your contry
     
    Set Fixer API
    Set your fixer API Key for support more currencies
     
    Currency Symbols
     
    You can also use currency symbols in your query for example 100¥ to € will be converted to 100JPY to EUR, here is a list of available symbols.
     
    Please go to the repo description on Github for a full list of supported symbols it's really difficult to write them here in the forum. View Currency Symbols
     
    Cryptocurrency
    You can use this in conjunction with currency to convert 100 cryptocurrencies to up to 168 currencies, again you can use natural language or simply pass the currency symbol and that's all.
     
    2 bitcoin to dollars 0.1 bitcoin in dollars 5 bitcoins in ethereum 1 ethereum to ¥ 10 ethereum in mxn 1eth btc 1btc (If no target the currency will be converted to the base currency that you configured)  
    Cryptocurrency Options
    You need to get a FREE API Key from https://coinmarketcap.com/api/pricing/ it takes less than a minute.
    The following options are available for cryptocurrency. Simply launch Alfred and type calculate configure and select any of the options below. View the configuration section for more info
     
    Set Coinmarketcap API
    Select this option and paste your API key and press enter to save it.
     
    Units
     
    You can write your query using natural language or just a few characters, either way this workflow will give you the result you need.
     
    100 ounces to kilograms 100oz to kg 100oz = kg 100oz kg 10 years to months 10years to seconds 1 year to sec 1hr s 10 días a horas (use your own language)  
    If you don't remember the unit abbreviation just simply type the name for example instead of "oz" you can type "ounce" or "ounces" or even use words in your own language for exaple "onza" or "onzas" in spanish.
     

     
    Finally if you still don't remember the unit abbreviation or it's name simply type calculate list and select "List Available Units" you can type to filter, etc.
    Please go to the repo description on Github for a full list of units it's really difficult to write them here in the forum. View Units
     
    Units Options
     
    The following options are available. Simply launch Alfred and type calculate configure and select any of the options below. View the configuration section for more info
     
    Set System of Measurement
    Here you can define your System of Measurement, this option is still in development but as the workflow grows this might be necessary for US users, by default the metric system will be used but you can define imperial or metric
     
    Percentages
     
    You can easily calculate percentages for example:
     
    15% of 50 = 7.50  //7.5 equals to 15% of 50 120 + 30% = 156  //120 plus the 30% of 120 120 plus 30% = 156  //120 plus the 30% of 120 120 - 30% = 84  //120 minus the 30% of 120 120 minus 30% = 84  //120 minus the 30% of 120 30 % 40 = 75%  // 30 is 75% of 40.  
    Translations and natural language can also be used
    120 más 30% = 156  

     
    Time
     
    Time is triggered by a keyword because is not often used so you can simply open alfred and type time
     
    Gives you the current time
    time  
    Converts the timestamp to a regular date
    time 1577836800  
    Gives you the time from now plus anything you want
    time +15 days time now plus 3 days  
    Number of days until specified date
    time days until 31 december  
    The start date of current year
    time start of year  
    The start date of specified year
    time start of 2021  
    The end date of current year
    time end of year  
    The end date of specified year
    time end of 2021  
    It also works in your language
    time inicio de 2020 time fin de 2020 time dias hasta 31 diciembre  
    Get information about date
    time 31 December, 2021 18:00:00 time 31/12/2021 18:00:00 time 12/31/2021 18:00:00  
    Calculate the difference between two dates
    time 25 December, 2021 - 31 December, 2021 time 31-11-2019 - 21-11-2019 time 11/31/2019 - 11/21/2019  

     
    Time Options
     
    The following options are available. Simply launch Alfred and type calculate configure and select any of the options below. View the configuration section for more info
     
    Set base timezone
    Base time zone to calculate dates in your time for example (America/Los_Angeles, Mexico/General, etc.)
     
    Add date format
    Configure a new date format so the date is displayed the way you want for example (j F, Y, g:i:s a)
     
    Delete date format
    It will show you a list of configured date formats, simply select the one you want to delete and press enter to remove it
     
    Time will use the language that you configure with Set base language
     
    VAT (value added tax)
     
    With this you can calculate the vat of a given amount. Like time, vat is also triggered with the keyword "vat" you can change the keyword in the workflow.
     
    Given the following query
    vat of 400 (with 16% vat configured, you can configure your own percentage)
     
    You will get
    VAT of 400 = 64 // VAT Amount 400 plus VAT = 464 // Amount plus vat 400 minus VAT = 344.82 // Amount minus vat  
    VAT Options
    The following options are available. Simply launch Alfred and type calculate configure and select any of the options below. View the configuration section for more info
     
    Set VAT percentage for example (16%)
     
    Configuration
     
    You can easily configure the workflow simply by opening Alfred and typing calculate configure you will see a list of all the available options to configure the workflow, select the option you want and press enter then simply enter your value and again press enter to save it. Check the following gif if you have doubts.
     

     
     
    Translations
     
    Please check the available languages on Github, it's easier to update the information there and also how you can create  a translation.
     
    Keywords
     
    Keywords are words that can be used when writing a query in natural language for example a keyword "ounces" will be converted to "oz", "kilometers" will be converted to "km" or "dollars" will be converted to "USD", "seconds" will become "s" and a large etc. This keywords allows the user to type in a more natural way and in their own language. You can write your own keywords to extend the functionality, please check the information on Github.
     
    Stop Words
     
    Stop words are words that can be used in the query when using natural language for example "100km to cm" - here the stop word is "to"
     
    Stop words are useful for two things:
     
    Allows the user to write more naturally and in their own language (e.g 100 dolares a mxn) "a" is the stop word Are used to check if the query has to be processed for example:  
    100km equals meters
     
    if the word "equals" is not registered in the stop_words array then it won't be processed. At the end this stop words are removed so 100km to cm becomes 100km cm.
     
    Please take a look at the readme on Github to learn more about this.
     
    For Currency, Percentages and Units this workflow will only process the query if it begins with a digit and it has at least 3 characters. Time and VAT have a keyword because those are not often used.
     
    Updates
     
    Updates are installed automatically when a new version is released you don't have to do anything but if want you can check for new updates manually just launch Alfred and type calculate update the workflow will check for updates and it will let you now if there are any updates available.
×
×
  • Create New...