Skip to main content

sire

sire is a command that generates Python 3.7 project templates, with git, travis, mypy (etc.) support.

Version 1.0.4

Build Status codecov.io readthedocs PyPI version Code style: black

Install sire

pip install sire
#or
git clone https://github.com/interrogator/sire && cd sire && python.setup.py install

Usage

sire --mkdocs --virtualenv --git --exclude=mypy <project_name>

As Python module:

python -m sire.sire mkdocs virtualenv <project_name>

Or from inside Python (why?):

from sire import sire
sire('project_name', mkdocs=True, virtualenv=True, git=True)

What gets generated

Pure Python:

  • <project_name>/<project_name>.py
  • <project_name>/__init__.py
  • setup.py
  • requirements.txt (with black, isort, flake8 etc)
  • tests/tests.py

Optional extras:

  • mkdocs (.readthedocs.yaml, ./docs, .mkdocs.yml)
  • irtualenv (with dependencies installed)
  • git (.git, .gitignore, .pre-commit-config.yaml)

Each of these has an associated flag:

sire -v/--virtualenv -m/--mkdocs -g/--git projname

Other files

  • .coveragerc
  • .travis.yml
  • publish.sh (a script for running tests and authoring a new version)
  • mypy.ini
  • MIT License
  • Empty CHANGELOG
  • .bumpversion.cfg

If you want to skip any of these files, use the --exclude option with comma separation:

sire --exclude=travis,setup.py,mypy projname

Trivia

  • sire actually generated itself.

Contributing

I don't really expect many other people to want this, because it's mostly tailored to my specific ideas about how a Pthon project should look. That said, if you do find this projet useful, you are more than welcome to submit pull/feature requests!

There are dozens of possible new features that could be added, which I'd personally quite like:

  • a --license option, to choose the correct license file
  • Setting git remote automatically (get github username from git global config?)
  • Deleting irrelevant strings --- if no codecoverage, remove the associated badge for example
  • Probably more code could be automatically generated and added for the main and test .py files

While I'd love to have these in sire, coding them will take me longer than doing it manually a few times. So, unless this repo somehow becomes popular or finds some new contributors, don't expect any of this stuff to get done in a hurry, unless you add it yourself.

Metadata

Release files for sire 1.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for sire 1.0.4
File Size Uploaded
sire-1.0.4.tar.gz 11.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for sire 1.0.4
File Interpreter ABI Platform
sire-1.0.4-py3.6.egg Legacy Egg format - - Details

Total release size: 30.9 kB

Release files / sire-1.0.4.tar.gz

Download URL sire-1.0.4.tar.gz
Size 11.5 kB
Tags Source
SHA-256 checksum
How to use checksums
0d325b0b367dc4d1b251a42c478a66b7b23cf5ceb03c7bf983700eb334b4419e
BLAKE2b-256 checksum
How to use checksums
9d3422b7e37173c471b7cc36de87144e2c11a395b73b2dc90a6b99ddd741ea82
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.18.4 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.7

Release files / sire-1.0.4-py3.6.egg

Download URL sire-1.0.4-py3.6.egg
Size 19.4 kB
Tags Egg
SHA-256 checksum
How to use checksums
971e27966dd6fa19affb9a8e85c5d7f9e248fffa5bc2edf47d335c793fdd1b78
BLAKE2b-256 checksum
How to use checksums
d11086371063cca65450ed33da09d16955aa881f6294b3bd4ef7ef7966e07449
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.18.4 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.7

Release history Release notifications | RSS feed

This release

1.0.4 This release

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

0.0.5

2 release files

0.0.4

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page