-
Notifications
You must be signed in to change notification settings - Fork 237
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add new utility functions & refactor
Helpers ------- Add new utility functions for running commands and scripts Move some helpers to util.py Workflow -------- Write '.' to debugger on start, so real log messages start on a new line Use root logger instead of 'workflow' Add warn_empty() method to Workflow3 Rebuild workflow and docset
- Loading branch information
Showing
16 changed files
with
958 additions
and
321 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
|
||
.. _api-util: | ||
|
||
Utilities & helpers | ||
------------------- | ||
|
||
|
||
.. currentmodule:: workflow.util | ||
|
||
A collection of functions and classes for common workflow-related tasks, such | ||
as running AppleScript or JXA code, or calling an External Trigger. | ||
|
||
|
||
.. autofunction:: utf8ify | ||
|
||
.. autofunction:: applescriptify | ||
|
||
.. autofunction:: run_command | ||
|
||
.. autofunction:: run_applescript | ||
|
||
.. autofunction:: run_jxa | ||
|
||
.. autofunction:: run_trigger | ||
|
||
.. autoclass:: AppInfo | ||
|
||
.. autofunction:: appinfo | ||
|
||
|
||
Other helpers | ||
^^^^^^^^^^^^^ | ||
|
||
These utility classes and functions are used internally by Alfred-Workflow, | ||
but may also be useful in your workflow. | ||
|
||
.. autoclass:: LockFile | ||
:members: | ||
|
||
.. autoclass:: uninterruptible | ||
:members: | ||
|
||
.. autofunction:: atomic_writer | ||
|
||
|
||
.. _api-util-exceptions: | ||
|
||
|
||
Exceptions | ||
^^^^^^^^^^ | ||
|
||
The following exceptions, may be raised by utility functions. | ||
|
||
.. autoexception:: AcquisitionError | ||
|
||
.. autoexception:: subprocess.CalledProcessError |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.