Development facilities for the bolt environment
Project description
Integrity
Development facilities for the bolt environment
from integrity import Component
from ./settings import settings
from ./blocks import blocks
from ./player import player
main = Component()
function main.on("main"):
if score settings.data.activated obj matches 1:
main.run("active")
function main.on("active"):
as @a at @s:
player.run("main")
function blocks.on("placed_by_player"):
if block ~ ~ ~ stone expand:
say Placed stone!
player.run("placed_stone")
Installation
The package can be installed with pip
. Note, you must have
both beet
and mecha
installed to use this package.
$ pip install integrity
Getting Started
To use this package, we must add the plugin to the require
section in the beet
project file alongside with mecha
and
mecha.contrib.bolt
.
require:
- mecha.contrib.bolt
- integrity
pipeline:
- mecha
Now that we've enabled integrity
, we can import the module
directly inside a bolt script
from integrity import Component
foo = Component("foo")
Features
- Components
Contributing
Contributions are welcome. Make sure to first open an issue
discussing the problem or the new feature before creating a
pull request. The project uses poetry
.
$ poetry install
You can run the tests with poetry run pytest
.
$ poetry run pytest
The project must type-check with pyright
.
If you're using VSCode the pylance
extension should report diagnostics automatically. You can also install
the type-checker locally with npm install
and run it from the command-line.
$ npm run watch
$ npm run check
The code follows the black
code style.
Import statements are sorted with isort
.
$ poetry run isort bolt_expressions examples tests
$ poetry run black bolt_expressions examples tests
$ poetry run black --check bolt_expressions examples tests
License - MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for integrity-0.7.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8629eecb639290fc95d9a9443a67f493514fdb95f2097dffd3b75f357988f7b7 |
|
MD5 | 47b53d7270d93e70614a66052fda1b4d |
|
BLAKE2b-256 | b59c0ad5b598efa907f13be99f6a8ac9cf8ca8ad50fe2342c84d0bfa60984ad5 |