depot/third_party/tvl/users/wpcarro/assessments/tt
Default email a291c8690a Project import generated by Copybara.
GitOrigin-RevId: e6e19f3d81a982a62e1bba08f0b4f7fdc21b4ea0
2022-05-19 16:39:52 +02:00
..
client Project import generated by Copybara. 2022-05-19 16:39:52 +02:00
data Project import generated by Copybara. 2022-05-19 16:39:52 +02:00
src Project import generated by Copybara. 2022-05-19 16:39:52 +02:00
tests Project import generated by Copybara. 2022-05-19 16:39:52 +02:00
.gitignore Project import generated by Copybara. 2022-05-19 16:39:52 +02:00
populate.sqlite3 Project import generated by Copybara. 2022-05-19 16:39:52 +02:00
README.md Project import generated by Copybara. 2022-05-19 16:39:52 +02:00
shell.nix Project import generated by Copybara. 2022-05-19 16:39:52 +02:00
todo.org Project import generated by Copybara. 2022-05-19 16:39:52 +02:00

TT

All of the commands defined herein should be run from the top-level directory of this repository (i.e. the directory in which this file exists).

Server

To create the environment that contains all of this application's dependencies, run:

$ nix-shell

To run the server interactively, run:

$ cd src/
$ ghci

Now compile and load the server with:

Prelude> :l Main.hs
*Main> main

Database

Create a new database named db.sqlite3 with:

$ sqlite3 db.sqlite3

Populate the database with:

sqlite3> .read populate.sqlite3

You can verify that everything is setup with:

sqlite3> .tables
sqlite3> .schema
sqlite3> SELECT * FROM Accounts;
sqlite3> SELECT * FROM Trips;