aboutsummaryrefslogtreecommitdiff
path: root/README.md
blob: 8c736d4021484614a9dece30c640dc0ffcc70235 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# Shared Cost

Share costs with a group of people:

- Share according to people income,
- Monthly payments available,
- Statistics by month,
- Weekly activity sent by email.

## Getting started

Install nix:

```
curl https://nixos.org/nix/install | sh
```

Start the environment with:

```bash
./make start
```

Init the database with migration scripts:

```bash
sqlite3 database < server/migrations/1.sql
sqlite3 database < server/migrations/2.sql
sqlite3 database < server/migrations/3.sql
```

Inside the tmux session, add some users with sqlite after the migration is done:

```
sqlite3 database
insert into user(creation, email, name, password) values (datetime('now'), 'john@mail.com', 'John', '$2y$14$1QqyMA8vknmSVBq9BcGi6upZISLwsP2aPXx5JZOMPVzaZ8gorrsq.');
insert into user(creation, email, name, password) values (datetime('now'), 'lisa@mail.com', 'Lisa', '$2y$14$1QqyMA8vknmSVBq9BcGi6upZISLwsP2aPXx5JZOMPVzaZ8gorrsq.');
```

Later, stop the environment with:

```bash
./make stop
```

## Deploy

```bash
make deploy
```

## Configuration

See [application.conf](application.conf).

## Documentation

- [reflex](https://hackage.haskell.org/package/reflex-0.6.2.4/docs/doc-index-All.html)
- [reflex-dom](https://hackage.haskell.org/package/reflex-dom-core-0.5/docs/doc-index-All.html)