Chipmunk uses Rust for processing the log files while frontend application is built using the ElectronJS
With the new Chipmunk Development CLI Tool, you can perform various Chipmunk development tasks without the need to install Ruby.
To build and run chipmunk on local you will need following languages installed on your system.
- Rust
- NodeJS
- Ruby (Not needed with the new Chipmunk Development CLI Tool)
To check if you have all the pre-requisite installed or not, chipmunk provides the shell script for this purpose. After cloning the repo run following command in your preferred terminal.
sh developing/check.sh
If everything is installed then script should print success messages. If all pre-requisite are satisfied, install dependencies. Follow steps below for installing the missing dependencies.
To install the Rust, use the Rust version manager called rustup which will automatically install the Rust on local. Run following command in the terminal.
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
Once command finishes processing, check the installed Rust version using
rustc --version
which should print the Rust version on terminal.
To install the NodeJS, install NVM(Node Version Manager). Follow installation guide for installing NVM on local. Once NVM in ready on your local, install NodeJS using
nvm install --lts
which will install latest long term NodeJS version. Check if node is installed or not using
node -v
which will print the installed NodeJS version on terminal.
Tip
You can use the new Chipmunk Development CLI Tool instead of Ruby & rake
You must have latest Ruby installed on your system. Prefer your choice of version manager
either RBENV or RVM.
Once version manager is ready to use, install Ruby version >=2.7.7
.
This project uses few dependencies from other languages and to install them run following command in terminal.
sh developing/install.sh
We are using yarn as a package manager. Installing yarn is simple as you just have to run following command in the terminal.
npm install -g yarn
As mentioned earlier backend is built in Rust which takes care of reading the log files and frontend app is built using Electron JS.
When you are running application first time on your local it is good idea to clean everything and build and start the new application in the development configuration.
rake clean
rake build_dev
rake run_dev
Which will open Chipmunk user interface, Yay!
To build and start the app in the production configuration you can use
rake clean
rake build_prod
rake run_prod
Most of the day-to-day task are written using Rake from Ruby. You can list all the tasks by
rake -T
It's recommended to rebuild the app incrementally and run the app after changes using
rake run_dev #or rake run_prod for production configuration
You don't need to update the Rust binary, just run the ElectronJS application.
cd application/holder
yarn run electron
cd application/holder
rake client:build_dev #or rake client:build_prod for production configuration
yarn run electron
With this you can take a look at the open issues and open a PR to fix them.
Before opening up the PR please fork the repo and check for code smells or any issues using
rake lint:all
To run linting for the backend only you can use
rake lint:rust
To run linting for the frontend only you can use
rake lint:js
Make sure your changes are covered by valid test cases and check if all test cases are passing by executing following task
rake test:all
Note - If any changes are made to the build cli tool, make sure to add the label "build-cli" to the PR. This would ensure that all the integration tests for the cli tool are run, which are otherwise not required.
If you find scope for improvement or any bug in the processing, please log issue on GitHub.