Skip to content

gowtham_hello is a lightweight Python package that prints a greeting message. It serves as a basic example for creating, packaging, and distributing a Python module. This repository includes the package source code, setup instructions, and a test script to verify installation.

License

Notifications You must be signed in to change notification settings

gowthamgdn/gowtham_hello

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gowtham_hello

Overview

my_package is a simple Python package that provides motivational quotes. It includes a single function get_quote() that returns a random inspirational message.

Project Structure

gowtham_hello/
│── gowtham_hello/
│   ├── __init__.py  # Initializes the package
│   ├── main.py      # Contains the get_quote function
│── testing/
│   ├── test_main.py  # Contains test cases for the package
│── setup.py
│── requirements.txt  # Lists package dependencies
│── README.md
  • __init__.py: Initializes the package.
  • main.py: Contains the get_quote() function.
  • testing/test_main.py: Contains test cases for the package.
  • setup.py: Defines package metadata and dependencies.
  • requirements.txt: Contains necessary dependencies for installation.
  • README.md: Documentation for the package.

Installation

To install the package, use:

pip install .

To install dependencies from requirements.txt, run:

pip install -r requirements.txt

To create a distributable package, run:

python setup.py sdist bdist_wheel

This will generate a package file in the dist/ directory.

Usage

After installation, you can use the package as follows:

from my_package.main import get_quote

print(get_quote())

This will print a random motivational quote.

Testing

To test the installation, you can run:

python -c "from my_package.main import get_quote; print(get_quote())"

This should output a random quote from the list.

To run automated tests:

python -m unittest discover -s testing

This will execute all test cases in the testing/ directory.

Requirements

This package requires:

  • Python 3.x

Notes

  • Ensure setup.py contains the correct packages and install_requires fields.
  • Always install dependencies using requirements.txt to avoid version conflicts.
  • If issues occur, check dependencies and Python version.

Author

Gowtham Tadavarthy

License

This project is licensed under the MIT License.

About

gowtham_hello is a lightweight Python package that prints a greeting message. It serves as a basic example for creating, packaging, and distributing a Python module. This repository includes the package source code, setup instructions, and a test script to verify installation.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages