git-link icon indicating copy to clipboard operation
git-link copied to clipboard

Add dwim(thingatp) smarts?

Open dolzenko opened this issue 1 year ago • 3 comments
trafficstars

E.g. when I'm in magit-refs buffer opens corresponding branch if I'm on branch or just home page, when in magit-log - opens commit.

Also thank you for the neat useful project :heart:

dolzenko avatar Nov 15 '24 08:11 dolzenko

Hi,

when I'm in magit-refs buffer

Not sure what this is. How to open it?

when in magit-log - opens commit.

git-link-commit will work if on a commit hash. What do you want to do instead?

In general should work with a variety of magit buffers: https://github.com/sshaw/git-link/blob/fd33c3f7692bdf4b039afaa88cf07580429043ad/git-link.el#L424-L425

In a magit-status buffer, for example, git-link will generate a file link if executed on a file name. git-link-commit will generate a commit link if executed on a commit hash.

sshaw avatar Nov 16 '24 02:11 sshaw

Not sure what this is. How to open it?

with y key, its a list of branches basically

Ok, thanks, I get it know, I was expecting git-link to work when standing on commit in magit-log, I guess, maybe, the message can be adjusted, to at least hint the user at trying git-link-commit function, because currently it says 'can't figure what to link to' :)

Cheers again, looking from history it seems we've been together with gitlink for past decade so it's kind of anniversary for me heh

dolzenko avatar Nov 18 '24 09:11 dolzenko

Not sure what this is. How to open it?

with y key, its a list of branches basically

As yes, I know this :)

If the branch is expanded git-link-commit can be used on the SHA but I suppose you want do be able to link from the branch name?

Ok, thanks, I get it know, I was expecting git-link to work when standing on commit in magit-log,

Yes makes sense.

Cheers again, looking from history it seems we've been together with gitlink for past decade so it's kind of anniversary for me heh

Yes you have first PR for this repo! 💪

sshaw avatar Nov 20 '24 02:11 sshaw