Skip to content

Alfred snippets#37

Merged
warpling merged 5 commits into
warpling:masterfrom
valrus:alfred-snippets
Mar 13, 2017
Merged

Alfred snippets#37
warpling merged 5 commits into
warpling:masterfrom
valrus:alfred-snippets

Conversation

@valrus

@valrus valrus commented Mar 12, 2017

Copy link
Copy Markdown
Contributor

As promised, here's a script to generate Alfred snippets from the emoji template plist. I tested it by verifying that the output (.alfredsnippets file) loads correctly into Alfred 3.

A couple other things:

  • I included the output of the script in the root dir of the repo since I noticed there was also a .kmmacros file there.
  • I cleaned up update-km.py a little because I'm a stickler for Python idioms. In particular I but the main block of code in a main() function and switched from using Python's XML parser to one specifically intended for .plist files. I verified that it produces output identical to what was there before my changes.

@valrus

valrus commented Mar 12, 2017

Copy link
Copy Markdown
Contributor Author

Oh, I didn't update the README. But you should probably do that yourself.

@warpling

Copy link
Copy Markdown
Owner

You are awesome!! And the Python fixes are extra appreciated. Before I merge, you don't suppose there's a good, straight-forward way we could combine the macro scripts?

@valrus

valrus commented Mar 13, 2017

Copy link
Copy Markdown
Contributor Author

Depends on what you mean by "straightforward" and "combine." 😛

I'm guessing you mean just regenerate both the .km output (and anything else in the templates) and the Alfred output at the same time? That would be simple enough.

@valrus

valrus commented Mar 13, 2017

Copy link
Copy Markdown
Contributor Author

OK, updated. The new script is just update-output.py and it does what update-km.py and update-alfred.py used to do.

@warpling

Copy link
Copy Markdown
Owner

Perfect—Thank you!! 😃

@warpling warpling closed this Mar 13, 2017
@warpling warpling reopened this Mar 13, 2017
@warpling warpling merged commit 4b6b55c into warpling:master Mar 13, 2017
@warpling warpling mentioned this pull request Mar 13, 2017
@valrus valrus deleted the alfred-snippets branch March 13, 2017 02:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants