Skip to content

premium-minds/billy-demo-app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

billy-demo-app

How to use

Create database

createdb -h localhost -U postgres billy-demo

Compile jar file

mvn package 

Execute jar file

mvn -B dependency:copy-dependencies

# using classpath
java -cp "target/DummyApp-0.0.1-SNAPSHOT.jar:target/dependency/*" dummyApp.app.App

# using modulepath and classpath
java -p "target/DummyApp-0.0.1-SNAPSHOT.jar:target/dependency/billy-core-8.0.1.jar:target/dependency/billy-core-jpa-8.0.1.jar:target/dependency/billy-gin-8.0.1.jar:target/dependency/billy-spain-8.0.1.jar:target/dependency/billy-portugal-8.0.1.jar:target/dependency/guice-5.1.0.jar:target/dependency/guice-persist-5.1.0.jar" \
    -cp "target/dependency/*" \
    -m DummyApp/dummyApp.app.App

Alternatively execute directly from maven

mvn exec:java -Dexec.mainClass="dummyApp.app.App" 

Single Invoice Demonstration with SAFT and PDF export

java -jar target/DummyApp.jar demo portugal

or

mvn exec:java -Dexec.mainClass="dummyApp.app.App" -Dexec.args="demo"

will create a saft.xml, an invoice*.pdf and a creditNote*.pdf