From 91a8ca15696d3de2c71057630ced6971ead23ed4 Mon Sep 17 00:00:00 2001 From: Olivier Date: Mon, 27 Mar 2023 11:55:35 +0100 Subject: [PATCH] More lazygit notes --- programmes/lazygit.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/programmes/lazygit.md b/programmes/lazygit.md index 416672d..f49b513 100644 --- a/programmes/lazygit.md +++ b/programmes/lazygit.md @@ -36,7 +36,7 @@ Use Up/Down to choose a file/directory. Press space to stage/unstage a whole file/directory. -**Magic:** When on a file, you can see the diff on the right-hand-side. You can **click** on a line and press space to stage/unstage a single line(!!!). +**Magic:** When on a file, you can see the diff on the right-hand-side. You can **click** on a line (or hit `enter` on the file) and press space to stage/unstage a single line(!!!). *You can also press `v` to start a range and then press space to stage/unstage a range of lines.* Press `c` to make a commit — you get a single-line text editor. If you want to use a full editor, use `C`. @@ -83,3 +83,5 @@ If you can't resolve, you can always press `m` then choose `abort` to stop whate ## Other tips On a branch or commit: `g` brings up the 'reset' menu. I often use `g` → `soft` on a commit to un-commit things (this rolls back the branch to a previous point but keeps the changes as staged changes) so that I can tweak them however I like. When doing dirty work I will often make commits with rubbish names like 'STASH' and then later un-commit them and commit them thoughtfully. + +[15 Lazygit Features In Under 15 Minutes](https://yewtu.be/watch?v=CPLdltN7wgE) is a video by the author of lazygit which I think I found useful.