Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to ignore lines from certain files #122

Open
rluvaton opened this issue Mar 29, 2021 · 8 comments
Open

Add option to ignore lines from certain files #122

rluvaton opened this issue Mar 29, 2021 · 8 comments
Assignees
Projects

Comments

@rluvaton
Copy link

Expected Behavior

I want to be able to ignore some files when calculating the repo lines (such as package-lock.json)

Actual Behavior

Count the lines from every file

@kas-elvirov
Copy link
Owner

Github doesn't has such API

image

@Lazerbeak12345
Copy link

Changing to the tokei api may help. They even have badges, and ignore code comments in a ton of languages.

@kas-elvirov
Copy link
Owner

Changing to the tokei api may help. They even have badges, and ignore code comments in a ton of languages.

Interesting idea. Thanks man

@kas-elvirov kas-elvirov reopened this Apr 14, 2021
@kas-elvirov kas-elvirov changed the title [Feature Request] Add option to ignore lines from certain files Add option to ignore lines from certain files May 15, 2021
@kas-elvirov kas-elvirov unpinned this issue May 15, 2021
@Lazerbeak12345
Copy link

Thanks for the assignment; I appreciate the gesture! I don't know that I'll be able to put much time into this, but I'll see what I can do.

@kas-elvirov
Copy link
Owner

@Lazerbeak12345 let's keep in touch regarding this task. I want to make it too. It would be great feature)

@Lazerbeak12345
Copy link

Lazerbeak12345 commented Jun 8, 2021

I played around with their badges api and discovered that it usually works on smaller repos such as:

  • this one: . ([![](https://tokei.rs/b1/github/artem-solovev/gloc)](https://github.com/artem-solovev/gloc))
  • Their repo: . ([![](https://tokei.rs/b1/github/XAMPPRocky/tokei)](https://github.com/XAMPPRocky/tokei))

But it often either takes a long time to load, or just never resolves for larger repos, such as chromium:

. ([![](https://tokei.rs/b1/github/chromium/chromium)](https://github.com/chromium/chromium))

You may need to wait a bit for these images to load, if they load at all. (I've been getting 502 errors)

@kas-elvirov
Copy link
Owner

kas-elvirov commented Jun 8, 2021

Ohh, that's great. I will keep in mind.
I have to postpone this task because i'm working on my new project
But i wanted release something similar you suggested anyway because it will be very useful
Thanks again )

@Lazerbeak12345
Copy link

Just thought i'd look at making this happen, and I've got bad news. Tokei provides an API, sure, but there's two ways of using it:

  • Crawl the actual code
  • Get badges. Only.

They have no api to get the actual number. This will work but it'll limit the ability to have status updates like "loading..." etc.

@Lazerbeak12345 Lazerbeak12345 removed their assignment Jun 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Gloc
  
To do
Development

No branches or pull requests

3 participants