r/github • • Oct 18 '21

Useful shortcuts:

Post image
165 Upvotes

17 comments sorted by

7

u/[deleted] Oct 18 '21

This is helpful, thanks

2

u/[deleted] Oct 18 '21

nice and cold

7

u/bye_petrol Oct 18 '21

The last one is going to change my life

3

u/VxJasonxV Oct 18 '21 edited Oct 19 '21

. at the repository root opens it up generally for editing. . on a pull request opens it up on the branch as the image says. I don’t know if there are other context specific situations then those two.

The editor is always the same, it’s just the repo/git state on start.

1

u/semiquaver Oct 19 '21

Try it on a pull request or commit page.

1

u/VxJasonxV Oct 19 '21

Commit too makes sense, anywhere git state is reflected differently. Makes me wonder how many people are going to get frustrated because HEAD is detached, or they inadvertently fork off their default branch, or…

1

u/semiquaver Oct 19 '21

Does it let you commit to a detached head? I didn’t think it did.

1

u/VxJasonxV Oct 19 '21

You can’t, that’s my point. It’s hard for people to get into that state on their own repo unless they’re blindly following a tutorial and a cloned repo because only then would the SHAs be able to be checked out successfully.

(Hard, but not impossible.)

This also assumes VSCode will set up into that state when .ing on a last commit page, which I’m taking your word for it that it does. I haven’t tried it out for myself yet.

2

u/semiquaver Oct 19 '21

I should probably mention that I work at GitHub and contributed to this feature. If you see anything that doesn’t work right I’d be grateful for the feedback!

2

u/VxJasonxV Oct 19 '21

Neat! I used to work at GitHub (Pre-Microsoft)

I’ve been very happy to see that the quality of feature creation has not changed a bit.

3

u/blackjackns Oct 18 '21

Last one looks like a wall plug lol

2

u/revicon Oct 19 '21

I wish the web based vscode would let me run scripts, without being able to run unit tests the web editor seems like it has limited value

1

u/zvckp Oct 18 '21

What about vim users?

1

u/schm0 Oct 18 '21

Or anything else, for that matter.

1

u/scp-8989 Oct 18 '21

very impressive thanks!

1

u/bruhred Oct 27 '21

Sublime* or whatever you have set in Integration settings