Skip to main content

@only.<OS> decorator. raise OSError if not supported OS

Project description

https://img.shields.io/pypi/pyversions/only.svg?maxAge=86400

https://www.codefactor.io/repository/github/looking-for-a-job/only.py/badge https://codeclimate.com/github/looking-for-a-job/only.py/badges/gpa.svg https://img.shields.io/scrutinizer/g/looking-for-a-job/only.py.svg https://bettercodehub.com/edge/badge/looking-for-a-job/only.py?branch=master https://sonarcloud.io/api/project_badges/measure?project=only.py&metric=code_smells

Install

`[sudo] pip install only`

Usage

>>> import only

>>> @only.linux
>>> @only.osx
>>> @only.unix
>>> @only.windows

Examples

>>> @only.osx
>>> def osascript(): pass

>>> osascript() # raise OSError if not OS X

https://img.shields.io/github/followers/looking-for-a-job.svg?style=social&label=Follow&maxAge=86400 https://img.shields.io/github/stars/looking-for-a-job/only.py.svg?style=social&label=Stars&maxAge=86400 https://img.shields.io/github/issues/looking-for-a-job/only.py.svg?maxAge=86400

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

only-1.0.1.tar.gz (1.8 kB view details)

Uploaded Source

File details

Details for the file only-1.0.1.tar.gz.

File metadata

  • Download URL: only-1.0.1.tar.gz
  • Upload date:
  • Size: 1.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for only-1.0.1.tar.gz
Algorithm Hash digest
SHA256 2bc02668d43065a0d3c73f5af4cc42a7dda00369bf5e3ea579a30cba2fc5e737
MD5 ba9e1f702643871a700eed74befa0293
BLAKE2b-256 8a362ba834db700725c6d6452e96534d5049a70b83d215f7da8283756a70d452

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page