Skip to content

Commit

Permalink
Doc rework progression #1686
Browse files Browse the repository at this point in the history
  • Loading branch information
dennissiemensma committed Jan 7, 2025
1 parent 4d5c0ea commit 04ac9d9
Show file tree
Hide file tree
Showing 13 changed files with 684 additions and 543 deletions.
4 changes: 4 additions & 0 deletions documentation/docs/explained/about.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# About DSMR-reader

[TOC]

DSMR-reader project information.

## Project goals
Expand Down
2 changes: 2 additions & 0 deletions documentation/docs/explained/hall-of-fame.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# Contributions

DSMR-reader is originally created and authored by:

- Dennis Siemensma
Expand Down
57 changes: 57 additions & 0 deletions documentation/docs/how-to/development.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# Developing DSMR-reader

## Setting up a development environment using Docker

> I'm using JetBrain's PyCharm IDE for local development, which has builtin support for Git and Docker.
> Therefor some steps or information below may or may not match your own development stack.
- Install Docker on your system. E.g. [how-to for Ubuntu](https://docs.docker.com/engine/install/ubuntu/) and consider [Docker rootless](https://docs.docker.com/engine/security/rootless/).

- Clone DSMR-reader repository from GitHub:

```shell
git clone <link to your fork>>
cd dsmr-reader/
```
- Symlink Docker files required (or just copy them):

```shell
# Either symlink
ln -s provisioning/container/compose.dev.yml compose.yml

# Or copy
cp provisioning/container/compose.dev.yml compose.yml
```

- Try running Docker (compose):
```shell
# This should build all the containers for local development
docker-compose up -d
```
- Containers built? See if this command works:
```shell
docker exec -it dev-dsmr-app poetry run /app/manage.py check

# Expected output: "System check identified no issues (0 silenced)"
```
- Now check whether tests run well in SQLite:
```shell
./tools/test-quick.sh
```


> Other DB engines can be tested as well, but the CI will take care of it anyway. The SQLite engine matches 99% of the features DSMR-reader requires and it also runs in-memory, speeding up tests.
- When using PyCharm, you can add a new Interpreter using Docker Compose. Just select ``dev-dsmr-app`` and set ``/opt/venv/bin/python`` as interpreter path. It should now map all dependencies used/installed in the container.


## Running DSMR-reader locally

When running it with the default Docker compose config, the Django Development Server application will be accessible at:

- [http://localhost:8000](http://localhost:8000/)

Any Python code changes you make will cause the Django Development Server to reload itself automatically.

## Other stuff
There is some more to it, such as tests, translations and documentation. If you ever need to work on those, just see how similar stuff works in the project. Or ask for more information.
8 changes: 8 additions & 0 deletions documentation/docs/how-to/donating.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Donating

If you really like DSMR-reader, feel free to use it without anything in return, you're welcome! ❤


Still want to return a small token of appreciation? You can:

- [Donate with PayPal](https://www.paypal.com/donate/?hosted_button_id=GCJZF72C28QM4)
7 changes: 7 additions & 0 deletions documentation/docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,10 @@
# DSMR-reader documentation
See sidebar for a more specific navigation or below for a (global) overview.

## [About DSMR-reader](explained/about.md#about-dsmr-reader)
## [Contributions](explained/hall-of-fame.md#contributions)
## [Developing DSMR-reader](how-to/development.md#developing-dsmr-reader)
## [Donating](how-to/donating.md#donating)
## [API](reference/API.md#api)
## [Environment variables](reference/environment-variables.md#environment-variables)
## [Plugins](reference/plugins.md#plugins)
6 changes: 4 additions & 2 deletions documentation/docs/reference/API.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
The application has an API, allowing you to insert/create readings and retrieve statistics.
# API

The application has a REST API, allowing you to insert/create readings and retrieve statistics.


## Configuration
You can access the API-documentation by selecting the **Support** menu item in DSMR-reader.
You can access the API documentation by selecting the **Support** menu item in DSMR-reader.

![Screenshot](../static/screenshots/api/support.png)

Expand Down
Loading

0 comments on commit 04ac9d9

Please sign in to comment.