dlvhdr / gh-dash

A beautiful CLI dashboard for GitHub 🚀
https://dlvhdr.github.io/gh-dash
MIT License
6.75k stars 190 forks source link

Ability to show info based on current repo in directory #179

Open rambhosale opened 1 year ago

rambhosale commented 1 year ago

Is your feature request related to a problem? Please describe. The global dashboard is working fine for me only issue is viewing the information of a specific Repo from which directory I am running the gh dash command

Describe the solution you'd like Show the issues, PRs (all or with a custom filter) specific to the repo from which I run the dash command, I was thinking of a view that shows like ([current repo name], [Prs], [Issues] )

Describe alternatives you've considered Just started using the extension so haven't found a solution yet

Additional context NONE

dlvhdr commented 1 year ago

@rambhosale thanks for the suggestion! Do you think a command line arguement like gh dash . to run the gh-dash on the current directory's repo would make sense? What sections would you expect in the [current repo name] view? "All PRs" and "All Issues"?

rambhosale commented 1 year ago

@dlvhdr sorry for the late reply According to me a command line argument would be unnecessary as the majority of gh commands take the current dir repo Into consideration when a valid repo is available, so just gh dash should be sufficient, and that way it is concise with gh commands structure (not that gh-dash should adhere to that structure but having the same system in both would the easier overall)

And as for what section to show in the [current repo name] view it would be great to have a list of all issues, prs and commits in that repo with the ability to update the filter just like in other sections

MikaelElkiaer commented 1 year ago

I would also love this!

It would be cool if it behaved similarly to lazygit/lazydocker, in that the gh dash will be focused on the current directory, if it is a git repo with a GitHub origin.

MikaelElkiaer commented 1 week ago

Has anyone worked on this? Or perhaps found some way of making this possible?

dlvhdr commented 1 week ago

Hey @MikaelElkiaer, this is possible but requires a bit of work. See how Josh made it work here The script basically searches for a .gh-dash.yml file in the current git repo's root directory. This means you would have to run gh dash by running the ghd script and also have a dedicated .gh-dash.yml config for each of your git repos that you want to customize.

MikaelElkiaer commented 1 week ago

Hey @MikaelElkiaer, this is possible but requires a bit of work. See how Josh made it work here The script basically searches for a .gh-dash.yml file in the current git repo's root directory. This means you would have to run gh dash by running the ghd script and also have a dedicated .gh-dash.yml config for each of your git repos that you want to customize.

That was super useful, thanks!

I ended up creating a script of my own, which dynamically sets the section filters based on current git repo: https://github.com/MikaelElkiaer/dotfiles/blob/nix-wsl2/home/nixos/bin/gh-dash