Jump to content

Search the Community

Showing results for tags 'scripts'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • Alfred 3
  • Make the Most of Alfred
    • Discussion & Help
    • Bug Reports
    • Alfred Feature Suggestions
    • Themes
  • Alfred Workflows
    • Share your Workflows
    • Workflow Help & Questions
    • Workflow Advanced Tips & Tricks
    • Workflow Automation Tasks
  • Alfred Themes
  • Alfred Remote for iOS
    • Alfred Remote Discussion & Help
    • Remote Connection Troubleshooting
  • Alfred 5 Early Access
    • Alfred 5 Early Access


  • Articles
    • Forum Integration
    • Frontpage
  • Pages
  • Miscellaneous
    • Databases
    • Templates
    • Media

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start




Website URL




Found 12 results

  1. Under Workflows if I select and edit a script object. There is a drop down list of shells and interpreters called Language, however, you cannot customise them. At the moment the main reason for wanting to do this is to change to /usr/bin/python3 Python2 is to be removed soon and most languages from default macOS installations at a later date(s). This was mentioned in Catalina’s notes as depreciations. This means in the future people will be using Conda, Homebrew etc to add languages to their systems unless Alfred plans to included runtimes. I actually use Homebrew to get newer versions of python, zsh and bash these are a different paths. I just wonder if there is currently a way to add and change them? Some people also use tools like asdf, pyenv, rvm, direnv etc to manage multiple versions of languages.
  2. This workflow is designed to work with the NotePad script for TextBar. NotePad is a group of nine notepads that sit in your menubar. You can tuck information away, run scripts on the text, or regular expression edits. There are around 37 pre-made scripts for editing your notes. You can create and add your own scripts as well. The topmost actions require you to set the noteID variable to the right. It can be 1 through 9 to represent the note that the text will be appended/written to. The actions will append or overwrite depending on the status of the append variable to the right. If set to 'a', it will append. If set to 'w', it will over-right the text. The last group of actions is for pasting a note to the topmost application. You can either give a number for the note or just paste the note that corresponds to the noteID parameter for the workflow. Download: https://github.com/raguay/MyAlfred/blob/master/Alfred 3/NotePadWorkflow.alfredworkflow
  3. Is there a way to call a script from a snippet or inversely trigger a workflow with a snippet?
  4. I love Alfred but I struggled at first to troubleshoot my workflow scripts due to difficulty finding a way to debug. I've seen posts mentioning writing logs to an external file but that seemed hack-y, especially since Alfred includes a debug console. If you'd like to use the console to debug your scripts, I found the following very useful. It would be great if there were a mention of this in the docs: To show script output in the debug console, print (or echo or put, etc) the output to stderr instead of stdout. In a Bash script: >&2 echo "Log this output to the console" In a Python script: import sys sys.stderr.write("Log this to the console") For other languages, look for an equivalent method that allows you to log to stderr.
  5. Hello Alfred Community, I have used Alfred quite a bit and I am all of a sudden having problems running my alfred workflows that have a python script in them. I have had others send me scripts that work flawlessly and others that have not worked. When I create or run a workflow there is no action taken, but if I put a result like post notification then it will execute that result without running the python script. Any suggestions or help?
  6. Is there a way to map output actions to specific items without having to use action modifiers? I have a script filter that I am using in alfred and I want each item to have its own return output. For example, if I press enter on the first item, I want it to copy to the clipboard and post a notification. I want the second and third item to not return anything. I want the third item to launch terminal when the user hits enter. I want the fourth item to launch a webpage when the user hits enter. IP=$(host google.com | cut -c 30-) CITY=$(curl http://ipinfo.io/$IP/city) STATE=$(curl http://ipinfo.io/$IP/region) PROVIDER=$(curl http://ipinfo.io/$IP/org | cut -c 8-) //Start Display cat<<EOB <?xml version="1.0"?> <items> //Remote Server's IP <item arg="$IP" valid="NO"> <title>Remote Server's IP: $IP</title> <subtitle> Press Cmd + C to copy </subtitle> <subtitle mod="cmd">Cmd + C to Copy</subtitle> <text type="copy">$IP</text> <icon>69288C18-2A0D-4430-837E-4AB331CD2698.png</icon> </item> //Location (City, State, Country) <item arg="$CITY, $STATE" valid="NO"> <title>Location: $CITY, $STATE</title> <subtitle>This is Location of the Server</subtitle> <icon>icon.png</icon> </item> //ISP Provider <item arg="$PROVIDER" valid="NO"> <title>Provider: $PROVIDER</title> <subtitle>This is the ISP Provider</subtitle> <icon>Wired_Network-100.png</icon> </item> //SSH into server <item arg="$IP"> <title>SSH into Server</title> <subtitle>Press Enter to connect</subtitle> <icon>Connected-100.png</icon> </item> //Open Web Page <item arg="$IP"> <title>Connect to Web Server</title> <subtitle>Press Alt + Enter to connect</subtitle> <subtitle mod="alt">Launch Webpage</subtitle> <icon>Open in Browser-100.png</icon> </item> </items> EOB
  7. Hello! I found an AppleScript that allow to check and uncheck the "Use F1, F2 etc. as standard function keys" in the keyboard prefpane. I check the security preferences and Alfred is check in the accessibility tab. When I run it inside Script Editor it works but when running in alfred workflow editor I get errors. Could somebody help me ? Thanks Jad [INFO: alfred.workflow.trigger.hotkey] Processing output 'alfred.workflow.action.applescript' with arg '' [ERROR: alfred.workflow.action.applescript] { NSAppleScriptErrorAppName = "System Events"; NSAppleScriptErrorBriefMessage = "Can\U2019t get checkbox 1 of tab group 1 of window 1 of process \"System Preferences\". Invalid index."; NSAppleScriptErrorMessage = "System Events got an error: Can\U2019t get checkbox 1 of tab group 1 of window 1 of process \"System Preferences\". Invalid index."; NSAppleScriptErrorNumber = "-1719"; NSAppleScriptErrorRange = "NSRange: {90, 47}"; } Here is the small script in question: tell application "System Events" to tell process "System Preferences" click checkbox 1 of tab group 1 of window 1 end tell quit application "System Preferences"
  8. I have spent almost 8 hours on this and I know it's an easy fix. I want to use this fork of the Sonos Ruby gem. The problem: I don't know how to require/include the gem, neither locally as a cloned copy or as a regular "require gem_name". The script runs fine in IRB, but when I try to run it in a workflow the sound doesn't pause. I thought it might be because my system Ruby is old, but I use Mavericks so that shouldn't be a problem. You can download the Workflow here from my Dropbox. And here's a SO question with more info, too. Any help is really appreciated. I am ready to tear my hair out on this.
  9. Hi everyone! So apologies if this is a crazy question, but I'm having a little trouble understanding how to pass data between scripts. In my first php script, I successfully copy a url to the clipboard (that works great). What I'd like to do now is pass that url onto the second PHP script so I can use it in another way. 1. I'm not quite sure how to have the second script run AFTER the first one. 2. I'm not sure what variable to use to pass the output on, I know it's not {query}, but is there something similar?
  10. I'm using Alfred App 2 and storing my preferences in a Dropbox folder. It's not picking up files that I have in the extensions and scripts folder under this folder though. When I try to type the keywords for these they do not come up. They were coming up in Alfred App 1. I was using this same Dropbox folder with v1. I've tried clearing the app cache and rebuilding osx metadata. Alfred version: 2.0.3 (187) OS X version: 10.8.3
  11. Hey guys, I'm creating a workflow that will search a (guitar tab database) website for the current song you are listening to iTunes. Unfortunately, I am very amateur with scripts. I hadn't really looked at one until today! I have a script that copies the song name and artist to my clipboard (using the line "set the clipboard to (nom & art)") however, I was wondering how you can get it instead to set "nom & art" to the query for the next step of the workflow? I know this is incredibly amateur, but thanks in advance for the help! Ned
  12. Hello, I am really new to scripts but I used some in Alfred v1. Scripts like Bluetooth-Toggle or Wi-Fi-toggle and AppleScripts like Starfish or Caffeine Manager. Now with version 2 beta I wanted to import some manually by copying the text. For Example: Bluetooth-Toggle I said Keyword (Input) and combined it with run script (Actions) Script: ./bluetooth.py Another Caffeine Manager: I said Keyword (Input) and combined it with run applescript (Actions) Script: (* This is an unofficial manager for Caffeine (http://lightheadsw.com/caffeine/) created by Sebastian of Zibity. It is an easy way to toggle Caffeine on and off. Usage: "caff" If you have any questions or suggestions, please send me a message via my website: http://www.zibity.com If you want more cool Alfred extensions like these, take a look at http://www.zibity.com/alfred.html for all of my other extensions. If you like this extension, please consider donating to support the continued development of things like this: http://donate.zibity.com *) --- SCRIPT BEGINS HERE --- try tell application "Caffeine" if active is false then turn on tell application "Growl" to notify with name "Extension Output" title "Caffeine has been activated." description "Caffeine Manager has activated Caffeine." application name "Alfred" identifier "caff" icon of application "Caffeine" else turn off tell application "Growl" to notify with name "Extension Output" title "Caffeine has been deactivated." description "Caffeine Manager has deactivated Caffeine." application name "Alfred" identifier "caff" icon of application "Caffeine" end if end tell end try Non of this ways really worked for me. Do you have any suggestions for me what I did wrong?
  • Create New...