shurcooL / Go-Package-Store

An app that displays updates for the Go packages in your GOPATH.
MIT License
900 stars 29 forks source link

Feature Request: ignore repos. #89

Open luckcolors opened 6 years ago

luckcolors commented 6 years ago

Hello!

I've been using Go-Package-Store for a while and it works pretty well, the only feature it lacks for me is a way to make it ignore some repos.

Ideas on how we could do this:

Let me know what you think. :)

dmitshur commented 6 years ago

Thanks for feedback.

I'll think more about this, but in the meantime, here's an existing way you can accomplish this:

go list all | grep -v ignore | Go-Package-Store -stdin

What do you think about this way? Is it sufficient, or not convenient enough?

luckcolors commented 6 years ago

Well i frankly prefer to just run go-Package-store, it's just easier :), and let it do it's thing, again if you want i can work on a pull request if you prefer.

dmitshur commented 6 years ago

Well i frankly prefer to just run go-Package-store, it's just easier :), and let it do it's thing

Fair.

I can make the suggestion of making an alias. It'd be one line in your .bash_profile or equivalent:

alias gps='go list all | grep -v ignore | Go-Package-Store -stdin'

I'd prefer to keep the project orthogonal and as simple as possible. In order to add additional complexity, it should be justified, and I'm not yet convinced this is.

Before sending a PR, I suggest discussing the design, i.e., let's agree on how to solve this first. Writing code can be then done after.

dmitshur commented 6 years ago

Also, to give me a better understanding, can you please answer these questions:

  1. How many repositories do you have in your GOPATH workspace(s), roughly?
  2. How many do you want to ignore?
  3. Why do you want to ignore them?
  4. How often do you want to change which repos you ignore?
luckcolors commented 6 years ago

Yeah no problem:

  1. Generally i use Go-Package-Store to update all of my global go path so there's quite a bunch of stuff.
  2. Ones that do not have a remote ( such as personal projects).
  3. Local only projects cause a lookup error on github apis (as ofc they aren't there) i would love to avoid to make requests to github for nothing. And projects wich are a binding and don't have a clean tree all the time (such for exaple the qt binding).
  4. Not always it's more like as you imagine, sporadically when there's the need to. Alas for me it wouldn't be an issue to use a cfg file for this.