https://github.com/bittricky/waist-line
Command line tool to calculate your Body Mass Index (BMI) ποΈ
https://github.com/bittricky/waist-line
chalk cli javascript meow nodejs npm-package pnpm
Last synced: 4 months ago
JSON representation
Command line tool to calculate your Body Mass Index (BMI) ποΈ
- Host: GitHub
- URL: https://github.com/bittricky/waist-line
- Owner: bittricky
- License: mit
- Created: 2024-12-23T22:40:26.000Z (5 months ago)
- Default Branch: main
- Last Pushed: 2024-12-25T18:24:36.000Z (5 months ago)
- Last Synced: 2025-01-27T18:10:09.199Z (4 months ago)
- Topics: chalk, cli, javascript, meow, nodejs, npm-package, pnpm
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/waist-line
- Size: 38.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Waist Line
> Those denim jeans collecting dust in your closet? No problem! With waistLine, you can calculate your BMI and take the first step toward better understanding of your health and fitness goalsβbecause a healthy you is the best fit!
A command-line tool to calculate your Body Mass Index (BMI) with support for both metric and imperial units to get you started on your fitness journey.
## π Installation
```bash
# Using npm
npm install -g waistline# Using pnpm
pnpm add -g waistline# Using yarn
yarn global add waistline
```## π Usage
### Calculate BMI using metric units (default)
```bash
waistline bmi --height 1.75 --weight 70
```- Height in meters
- Weight in kilograms### Calculate BMI using imperial units
```bash
waistline bmi --height 70 --weight 154 --imperial
```- Height in inches
- Weight in pounds### Get help
```bash
waistline help
```## π οΈ Available Commands
### `bmi`
Calculate your Body Mass Index (BMI)
#### Options:
- `--height, -h`: Your height (in meters or inches)
- `--weight, -w`: Your weight (in kilograms or pounds)
- `--imperial, -i`: Use imperial units (height in inches, weight in pounds)
- `--clear, -c`: Clear the console
- `--debug, -d`: Print debug info## π BMI Categories
The tool categorizes your BMI into one of these ranges:
- Underweight: < 18.5
- Normal weight: 18.5 - 24.9
- Overweight: 25 - 29.9
- Obese: β₯ 30## π§ Development
### Prerequisites
- Node.js >= 18
### Setup
```bash
# Clone the repository
git clone https://github.com/bittricky/death.git
cd waist-line# Install dependencies
pnpm install# Run locally
pnpm dev
```### Available Scripts
- `pnpm dev`: Run the CLI locally
- `pnpm start`: Run the CLI
- `pnpm format`: Format code using Prettier
- `pnpm publish:patch`: Publish a patch version
- `pnpm publish:minor`: Publish a minor version
- `pnpm publish:major`: Publish a major version## π License
MIT Β© [Mitul Patel](https://mitulpa.tel)
A reimagining of the BMI calculator challenge on [frontendmentor.io](https://frontendmentor.io)