#python #project-management #cli #build #skeletons #account #pypi

app hajime

A Rust CLI tool to create Python project skeletons

16 releases

0.3.12 Apr 11, 2025
0.3.11 Apr 10, 2025
0.3.10 Jan 21, 2025
0.2.2 Jan 16, 2025
0.1.0 Jan 16, 2025

#287 in Command line utilities

Download history 860/week @ 2025-01-15 149/week @ 2025-01-22 4/week @ 2025-02-05 7/week @ 2025-02-12 255/week @ 2025-04-09 16/week @ 2025-04-16 5/week @ 2025-04-23

276 downloads per month

MIT license

31KB
674 lines

Hajime (始め)

hajime is a lightweight Rust CLI tool designed to quickly create and manage Python project skeletons.

Installation

cargo install hajime

Or, to install hajime locally, clone this repository and run:

cargo install --path .

Make sure ~/.cargo/bin is in your PATH.

Usage

Create a New Python Project

Run the following command to create a new Python project:

hajime new project_name

This creates the following structure:

project_name/
├── README.md
├── pyproject.toml
├── project_name
│   ├── __init__.py
│   └── main.py
├── tests
│   ├── __init__.py
│   └── test_main.py

Build the Project

To build the Python project into a wheel:

hajime build

This runs python3 -m build and will package your project and place the distribution files (e.g., .tar.gz and .whl) in the dist/ directory.

Check the build

To check the build, run:

hajime check

Publish the Project to PyPI

To publish your project to PyPI, run the following command:

hajime publish

By default, hajime will use the default account stored in your system's keyring. You can specify an account or override the stored token:

Specify an Account

hajime publish --account account_name

Override the Token for an Account

hajime publish --account account_name --override-token

This will:

  1. Prompt you to enter a new token.
  2. Save the token securely in the keyring.
  3. Publish the package to PyPI.

Notes

  • Ensure you have built the project first using hajime build or python3 -m build.
  • If the required build or twine packages are missing, install them with:
    pip install build twine
    
  • For accounts, hajime securely stores your PyPI API tokens in your system's keyring (e.g., macOS Keychain, Windows Credential Manager, or Linux Secret Service).

Dependencies

~3–14MB
~132K SLoC