Jump to content

Search the Community

Showing results for tags 'deanishe'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

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

Categories

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

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Twitter


Website URL


Jabber


Location


Interests

Found 1 result

  1. AwGo — A Go library for Alfred workflows Full-featured library to build lightning-fast workflows in a jiffy. https://github.com/deanishe/awgo Features Easy access to Alfred configuration, including populating a struct from workflow variables and persisting settings back to info.plist. Straightforward generation of Alfred JSON feedback. Support for all applicable Alfred features up to v3.5. Fuzzy sorting/filtering. Simple API for caching/saving workflow data. Catches panics, logs stack trace and shows user an error message. Workflow updates API with built-in support for GitHub releases. Built-in logging for easier debugging. "Magic" queries/actions for simplified development and user support. macOS system icons. Installation & usage Install AwGo with: go get -u github.com/deanishe/awgo/... Typically, you'd call your program's main entry point via Run(). This way, the library will rescue any panic, log the stack trace and show an error message to the user in Alfred. program.go: package main // Package is called aw import "github.com/deanishe/awgo" // Workflow is the main API var wf *aw.Workflow func init() { // Create a new Workflow using default settings. // Critical settings are provided by Alfred via environment variables, // so this *will* die in flames if not run in an Alfred-like environment. wf = aw.New() } // Your workflow starts here func run() { // Add a "Script Filter" result wf.NewItem("First result!") // Send results to Alfred wf.SendFeedback() } func main() { // Wrap your entry point with Run() to catch and log panics and // show an error in Alfred instead of silently dying wf.Run(run) } In the Script Filter's Script box (Language = /bin/bash with input as argv): ./program "$1" Documentation Read the docs on GoDoc. Check out the example workflows (docs), which show how to use AwGo. Use one as a template to get your own workflow up and running quickly. Running/testing The library, and therefore the unit tests, rely on being run in an Alfred-like environment, as they pull configuration options from environment variables (which are set by Alfred). As such, you must source the env.sh script in the project root or run unit tests via the run-tests.sh script (which also sets up an appropriate environment then calls go test). Licensing & thanks This library is released under the MIT licence. The icon is based on the Go Gopher by Renee French.
×
×
  • Create New...