semvec/pypi-packages huggingface dataset:
pyhomebridge 0.0.3
Control a homebridge server
License: MIT
Keywords: HomeBridge,HomeKit

# pyhomebridge
python library to control a Homebridge server

## Setup
Install [homebridge-config-ui-x](https://www.npmjs.com/package/homebridge-config-ui-x) on your HomeBridge.

Make sure you run HomeBridge in Insecure Mode. (This can be changed in the Web Settings at top right corner)
API control is only allowed in this mode.
Thats starting HomeBridge with the -I flag.

## Installation
Pypi package for [pyhomebridge](https://pypi.org/project/pyhomebridge/)
```bash
pip3 install pyhomebridge
```

## Usage
Python usage:
```python
from homebridge import HomeBridgeController

controller = HomeBridgeController(host="homebridge.local", port=80, auth="123-45-678")
print(controller.accessories)
controller.print_accessories()
controller.accessory_exists("light_hallway")
controller.get_value("light_hallway")
controller.set_value("light_hallway", True)
```

In the repo you can find a python script to use for CLI execution. `control-homebridge.py`
```bash
python3 control-homebridge.py --list
python3 control-homebridge.py --name light_hallway --off

# you will need to set url, port and code in the script
# or use the --server, --port, --auth options
```

## Development

Currently supported devices:

* Lights
* Switches
* Outlets

## TODO

* add timeouts
* support more device types
* write documentation
* write tests
* much much more

## Inspiration
[HomeScript by menahishayan](https://github.com/menahishayan/HomeScript)

## License
[MIT](LICENSE)

**Free Software, Hell Yeah!**
pysemanticmd 0.1.0
An implementation of SemanticMd parser, see specifications here: http://source.virtual-assembly.org/semantic-markdown/about/
License: MIT
Requires Python: >=3.8,<4.0

# pySemanticMd

## Project objective

Provide a new Renderer to mistletoe (a python librairie that transform MD into different format, including HTML) that handle SemanticMarkdown.

## Try current pySemanticMDRenderer

*This needs to be tested*

Source : [https://cjolowicz.github.io/posts/hypermodern-python-01-setup/](https://cjolowicz.github.io/posts/hypermodern-python-01-setup/)

### First time

* clone repository `git clone git://source.virtual-assembly.org/pySemanticMd`
* enter the new folder `cd pySemanticMD`
* Install Poetry `curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python`
* run `source ~/.poetry/env`
* go to second time

### Second time and next

* pull from repo `git pull`
* add any new requirements `poetry install`
* enter the virtual env `poetry shell`
* run the demo script `python display.py`

## Discussions

Join the discussion on Riot : [https://riot.im/app/#/room/#semantic-markdown:matrix.virtual-assembly.org](https://riot.im/app/#/room/#semantic-markdown:matrix.virtual-assembly.org)

## References

- [SemanticMarkdown Specifications](https://hackmd.io/KtR5fUhXRuS_XnNEo_gpow)
- [mistletoe](https://github.com/miyuchina/mistletoe)
- [Regex101 <3](https://regex101.com/)
autoinclude-blueprints 1.0.1
Auto register all project flask-blueprints.
License: MIT
Requires Python: >=3.6

![Upload Python Package](https://github.com/FelixTheC/autoinclude_flask_blueprints/workflows/Upload%20Python%20Package/badge.svg?branch=master)
![Python application](https://github.com/FelixTheC/autoinclude_flask_blueprints/workflows/Python%20application/badge.svg?branch=master)
# Flask Blueprint autoinclude
A function to automatically register all flask-blueprints from a project.
<br>__register_blueprints__ from flask_bp_autoregister.blueprints

---
When using flask blueprints then after defining them you have to register them all this can possible look like this.
```python
# in some config.py or __init__.py
def register_my_blueprints(used_flask_app: any):
    from my_app.views import home_views
    from my_app.views import package_views
    from my_app.views import account_views

    used_flask_app.register_blueprint(home_views.app_bp)
    used_flask_app.register_blueprint(package_views.app_bp)
    used_flask_app.register_blueprint(account_views.app_bp) 

# and then in your run.py or similar

from my_app import flask_app
from my_app import register_my_blueprints

register_my_blueprints(flask_app)

if __name__ == '__main__':
    flask_app.run()

```
The register_blueprints code can get really long and you always have to remember where your blueprints are.

---

For this is had created a function __register_blueprints__ which automatically will search for all blueprints in your project and register them.
```python

from my_app import flask_app
from flask_bp_autoregister.blueprints import register_blueprints


register_blueprints(flask_app, 'my_project/src/my_app')


if __name__ == '__main__':
    flask_app.run()

```

The path attribute is not really needed you can also use it without then all blueprints inside of the project will be registered automatically
```python

from my_app import flask_app
from flask_bp_autoregister.blueprints import register_blueprints


register_blueprints(flask_app)


if __name__ == '__main__':
    flask_app.run()

```

When you have some __commented Blueprints__ inside of your project, __register_blueprints__ will try to register them too <br>
which will raise an AttributeError you can disable this with __silent=True__
```python
from my_app import flask_app
from flask_bp_autoregister.blueprints import register_blueprints


register_blueprints(flask_app, silent=True) # will prevent raising AttributeError


if __name__ == '__main__':
    flask_app.run()

```

### Tested for Versions
- 3.6, 3.7, 3.8

### Installing

- pip install git+https://github.com/FelixTheC/autoinclude_flask_blueprints.git

#### Versioning
- For the versions available, see the tags on this repository.

### Authors
- Felix Eisenmenger - Initial work

### License
- This project is licensed under the MIT License - see the LICENSE.md file for details