-
Notifications
You must be signed in to change notification settings - Fork 0
Developer Environment
- Python ≥ 3.9
-
uv(dependency manager) -
git(Obviously)
Install uv if missing:
curl -LsSf https://astral.sh/uv/install.sh | sh
- Fork the repository
- Clone it
- Sync dependencies (creates .venv automatically)
uv sync
- Activate venv
source .venv/bin/activate
You’re ready to develop.
pytest -v
(Add more tests gradually, don’t wait till the end.)
Use Google or reST style. Example:
def backup_files():
"""
Copies files listed in config.ini into the backup directory.
Returns:
bool: True if backup completed, False if skipped.
"""
pre-commit install
pre-commit run --all-files
Configured tools:
-
black→ formatting
Run latest code instantly:
pip install --editable .
Check which version is used:
which dotpush
When contributing:
- Create a branch: feature/
- Write clear commit messages
- Add tests for new features
- Format code before submitting
Warning
makepkg -si will fail inside virtual environment.
Reason: When inside .venv, makepkg accidentally uses that Python instead of system /usr/bin/python, which breaks the build (build / installer / setuptools might be missing).
Always use makepkg -si OUTSIDE your virtual environment.
- Update Version:
-
PKGBUILD:pkgver -
pyproject.toml:version -
setup.py:version
- Commit Version bump:
git add pyproject.toml
git commit -m "Bump version to v1.1.1"- Build Python package:
Make sure you're NOT in venv:
deactivate 2>/dev/null || true
Build:
/usr/bin/python -m build
You'll get:
dist/dotpush-<ver>.tar.gz <--- Release version
dist/dotpush-<ver>-py3-none-any.whl
- Generate SHA256 for AUR
sha256sum dist/dotpush-<ver>.tar.gz
- Update
PKGBUILD:
sha256sums=('PASTE_YOUR_HASH_HERE')
-
Draft New Release on GitHub and Upload
dist/dotpush-<ver>.tar.gz&dist/dotpush-<ver>-py3-none-any.whl -
Test Release locally:
makepkg -si
- AUR Release:
Update the version in /aur/dotpush fork: .SRCINFO and PKGBUILD and Push
Verify:
yay -S dotpush