Installation
$ [sudo] pip install launchd-generator
$ [sudo] npm i -g launchd-generator
How it works
script.py -> script.py.plist, script.sh -> script.sh.plist
#!/usr/bin/env <interpreter>
KEY: VALUE
CUSTOM_KEY@type: VALUE # custom key. @type required - array/bool/integer/string
Features
- generate launchd.plist from any script
- define launchd.plist keys in script comments
Examples
agent.sh
#!/usr/bin/env bash
# StartInterval: 10
agent.sh.plist
<key>ProgramArguments</key>
<array>
<string>/path/to/agent.sh</string>
<string>/path/to/agent.sh.plist</string>
</array>
<key>StartInterval</key>
<integer>10</integer>
agent.py
#!/usr/bin/env python
"""
WatchPaths: ~/Desktop
WatchPaths: ~/Downloads
"""
agent.py.plist
<key>ProgramArguments</key>
<array>
<string>/path/to/agent.py</string>
<string>/path/to/agent.py.plist</string>
</array>
<key>WatchPaths</key>
<array>
<string>/Users/username/Desktop</string>
<string>/Users/username/Downloads</string>
</array>
$ cd ~/Library/LaunchAgents && find . \( -name "*.sh" -o -name "*.py" \) | xargs launchd-generator
Related
classifiers-generator- python classifiers generatorcommands-generator- shell commands generatorlaunchd-generator- launchd.plist generatorreadme-generator-README.mdgeneratorsetupcfg-generator-setup.cfggeneratortravis-generator-.travis.ymlgenerator
Links
Metadata
Release files for launchd-generator 2020.12.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| launchd-generator-2020.12.3.tar.gz | 3.2 kB | Without provenance | Details for launchd-generator-2020.12.3.tar.gz |
Release files / launchd-generator-2020.12.3.tar.gz
| Download URL | launchd-generator-2020.12.3.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
eb7a8bbba9948ceade21a07a0b5d6bc831fc263211e77ea682182b0afea030a4
|
|
BLAKE2b-256 checksum How to use checksums |
27f7c267dc3ff538cba5fb408b58c189638cc639c7d8d541b8b7d15d848369bf
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.6.0 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.6
|
Security for launchd-generator 2020.12.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.