Skip to main content

useful tools for civil engineering that are needed regularly in the daily tasks for a civil engineer

Project description

civix

python tools for Civil and Structural Engineering

Release workflow

1. Pre-release checks (run locally)

Ruff is not enforced in CI — run manually before merging:

uv tool run ruff check .        # lint (Pyflakes F-rules)
uv tool run ruff format .       # auto-format
uv run pytest                   # all tests green

2. Merge feature branch → develop (squash)

git checkout develop
git merge --squash feature/<branch-name>
git commit -m "squashed: <short description>"

3. Bump version

uv version --bump patch          # e.g. 0.0.18 → 0.0.19
git add pyproject.toml uv.lock
git commit -m "bump version to $(uv version)"

4. Merge develop → main

git checkout main
git merge develop
git push origin main

CI detects the version change on main, creates the tag, runs tests, builds, and publishes to PyPI automatically.

Starting a new feature

1. Clean up the old feature branch

git branch -d feature/<old-branch>                # delete local
git push origin --delete feature/<old-branch>     # delete remote

2. Create a new branch from develop

git checkout develop
git pull origin develop                            # make sure develop is up to date
git checkout -b feature/<new-branch>

3. Work, commit, repeat

git add <files>
git commit -m "<description>"

When ready, follow the Release workflow steps above (squash merge → bump version → merge to main).


Syncing all local branches with remote

Run this at the start of each session to stay up to date:

git fetch --all --prune              # fetch all remotes, remove deleted remote branches
git checkout main && git pull
git checkout develop && git pull
git push origin develop              # push any local develop commits not yet on remote

Streamlit app

uv run streamlit run streamlit_app/app.py

Installation

pip install civix                      # core only (numpy, loguru, pyyaml, plotly, openpyxl)
pip install "civix[etabs]"             # + ETABS automation (Windows)
pip install "civix[ifc]"              # + IFC parsing (ifcopenshell)
pip install "civix[geom]"             # + Rhino/Grasshopper geometry
pip install "civix[notebook]"         # + Jupyter notebook + handcalcs rendering
pip install "civix[streamlit]"        # + Streamlit app
pip install "civix[all]"              # everything

With uv:

uv add civix
uv add "civix[etabs,ifc,geom]"
uv add "civix[all]"

Logging

civix is silent by default — it calls logger.disable("civix") at import and never attaches a sink itself. To see its logs, opt in from your notebook or script:

import sys
from loguru import logger

logger.enable("civix")
logger.remove()
logger.add(sys.stderr, level="INFO")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

civix-0.0.21.tar.gz (27.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

civix-0.0.21-py3-none-any.whl (42.5 kB view details)

Uploaded Python 3

File details

Details for the file civix-0.0.21.tar.gz.

File metadata

  • Download URL: civix-0.0.21.tar.gz
  • Upload date:
  • Size: 27.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for civix-0.0.21.tar.gz
Algorithm Hash digest
SHA256 facb66f1a0bac3867825acf2a9064d969f0c65a7a32cd9ede20aef229c9177db
MD5 d0f9be53e2bd32303100c9d47a8bd7bc
BLAKE2b-256 1c400f90fdfa1f4d742d058a6cd63bd0b19b991ad23b381f1b85993bf7fa0e64

See more details on using hashes here.

Provenance

The following attestation bundles were made for civix-0.0.21.tar.gz:

Publisher: release.yml on mohamadalitellawi/civix

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file civix-0.0.21-py3-none-any.whl.

File metadata

  • Download URL: civix-0.0.21-py3-none-any.whl
  • Upload date:
  • Size: 42.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for civix-0.0.21-py3-none-any.whl
Algorithm Hash digest
SHA256 33de20d489c035c8214d7ade898780bf535a77b3e6c7dc3866eda70e23665b6c
MD5 6a535a1e30f06c3ea14e0b986747cb60
BLAKE2b-256 505fd1dd6a80305d78313e390f040750e9a2bb534c031d82bb914c1d713e4937

See more details on using hashes here.

Provenance

The following attestation bundles were made for civix-0.0.21-py3-none-any.whl:

Publisher: release.yml on mohamadalitellawi/civix

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page