{"id":18873823,"url":"https://github.com/lekesoldat/backup","last_synced_at":"2025-04-14T16:32:48.007Z","repository":{"id":42310837,"uuid":"221685655","full_name":"Lekesoldat/BACkup","owner":"Lekesoldat","description":"Blood Alcohol Concentration Calculator, BACkup!","archived":true,"fork":false,"pushed_at":"2023-01-05T00:51:18.000Z","size":2436,"stargazers_count":0,"open_issues_count":28,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-20T11:17:32.021Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Lekesoldat.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-11-14T11:50:08.000Z","updated_at":"2024-10-24T13:53:18.000Z","dependencies_parsed_at":"2023-02-03T02:32:34.837Z","dependency_job_id":null,"html_url":"https://github.com/Lekesoldat/BACkup","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lekesoldat%2FBACkup","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lekesoldat%2FBACkup/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lekesoldat%2FBACkup/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lekesoldat%2FBACkup/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Lekesoldat","download_url":"https://codeload.github.com/Lekesoldat/BACkup/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248916876,"owners_count":21182882,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-08T05:35:56.097Z","updated_at":"2025-04-14T16:32:46.083Z","avatar_url":"https://github.com/Lekesoldat.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Project structure\n\nThis repository contains the entire BACkup project. The tech stack is the following:\n\n### Root\n\n- [Node](https://nodejs.org/en/) to bootstrap the project.\n  - [Concurrently](https://www.npmjs.com/package/concurrently) to start the backend and frontend with the same command.\n  - [wait-on](https://www.npmjs.com/package/wait-on) to delay the frontend start.\n\n### Frontend:\n\n- [React.js](https://reactjs.org)\n  - [Reach Router](https://reach.tech/router)\n  - [Styled Components](https://www.styled-components.com)\n- [ESLint](https://eslint.org/) for code quality.\n- [Jest](https://jestjs.io/) for testing and code coverage.\n\n### Backend:\n\n- [Spring Boot](https://spring.io/projects/spring-boot)\n- [Retrofit](https://square.github.io/retrofit/)\n- [JUnit](https://junit.org/junit5/) for testing.\n- [Jacoco](https://www.eclemma.org/jacoco/) for code coverage.\n- [SpotBugs](https://spotbugs.github.io/) for finding bugs.\n- [CheckStyle](https://checkstyle.sourceforge.io) for code quality.\n\n---\n\n## Running the project bootstrapped:\n\nWhen running the application, data is generated and stored via the REST api. The output can be located in `/backend/out/profiles/` after the app has ran for the first time.\n\n### Install dependencies\n\n```zsh\n$ npm install\n```\n\n### Run the project\n\n```zsh\n$ npm start\n```\n\n### Test the frontend\n\n```zsh\n$ npm run test-frontend\n```\n\n### Test the backend\n\n```zsh\n$ npm run test-backend\n```\n\n---\n\n## Running the project manually\n\n### Start the backend first.\n\n```zsh\n$ cd backend\n$ gradle run\n```\n\n### Start the frontend second, in a new terminal window/tab.\n\n```zsh\n$ cd frontend\n$ npm install # Install dependencies first time.\n$ npm run start\n```\n\n---\n\n## Building the project:\n\n### Build backend\n\n```zsh\n$ cd backend\n$ gradle build\n```\n\n### Build frontend\n\n```zsh\n$ cd frontend\n$ npm run build\n```\n\n---\n\n## Testing and results.\n\nThere are tests for both the frontend and the backend.\n\n### Backend\n\nTests are found at `{modulename}/src/test`. For analysis purposes we're using the following technologies:\n\n- `Jacoco` for code coverage.\n- `Checkstyle` to adhere the Google coding standards.\n- `Spotbugs` to find bugs.\n\nThe test results are stored within each module at `{modulename}/build/reports`.\n\n**NB!**  \nThe testing of the REST-api is both done in the API-tests, aswell as the SERVER-tests as they are dependant on eachother.\n\n### Running the tests:\n\n```zsh\n$ gradle test\n```\n\n### Frontend\n\nThe tests are found at `frontend/src/tests`. For analysis purposes we're using the following technologies.\n\n- `Istanbul` for code coverage. This is integrated in JEST.\n- `ESLint` for code quality.\n- `JEST` for testing the JavaScript.\n\n### Running the tests:\n\n```zsh\n$ npm run test\n```\n\nThe test render a code coverage-report in the terminal. You can also access this report manually at `/coverage/`. We suggest opening the HTML-file located at `/coverage/lcov-report/`.\n\n---\n\n# Welcome to our Blood Alcohol Concentration Calculator, BACkup!\n\nUsing this application, you can accurately estimate your BAC at any given time. The user can register relevant health stats, and input how many units she/he has consumed over any given time. The health stats include weight and gender, as well as the persons name. The program results with an interface displaying your current BAC.\n\nEvery user is welcomed by our profile page. There one can select a profile, if already created, or create a new one. Once the profile is loaded or created, it's time to register your drinks. The trackerpage takes the input from the user and calculates the users BAC.\n\n---\n\n# Diagrams\n\n## Package Diagram\n\n![Frontend Package Diagram](./resources/img/new_packagedia_frontend.png)\n![Backend Package Diagram](./resources/img/new_packagedia_backend.png)\n\n---\n\n## Class Diagram\n\n![API](./resources/img/klassedia_core.png)\n![API Service](./resources/img/klassedia_api_services.png)\n![CORE](./resources/img/klassedia_api_services.png)\n![JSON](./resources/img/klassedia_json.png)\n![SERVER](./resources/img/klassedia_server.png)\n![SERVER Controller](./resources/img/klassedia_server_controller.png)\n\n---\n\n## Sequence Diagram\n\nAdding a unit on a user.\n![SEQUENCE](./resources/img/Sekvensdiagram.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flekesoldat%2Fbackup","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flekesoldat%2Fbackup","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flekesoldat%2Fbackup/lists"}