feat: publish package to pypi workflow and rename package to djinitx

This commit is contained in:
sankalp committed 2025-10-29 13:42:46 +05:45
1 parent 937caf600b
commit cb89795077
4 files changed
+55 -4

No files matched your search

+2 -2
View File
@@ -31,11 +31,11 @@ jobs:
- name: Lint with Ruff - name: Lint with Ruff
run: | run: |
ruff check src/ ruff check djinit/
- name: Check formatting with Ruff - name: Check formatting with Ruff
run: | run: |
ruff format --check src/ ruff format --check djinit/
- name: Test CLI import - name: Test CLI import
run: | run: |
+39
View File
@@ -0,0 +1,39 @@
name: Release
on:
push:
tags:
- 'v*'
jobs:
build-and-publish:
name: Build and Publish to PyPI
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build twine
- name: Build package
run: |
python -m build
- name: Check package
run: |
twine check dist/*
- name: Publish to PyPI
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
run: |
twine upload dist/*
+12 -1
View File
@@ -1,5 +1,5 @@
[project] [project]
name = "djinit" name = "djinitx"
version = "0.1.0" version = "0.1.0"
description = "A CLI tool to setup Django project" description = "A CLI tool to setup Django project"
readme = "README.md" readme = "README.md"
@@ -8,6 +8,17 @@ authors = [
{ name = "Sankalp Tharu", email = "sankalptharu50028@gmail.com" } { name = "Sankalp Tharu", email = "sankalptharu50028@gmail.com" }
] ]
license = { text = "MIT" } license = { text = "MIT" }
keywords = [
"django",
"cli",
"project",
"djinit",
"djinitx",
"dj",
"django-init",
"django project",
"django starter"
]
classifiers=[ classifiers=[
"Programming Language :: Python", "Programming Language :: Python",
"Programming Language :: Python :: 3", "Programming Language :: Python :: 3",
+2 -1
View File
@@ -1,7 +1,7 @@
from setuptools import find_packages, setup from setuptools import find_packages, setup
setup( setup(
name="djinit", name="djinitx",
version="0.1.0", version="0.1.0",
description="A CLI tool to setup Django projects", description="A CLI tool to setup Django projects",
long_description=open("README.md").read(), long_description=open("README.md").read(),
@@ -49,6 +49,7 @@ setup(
"cli", "cli",
"project", "project",
"djinit", "djinit",
"djinitx",
"dj", "dj",
"django-init", "django-init",
"django project", "django project",