๐Ÿ“ฆ savankansagra / expenses-management

geektrust expenses-management sample.

โ˜… 1 stars โ‘‚ 0 forks ๐Ÿ‘ 1 watching โš–๏ธ MIT License
expenses-managementgeektrustjavaobject-oriented-programming
๐Ÿ“ฅ Clone https://github.com/savankansagra/expenses-management.git
HTTPS git clone https://github.com/savankansagra/expenses-management.git
SSH git clone git@github.com:savankansagra/expenses-management.git
CLI gh repo clone savankansagra/expenses-management
savan savan Merge remote branch 'origin/main' 79c5316 2 years ago ๐Ÿ“ History
๐Ÿ“‚ main View all commits โ†’
๐Ÿ“ diagrams
๐Ÿ“ sample_input
๐Ÿ“ src
๐Ÿ“„ .DS_Store
๐Ÿ“„ .gitignore
๐Ÿ“„ LICENSE
๐Ÿ“„ pom.xml
๐Ÿ“„ ReadMe.md
๐Ÿ“„ run.bat
๐Ÿ“„ run.sh
๐Ÿ“„ README.md

Pre-requisites

  • Java 1.8/1.11/1.15
  • Maven

How to run the code

We have provided scripts to execute the code.

Use run.sh if you are Linux/Unix/macOS Operating systems and run.bat if you are on Windows. Both the files run the commands silently and prints only output from the input file sample_input/input1.txt. You are supposed to add the input commands in the file from the appropriate problem statement.

Internally both the scripts run the following commands

  • mvn clean install -DskipTests assembly:single -q - This will create a jar file geektrust.jar in the target folder.
  • java -jar target/geektrust.jar sample_input/input1.txt - This will execute the jar file passing in the sample input file as the command line argument
We expect your program to take the location to the text file as parameter. Input needs to be read from a text file, and output should be printed to the console. The text file will contain only commands in the format prescribed by the respective problem.

Use the pom.xml provided along with this project. Please change the main class entry (<mainClass>com.example.geektrust.Main</mainClass>) in the pom.xml if your main class has changed.

# Running the code for multiple test cases

Please fill input1.txt and input2.txt with the input commands and use those files in run.bat or run.sh. Replace java -jar target/geektrust.jar sample_input/input1.txt with java -jar target/geektrust.jar sample_input/input2.txt to run the test case from the second file.

# How to execute the unit tests

mvn clean test will execute the unit test cases.

Help

You can refer our help documents here You can read build instructions here