Commit cbe294dc authored by Ellis Percival's avatar Ellis Percival
Browse files

Handle PyPI uploads manually

parent ea595561
......@@ -15,4 +15,7 @@ wheel3: schema
clean:
cp pi_mqtt_gpio/__init__.py.die pi_mqtt_gpio/__init__.py
rm -rf .cache .eggs build *.egg-info
find pi_mqtt_gpio -type d -name __pycache__ -exec rm -rf {} \;
find pi_mqtt_gpio -type d -name __pycache__ -prune -exec rm -rf {} \;
upload: packages
twine upload dist/*
import yaml
CONFIG_SCHEMA = yaml.load("""
mqtt:
type: dict
required: yes
schema:
host:
type: string
empty: no
required: no
default: localhost
port:
type: integer
min: 1
max: 65535
required: no
default: 1883
user:
type: string
required: no
default: ""
password:
type: string
required: no
default: ""
client_id:
type: string
required: no
default: ""
topic_prefix:
type: string
required: no
default: ""
coerce: rstrip_slash
protocol:
type: string
required: no
empty: no
coerce: tostring
default: "3.1.1"
allowed:
- "3.1"
- "3.1.1"
status_topic:
type: string
required: no
default: status
status_payload_running:
type: string
required: no
default: running
status_payload_stopped:
type: string
required: no
default: stopped
status_payload_dead:
type: string
required: no
default: dead
gpio_modules:
type: list
required: yes
schema:
type: dict
allow_unknown: yes
schema:
name:
type: string
required: yes
empty: no
module:
type: string
required: yes
empty: no
cleanup:
type: boolean
required: no
default: yes
digital_inputs:
type: list
required: no
default: []
schema:
type: dict
schema:
name:
type: string
required: yes
empty: no
module:
type: string
required: yes
empty: no
pin:
type: integer
required: yes
min: 0
on_payload:
type: string
required: yes
empty: no
off_payload:
type: string
required: yes
empty: no
pullup:
type: boolean
required: no
default: no
pulldown:
type: boolean
required: no
default: no
retain:
type: boolean
required: no
default: no
digital_outputs:
type: list
required: no
default: []
schema:
type: dict
schema:
name:
type: string
required: yes
module:
type: string
required: yes
pin:
type: integer
required: yes
min: 0
on_payload:
type: string
required: no
empty: no
off_payload:
type: string
required: no
empty: no
inverted:
type: boolean
required: no
default: no
initial:
type: string
required: no
allowed:
- high
- low
retain:
type: boolean
required: no
default: no
""")
import sys
print("FATAL ERROR: The file at pi_mqtt_gpio/__init__.py should be replaced us"
"ing 'make schema' before packaging.")
sys.exit(1)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment