bvtsu / affirmation

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Affirmations

A module that gives you a little bump of encouragement.

Requirements

  • A positive attitude
  • A can-do spirit

Installation

pip install Affirmations

Usage

Decorate any function to get a random affirmation printed to stdout every time that function is run

from Affirmations import affirm

@affirm() # prints an affirmation to stdout 100% of the time this function is run
def hello_world():
    print("hello")

@affirm(0.2) # prints an affirmation to stdout 20% of the time this function is run
def hello_world2():
    print("hello")

hello_world()
hello
You are awesome!

About

License:MIT License


Languages

Language:Python 100.0%