Skip to content

Latest commit

 

History

History
39 lines (32 loc) · 827 Bytes

File metadata and controls

39 lines (32 loc) · 827 Bytes

Idris Spring Boot Example

An example Idris project demonstrating how to export functions and generate classes from Idris to Java. It is a Spring Boot application connecting to MySQL database.

Build

Compile

./mvnw package

Start MySQL server

mysql.server start

Initialize MySQL

  • From MySQL console
create database payroll_db;
create user 'payroll_admin'@'%' identified by '<enter password>';
grant all on payroll_db.* to 'payroll_admin'@'%';

Run

  • Set MySQL password in PAYROLL_PASSWORD environment variable
read -rs PAYROLL_PASSWORD
export PAYROLL_PASSWORD
  • Start application
java -cp "build/exec/idrisspringbootexample_app:target/classes:build/exec/idrisspringbootexample_app/*" idrisspringbootexample.Main