Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
muhammad-fiaz committed Nov 19, 2024
2 parents 1a302d2 + 4571d84 commit 3f12a18
Show file tree
Hide file tree
Showing 10 changed files with 486 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @muhammad-fiaz
15 changes: 15 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# These are supported funding model platforms

github: [muhammad-fiaz] # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
polar: # Replace with a single Polar username
buy_me_a_coffee: # Replace with a single Buy Me a Coffee username
thanks_dev: # Replace with a single thanks.dev username
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
11 changes: 11 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file

version: 2
updates:
- package-ecosystem: "pip" # See documentation for possible values
directory: "/" # Location of package manifests
schedule:
interval: "weekly"
169 changes: 169 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,169 @@

# IntelliJ project files
.idea
*.iml
out
gen
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
*.py,cover
.hypothesis/
.pytest_cache/
cover/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
.pybuilder/
target/

# Jupyter Notebook
.ipynb_checkpoints

# IPython
profile_default/
ipython_config.py

# pyenv
# For a library or package, you might want to ignore these files since the code is
# intended to run in multiple environments; otherwise, check them in:
# .python-version

# pipenv
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
# However, in case of collaboration, if having platform-specific dependencies or dependencies
# having no cross-platform support, pipenv may install dependencies that don't work, or not
# install all needed dependencies.
#Pipfile.lock

# poetry
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
# This is especially recommended for binary packages to ensure reproducibility, and is more
# commonly ignored for libraries.
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
#poetry.lock

# pdm
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
#pdm.lock
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
# in version control.
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
.pdm.toml
.pdm-python
.pdm-build/

# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
__pypackages__/

# Celery stuff
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/

# pytype static type analyzer
.pytype/

# Cython debug symbols
cython_debug/

# PyCharm
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/

43 changes: 43 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Code of Conduct

## Introduction

We, as contributors and maintainers, pledge to make participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.

## Our Standards

Examples of behavior that contributes to creating a positive environment include:

- Using welcoming and inclusive language
- Being respectful of differing viewpoints and experiences
- Gracefully accepting constructive criticism
- Focusing on what is best for the community
- Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

- The use of sexualized language or imagery and unwelcome sexual attention or advances
- Trolling, insulting/derogatory comments, and personal or political attacks
- Public or private harassment
- Publishing others' private information, such as a physical or electronic address, without explicit permission
- Other conduct that could reasonably be considered inappropriate in a professional setting

## Responsibilities of Maintainers

Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.

Maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned with this Code of Conduct or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.

## Scope

This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project maintainer. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant](https://www.contributor-covenant.org), version 2.0, available at [https://www.contributor-covenant.org/version/2/0/code_of_conduct.html](https://www.contributor-covenant.org/version/2/0/code_of_conduct.html).

For answers to common questions about this code of conduct, see [https://www.contributor-covenant.org/faq](https://www.contributor-covenant.org/faq).
67 changes: 67 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
<h1 align="center">
Setups Python
</h1>
<p align="center">
<img src="https://img.shields.io/pypi/v/setups.svg" alt="PyPI Version">
<img src="https://img.shields.io/github/license/muhammad-fiaz/setups-python.svg" alt="License Badge">
<img src="https://img.shields.io/pypi/pyversions/setups.svg" alt="Python Version">
<img src="https://img.shields.io/pypi/dm/setups.svg" alt="Downloads">
<img src="https://img.shields.io/github/issues-pr/muhammad-fiaz/setups-python.svg" alt="PRs">
<img src="https://img.shields.io/github/issues/muhammad-fiaz/setups-python.svg" alt="Issues">
<img src="https://img.shields.io/github/contributors/muhammad-fiaz/setups-python.svg" alt="Contributors">
<img src="https://img.shields.io/github/last-commit/muhammad-fiaz/setups-python" alt="Last Commit">
<img src="https://img.shields.io/github/commit-activity/m/muhammad-fiaz/setups-python.svg" alt="Commit Activity">
<img src="https://img.shields.io/github/license/muhammad-fiaz/setups-python.svg" alt="License Badge">
</p>

**Setups Python** is a Python CLI tool to generate a `setup.py` file for your Python project dynamically. It prompts the user for key project details like dependencies, license types, and classifiers.

## Features

- Generate a `setup.py` with interactive prompts
- Supports common open-source licenses
- Define project metadata including dependencies, version, and URLs
- Integrate with PyPI and other tools seamlessly

## Installation

```bash
pip install setups
```

## Usage

To create a `setup.py` file for your new project:

```bash
setup new <project_name>
```

## Example

```bash
$ setup new my-awesome-project
Version (e.g., 0.1.0): 0.1.0
Short project description: An awesome project
License type: MIT
Minimum Python version required: 3.8
Dependencies: numpy, requests
```

## Contributing

We welcome contributions! Fork the repository, create a feature branch, and submit a pull request. Please follow the steps below:

1. Fork the repository
2. Create a new branch: `git checkout -b feature-name`
3. Commit your changes: `git commit -am 'Add feature'`
4. Push to your fork: `git push origin feature-name`
5. Submit a pull request

## Code of Conduct

By participating in this project, you agree to follow our [Code of Conduct](CODE_OF_CONDUCT.md).

## License

MIT License. See the [LICENSE](LICENSE) file for more details.
47 changes: 47 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
from setuptools import setup, find_packages

VERSION = "0.0.1" # Version of your package
DESCRIPTION = 'Setups: Dynamically generate setup.py for Python projects.'

# Reading the long description from README.md if exists
try:
with open("README.md", "r", encoding="utf-8") as fh:
LONG_DESCRIPTION = fh.read()
except FileNotFoundError:
LONG_DESCRIPTION = DESCRIPTION # Fallback to DESCRIPTION if README.md is missing

setup(
name="setups", # Name of your package
version=VERSION, # Package version
author="Muhammad Fiaz", # Author name
author_email="contact@muhammadfiaz.com", # Author's email
description=DESCRIPTION, # Short description
long_description=LONG_DESCRIPTION, # Detailed description from README.md
long_description_content_type="text/markdown", # Format of the long description
url="https://github.com/muhammad-fiaz/setups-python", # URL to the project's GitHub page
packages=find_packages(), # Automatically find all packages in the directory
classifiers=[ # List of classifiers to categorize your package
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
],
python_requires='>=3.6', # Minimum Python version required
install_requires=[ # Dependencies needed to run the package
'click', # For creating command-line interfaces
],
setup_requires=['pytest-runner'], # For running tests during installation
tests_require=['pytest'], # Dependencies for running tests
license='MIT', # License for the project
project_urls={ # Additional URLs related to your project
'Source Code': 'https://github.com/muhammad-fiaz/setups-python',
'Bug Tracker': 'https://github.com/muhammad-fiaz/setups-python/issues',
'Documentation': 'https://github.com/muhammad-fiaz/setups-python#readme',
},
entry_points={ # CLI Entry Point
'console_scripts': [
'setup = setups.cli:generate_setup', # This links 'setup' command to generate_setup function
],
},
)
Empty file added setup/__init__.py
Empty file.
Loading

0 comments on commit 3f12a18

Please sign in to comment.