Skip to content

Find out how many lines of code you have written for your project πŸ“œ

License

Notifications You must be signed in to change notification settings

varunKT001/tloc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

28 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ“œ TLOC (Tomper Lines Of Code)

Find out how many lines of code you have written for your project.

πŸ“ˆ Installation

(Install the package globally)

npm install -g tloc

πŸ§ͺ Usage

The tloc command can be used to calculate the number of lines of code by providing the location of the file or folder. Some additional options and flags that can be used:

  1. -l or --log: Adding some additional information to the console.

  2. --: Ignoring files/directories (This option must be used at the last)

Example: Getting number of lines

# path to folder
tloc ./src

# path to file
tloc ./src/index.ts

Example: Logging additional information

tloc ./src -l

# or

tloc ./src --log

Example: Ignoring files/directories

# Remove particular file or directory
tloc ./src -- ./src/dummyData.js ./temp

# Remove all matching occurences
tloc ./src -- dummyData.js temp

# While using other options, use the ignore option at last
tloc ./src -l -- dummyData.js ./temp

✨ Features

  • Calculates the number of lines in each file by recursively moving through the directories.
  • Ignore specific files/directories or all matching occurrences.
  • Implemented using Depth First Search (DFS) algorithm.

βš™ Tools and Technologies used

  1. Typescript
  2. Minimist
  3. Chalk

πŸ›  Local Installation and setup

  1. Clone the repo to your local machine.

  2. Install the required dependency using:

    npm install

🏎 Creating production built

  1. Build the package using:

    npm run build

😎 Made with πŸ’™ by

GSSoC'22
Varun Kumar Tiwari
LinkedIn Github

βš– License

GPL-3.0




(If you liked the project, give it star πŸ˜ƒ)

About

Find out how many lines of code you have written for your project πŸ“œ

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published