threagile-builder
| CI/CD | |
| Package | |
| Meta |
A block-based no-code web application to create threagile YAML files
Executive Summary
Getting your code up and running on your own system.
Note: Make sure you fulfill the requirements.
-
Installation process:
$ cd threagile-builder $ hatch --version # optional, will print the version of our package to the terminal without modifying the source directory (e.g. `0.0.1`). # Without hatch: $ python src/threagile_builder/app.py $ hatch env create # optional, if the default env already exists you will be told $ hatch shell # spawn a shell within an environment (threagile-builder) $ pip show threagile-builder # optional, shows the project details, here 'threagile-builder', from `pyproject.toml` # Name: threagile-builder # Version: 0.0.1 # it takes this from src/threagile_builder/__about__.py # ... (threagile-builder) $ python -c "import sys;print(sys.executable)" # optional, see where your environment's python is located (threagile-builder) $ pip install --upgrade pip # optional, the `run` command allows you to execute commands in an environment as if you had already entered it. (threagile-builder) $ pip install -r requirements.txt # pipx won't do this (threagile-builder) $ python -m setuptools_scm # optional, display the version of our package and perform any side-effects like writing to a file. (here: `_version.py`) (threagile-builder) $ python src/threagile_builder/app.py # starts the app (threagile-builder) $ exit # optional, type `exit` to leave the environment
-
Software dependencies
-
Latest releases
-
API references
-
Build and Test:
To build your code, use:
$ cd threagile-builder $ hatch buildTo use AI for pull request reviews, use:
https://app.coderabbit.ai/dashboard (uses
phpstan.neon)To run the application, use:
Linux:
$ export SECRET_KEY="secret"
Windows:
$ setx SECRET_KEY secret
Then:
$ cd threagile-builder # Without hatch: $ python src/threagile_builder/app.py $ hatch run python src/threagile_builder/app.py
Then, navigate to
http://127.0.0.1:5000/in your web browser.To run tests, use:
$ cd threagile-builder $ pip install pytest # optional $ pytest tests/
Navigate to http://127.0.0.1:5000/docs in your web browser, or download the openapi.json from http://127.0.0.1:5000/openapi.json.
Let a tool like Prometheus scrape http://127.0.0.1:9464/metrics.
___ NEW ___
Table of Contents
pip install threagile-builder- The hatch-vcs version source plugin determines the project version using Git tags
- Defined neatly in a standalone
hatch.toml - The
testmatrix uses the hatch-containers plugin to run each environment inside Docker containers; usage can be seen in the test GitHub workflow
- All build targets use the hatch-vcs build hook plugin to ship a
_version.pyfile so the version can be used at runtime - Wheels use the hatch-mypyc build hook plugin to first compile all code with Mypyc
- The build GitHub workflow shows how to:
- use cibuildwheel to distribute binary wheels for every platform
- use the app build target to build standalone distributions for every platform
threagile-builder is distributed under the terms of the MIT license.
See README.md
See README.md
See README.md
See README.md