Skip to main content

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

Project description

https://img.shields.io/badge/language-Python-blue.svg https://img.shields.io/pypi/pyversions/only.svg https://img.shields.io/pypi/v/only.svg

https://api.codacy.com/project/badge/Grade/fe6a6f03f9354ae391a907cdff85e47b 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://sonarcloud.io/api/project_badges/measure?project=only.py&metric=code_smells https://sonarcloud.io/api/project_badges/measure?project=only.py&metric=reliability_rating

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

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-0.0.32.tar.gz (2.2 kB view details)

Uploaded Source

File details

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

File metadata

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

File hashes

Hashes for only-0.0.32.tar.gz
Algorithm Hash digest
SHA256 96a13269219c92a4db4768a2c602efab0112f1bc754b374a44ec9265c23464b0
MD5 7b0b49f05eb575be72f7811576233a38
BLAKE2b-256 03b23180c4266e2fd882c7c825ba7cb72c7f4ba27d9ae07319c5e82eaa304b62

See more details on using hashes here.

Supported by

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