blob: 4c3444a2a65884c63e6bfb1d70680709c53770a0 (
plain) (
tree)
|
|
# Energyscripts
This is a small collection of scripts I use to collect information about my
energyconsumption.
## Set up venv
```
python3 -m venv venv
source venv/bin/activate
pip3 install -r requirements.txt
```
## Handling pip
```
# Create requirements.txt
pip3 freeze > requirements.txt
# Show outdated packages
pip3 list --outdated
# Upgrade package
pip3 install -U name
# Upgrade everything
pip3 install -U -r requirements.txt
# Update requirements.txt
pip3 freeze > requirements.txt
```
## Schema
Install schema
```
psql el < schema.sql
```
schema.sql created with:
```
pg_dump --schema-only --no-owner --no-privileges el
```
TODO:
Put every state in `states`-table. Entities in an entity-table, and devices in
a device-table.
|