| 2021-10-14 |
| ← jazzy left | 00:04 |
| ← m0viefreak left | 00:06 |
| ← subopt left | 00:08 |
| ← ZacSharp left | 00:09 |
| → pyeverything joined | 00:09 |
| ← tdaeayusr^ left | 00:09 |
| ← emf left | 00:10 |
| → travaldo joined | 00:11 |
| ← Thanatermesis left | 00:13 |
| → chenqisu1 joined | 00:14 |
| ← pyeverything left | 00:14 |
| chenqisu1 → chenqisu12 | 00:14 |
| → jazzy joined | 00:18 |
| ← onizu left | 00:23 |
| ← chexum_ left | 00:25 |
| → chexum joined | 00:26 |
| ← pulse left | 00:27 |
| ← brianward left | 00:30 |
| ← JibStyle left | 00:33 |
| → emf joined | 00:34 |
| → ttree joined | 00:34 |
| ← Swahili left | 00:35 |
| → Swahili joined | 00:36 |
| → gco_ joined | 00:41 |
| ← causasui left | 00:44 |
| → causasui joined | 00:44 |
| ← causasui left | 00:45 |
| → causasui joined | 00:50 |
| ← causasui left | 00:51 |
| → causasui joined | 00:52 |
| ← causasui left | 00:53 |
| → causasui joined | 00:53 |
| ← thiago left | 00:55 |
| ← regf left | 01:01 |
| → raffaele__ joined | 01:03 |
| ← brettgilio left | 01:05 |
| ← Murr left | 01:08 |
| → Murr joined | 01:08 |
| → brettgilio joined | 01:09 |
| ← igemnace left | 01:10 |
| ← computeiro left | 01:11 |
| ← o1lo01ol1o left | 01:11 |
| → thiago joined | 01:12 |
| → o1lo01ol1o joined | 01:12 |
| ← vdamewood left | 01:17 |
| ← durham left | 01:19 |
| → durham_ joined | 01:19 |
| ← TJ- left | 01:25 |
| → TJ- joined | 01:27 |
| → vdamewood joined | 01:27 |
| → LuxuryMode joined | 01:29 |
| ← causasui left | 01:30 |
| → Thanatermesis joined | 01:33 |
| ← austin987 left | 01:34 |
| → austin987 joined | 01:38 |
| → pyeveryt_ joined | 01:48 |
| ← YoungChiefBTW left | 01:49 |
| → YoungChiefBTW joined | 01:49 |
| → JibStyle joined | 01:51 |
| ← pyeveryt_ left | 01:52 |
| ← jinsun left | 01:59 |
| ← makara_ left | 02:03 |
| ← durham_ left | 02:04 |
| ← thiago left | 02:04 |
| ← makara left | 02:04 |
| → makara_ joined | 02:04 |
| → makara joined | 02:05 |
| → bn_work joined | 02:12 |
| ← keypusher left | 02:14 |
| ← jwillikers left | 02:15 |
| ← arcatech left | 02:17 |
| → keypusher joined | 02:24 |
| → rgrinberg joined | 02:27 |
| ← ttree left | 02:38 |
| ← travaldo left | 02:39 |
| ← JibStyle left | 02:44 |
| → causasui joined | 02:46 |
| ← ahappydeath left | 02:49 |
| ← pycurious left | 02:49 |
| ← FinnElija left | 02:50 |
| ← nyah left | 02:51 |
| ← tchan left | 02:52 |
| → FinnElija joined | 02:52 |
| → ttree joined | 02:56 |
| → Jong joined | 03:02 |
| prime- → prime | 03:02 |
| Hash → LordOfThePings | 03:05 |
| ← Murr left | 03:07 |
| → Murr joined | 03:07 |
| ← ChmEarl left | 03:08 |
| ← PocketKiller left | 03:11 |
| → durham joined | 03:12 |
| → PocketKiller joined | 03:12 |
| ← treefrob left | 03:14 |
| → majors_ joined | 03:15 |
| ← llh left | 03:18 |
| → llh joined | 03:18 |
| ← diverdude left | 03:19 |
| → diverdude joined | 03:21 |
| → kanzure joined | 03:21 |
| ← gco_ left | 03:26 |
| → treefrob joined | 03:27 |
| → thiago joined | 03:27 |
| → michele_ joined | 03:28 |
| ← michele left | 03:31 |
| ← durham left | 03:31 |
| ← diverdude left | 03:31 |
| → diverdude joined | 03:33 |
| ← bket left | 03:43 |
| → jess joined | 03:45 |
| → bket joined | 03:48 |
| ← juliopcrj left | 03:51 |
| ← ferdna left | 03:52 |
| → tchan joined | 03:54 |
| ← af left | 03:54 |
| → af joined | 03:57 |
| ← ttree left | 04:01 |
| ← zmt00 left | 04:04 |
| → zf joined | 04:05 |
| → zmt00 joined | 04:06 |
| → locrian9 joined | 04:07 |
|
zf
| hello folks. I have a large file a.txt, and in a single commit I move almost the entire contents of this file to b.txt, while creating a new a.txt in its place (boring code refactoring, basically). is there a way to make git generate a diff from /dev/null to a.txt, instead of from a.txt to a.txt? the diff should be a lot more readable that way | 04:09 |
| → yeirr joined | 04:10 |
| ← yeirr left | 04:10 |
| ← emf left | 04:11 |
|
zf
| -C works just fine for the copy, but I'm still left with hundreds of lines of deletion from a.txt to a.txt | 04:11 |
| → emf joined | 04:13 |
| → yeirr joined | 04:14 |
| → ttree joined | 04:18 |
| ← cliluw left | 04:20 |
| → cliluw joined | 04:24 |
| ← zebrag left | 04:28 |
| → jinsun joined | 04:29 |
| → ChemicalRascal joined | 04:31 |
| ← Thanatermesis left | 04:42 |
| LordOfThePings → EnchanterTim | 04:42 |
| → coot joined | 04:44 |
| → jimklimov1 joined | 04:46 |
| ← jimklimov left | 04:48 |
| ← af left | 04:55 |
| ← vishal left | 04:57 |
| → vishal joined | 05:00 |
| ← skered left | 05:05 |
| → madewokherd` joined | 05:07 |
| ← yeirr left | 05:08 |
| ← madewokherd left | 05:10 |
| ← average left | 05:16 |
| ← emf left | 05:20 |
| ← jetchisel left | 05:22 |
| ← rgrinberg left | 05:28 |
| ← ttree left | 05:34 |
| → jimklimov joined | 05:34 |
| → Smashcat joined | 05:35 |
| ← jimklimov1 left | 05:36 |
|
Smashcat
| Hi, I've got a problem with git - tried doing a pull just now and there's a conflict with a binary file. So I deleted the local binary file, but git still thinks it's there and refuses to pull again. Do I need to just clone the repo again to fix this? | 05:36 |
| → Assault joined | 05:41 |
| ← Smashcat left | 05:42 |
|
ChemicalRascal
| It sounds like you're still in the middle-- Oh, they left. | 05:42 |
| → TomyWork joined | 05:44 |
| ← gast0n left | 05:49 |
| ← frobnic left | 05:51 |
| → gco_ joined | 05:53 |
| → pyeveryt_ joined | 05:58 |
| → af joined | 05:59 |
| → yeirr joined | 06:00 |
| ← Lunatrius left | 06:02 |
| ← hbautista left | 06:03 |
| ← jazzy left | 06:08 |
| ← bloody left | 06:09 |
| ← af left | 06:12 |
| → af joined | 06:15 |
| ← locrian9 left | 06:17 |
| ← af left | 06:20 |
| → af joined | 06:25 |
| → euouae joined | 06:29 |
|
euouae
| Hello how can I rebase a branch I've merged a few times | 06:30 |
|
| to delete a commit? | 06:30 |
|
| I accidentally merged into a branch that was above main that I didn't want and then I committed a few times | 06:30 |
| → FH_thecat joined | 06:30 |
|
euouae
| so I want to remove one erroneous commit that slipped in there, even though I've undone all the work, I don't want it to be part of history | 06:30 |
| → Lunatrius joined | 06:32 |
|
mdk
| euouae: rebasing a branch with merge commits won't do. I don't know if there's an easy way for this one, it depend on the complexity of merge commits I imagine. Maybe try a git rebase -i and remove your commit AND merge commits? Never tried this... | 06:41 |
|
euouae
| mdk: I think maybe the easy way out is to create a new branch, apply all the commits on top and basically turn the history into a linear one? | 06:42 |
|
mdk
| euouae: that's what's a `git rebase -i` would do anyway, yes, those are equivalent, the `git rebase -i` way is more automated, the `manually create branch and cherry pick what you want` is the ... manual way | 06:43 |
| ← FemmeAndroid left | 06:46 |
|
euouae
| great, thank you | 06:47 |
| → ttree joined | 06:47 |
|
mdk
| euouae: tell me how it went maybe, I'm interested | 06:48 |
| → palasso joined | 06:53 |
|
euouae
| still trying to get it right | 06:58 |
|
| lol | 06:58 |
|
| I've realized that I've pushed some bad changes into my repo | 06:58 |
|
| but not upstream so | 06:58 |
|
| ugh | 06:58 |
| ← af left | 07:01 |
| → af joined | 07:02 |
| ← gco_ left | 07:02 |
|
euouae
| mdk, I pulled it off, I simply cherry picked the commits I needed and then deleted the old branch and renamed the new as the old | 07:04 |
|
| I don't know if that is the right way to do it but that worked fine | 07:04 |
|
| I'll have to force push later but that's fine too | 07:04 |
| ← unluckyshrubbery left | 07:04 |
|
mdk
| force pushing a personal branch is fine yes | 07:04 |
| → rfuentess joined | 07:05 |
|
mdk
| euouae: a good way to avoid those issues is to avoid merging in a personal branch, I just rebase them when absolutely needed, so you can always `git rebase -i` and play around without issues. Thanks for the feedback. | 07:06 |
| → ttree_ joined | 07:06 |
| ← ttree left | 07:07 |
| ← ttree_ left | 07:07 |
| → ttree joined | 07:07 |
| ← Murr left | 07:07 |
| → Murr joined | 07:08 |
|
euouae
| Yeah I'm like a baby stumbling while learning to walk mdk | 07:08 |
|
| but maybe in this particular instance it was also my mistake for committing something that's wrong | 07:09 |
| ← diverdude left | 07:10 |
| → onizu joined | 07:11 |
| → vladoski joined | 07:13 |
| ← causasui left | 07:16 |
| → diverdude joined | 07:16 |
| ← Gustavo6046 left | 07:20 |
| → Gustavo6046 joined | 07:20 |
| → jinsun__ joined | 07:21 |
| ← ChemicalRascal left | 07:24 |
| ← dayday left | 07:24 |
| ← jinsun left | 07:25 |
| → frobnic joined | 07:28 |
| ← hnOsmium0001 left | 07:30 |
|
j416
| keeping topic branches up-to-date by rebasing them frequently is usually a good idea | 07:30 |
| ← AbleBacon left | 07:31 |
| → kenanmarasli joined | 07:32 |
|
dob1
| when I have just one remote branch this become an upstream branch ? | 07:33 |
|
euouae
| upstream is just a word | 07:33 |
|
bookworm
| not only no | 07:33 |
|
| --set-upstream-to | 07:34 |
|
euouae
| oh my bad -- I thought 'upstream' was not used as a term | 07:34 |
|
| apologies | 07:34 |
|
j416
| dob1: "upstream" usually means "remote tracking branch" or "remote repo" or "repo which I forked off of" | 07:34 |
|
| branch@{upstream} (or branch@{u}) (remote tracking branch); --set-upstream-to (remote repo) as mentioned | 07:36 |
|
dob1
| sorry for newbie questions, but I really don't understand the use of this feature. If I have 2 branches, main and dev, and I push them to a remote, why I need to set upstream? what will change? | 07:37 |
|
j416
| dob1: it's the difference of having to specify "git push origin main" every time, or just being able to run "git push" | 07:37 |
|
| dob1: .git/config contains config saying that your branch "main" has its upstream (remote tracking branch) set to for example origin/main | 07:38 |
|
| dob1: if you have set up your prompt to show info like ahead/behind, this will also use the configured upstream | 07:38 |
| ← sudoforg1 left | 07:39 |
|
j416
| dob1: a branch does not have to have a corresponding remote branch; it can be only local if you want. | 07:39 |
|
| dob1: just like a repo does not have to have a remote configured; it can be only local. | 07:40 |
| ← ttree left | 07:40 |
| ← momomo_ left | 07:46 |
|
dob1
| ah in practice every branch that I want to keep in sync with has to be an upstream branch, am I right? | 07:46 |
|
| *with remote | 07:46 |
|
| without marking it as upstream every tiem I have to do git push origin branch | 07:46 |
| → momomo joined | 07:46 |
| → jetchisel joined | 07:54 |
|
dob1
| ok it seems this, I am testing a bit from what j416 wrote | 07:54 |
| ← o1lo01ol1o left | 07:55 |
| → jimklimov1 joined | 08:01 |
| ← pyeveryt_ left | 08:02 |
| → dimi1947 joined | 08:02 |
| → pyeveryt_ joined | 08:02 |
| ← jimklimov left | 08:03 |
| → Nspace joined | 08:06 |
| ← pyeveryt_ left | 08:07 |
| ← lgc left | 08:09 |
|
j416
| not _be_, it has to _have_ one. | 08:10 |
| → pyeveryt_ joined | 08:10 |
| → lllh joined | 08:11 |
| → JibStyle joined | 08:11 |
|
j416
| your local branch (main) is not the same as the remote tracking branch (origin/main) which in turn is not the same as the corresponding branch in the remote repo, but they are typically (and by default) set up to follow one another | 08:11 |
| ← llh left | 08:12 |
| ← Nspace left | 08:15 |
| → mikisid joined | 08:15 |
| → o1lo01ol1o joined | 08:18 |
| ← JibStyle left | 08:24 |
| → spare joined | 08:24 |
| → JibStyle joined | 08:24 |
| ← bkircher left | 08:25 |
| ← tejr left | 08:28 |
| ← spare left | 08:29 |
| → spare joined | 08:29 |
| ← spare left | 08:29 |
| → tejr joined | 08:29 |
| ← momomo left | 08:30 |
| ← euouae left | 08:34 |
| ← FH_thecat left | 08:37 |
| → bkircher joined | 08:37 |
| → skapata joined | 08:44 |
| ← skapata left | 08:44 |
| → skapata joined | 08:44 |
| ← madewokherd` left | 08:44 |
| ← LuKaRo left | 08:49 |
| ← dimi1947 left | 08:50 |
| → dimi1947 joined | 08:51 |
|
Timvde
| Does `git diff` act differently when in an "unmerged paths" state? | 08:51 |
| ← emanuele6 left | 08:51 |
| ← o1lo01ol1o left | 08:52 |
|
Timvde
| I was super confused by its output, then I did `git add -u && git reset` (which shouldn't change anything) and I got the expected output | 08:52 |
| → guardian joined | 08:52 |
| → o1lo01ol1o joined | 08:52 |
|
guardian
| Hello. I just upgraded to Git 2.33.windows.1 and now I get to see "info: detecting host provider for 'https://example.com'... messages when doing git fetch | 08:53 |
| → otisolsen70 joined | 08:53 |
|
guardian
| What's this message about? It prints like 3 times per repo | 08:53 |
| → raxor2k joined | 08:53 |
|
raxor2k
| i have several up and running API`s that do different AI/maachine learning work, and now i want to push all this to github | 08:54 |
| → LuKaRo joined | 08:54 |
|
raxor2k
| should i push all those as several repos inside a big folder or just push them by themselves? | 08:54 |
| ← raxor2k left | 08:54 |
| → raxor2k joined | 08:54 |
| ← o1lo01ol1o left | 08:54 |
| → o1lo01ol1o joined | 08:55 |
|
mgedmin
| Timvde: yeah, IIRC git diff tries to diff all three versions (base, ours, theirs) when a path is unmerged; and git add "resolves" merge conflicts | 09:02 |
|
Timvde
| mgedmin: Hmkay, I should look into how that works then, because it was confusing the hell out of me | 09:02 |
| ← o1lo01ol1o left | 09:02 |
| → o1lo01ol1o joined | 09:03 |
|
Timvde
| I see now that there are indeed two columns with + and - in front | 09:03 |
|
mgedmin
| conflicts are confusing; after much flailing I settled on the diff3 format of conflict markers as the most readable one for me personally | 09:04 |
|
| (git config --global merge.conflictStyle diff3) | 09:04 |
|
Timvde
| I'm okay with the in-file markers | 09:05 |
| → mat001 joined | 09:06 |
|
JibStyle
| Big +1 on diff3 output, makes it much easier to determine what's going on. | 09:06 |
|
cbreak
| you can use a merge tool gui thingie too | 09:08 |
|
guardian
| apparently the message is emitted by git-credential-manager-core: trace: run_command: git-credential-manager-core get | 09:11 |
|
JibStyle
| Timvde: In git diff output for a merge, keep in mind the merge commit is based on top of _two_ parent commits. That is why the git diff output has two columns of +- characters. One column indicates a difference between parent A and child, and the other column, parent B and child. | 09:11 |
| → emanuele6 joined | 09:11 |
| ← emanuele6 left | 09:11 |
| → emanuele6 joined | 09:11 |
| → unluckyshrubbery joined | 09:14 |
| ← Swahili left | 09:16 |
| → Swahili joined | 09:16 |
| ← pyeveryt_ left | 09:21 |
| → tdaeayusr^ joined | 09:21 |
| → pyeveryt_ joined | 09:22 |
| ← JibStyle left | 09:25 |
| → JibStyle joined | 09:25 |
| ← pyeveryt_ left | 09:27 |
| → tuskkk____ joined | 09:29 |
| → mei6 joined | 09:34 |
| ← mikisid left | 09:36 |
| ← tdaeayusr^ left | 09:46 |
| → Tobbi_ joined | 09:46 |
| ← The_Blode left | 09:46 |
| → otisolsen70_ joined | 09:49 |
| → The_Blode joined | 09:49 |
| ← otisolsen70 left | 09:53 |
| → tirnanog joined | 09:54 |
| → Rashad joined | 09:55 |
|
Rashad
| Hello. What would you say is a thing in git that is right in the middle between being a complete beginner and an expert? | 09:56 |
|
| If such a thing exists anyway... | 09:57 |
|
| I am thinking rebasing maybe? | 09:57 |
|
ikke
| git bisect | 09:58 |
|
osse
| writing decent commit messages :p | 09:58 |
|
Rashad
| I understand commits, .git, push, pull, fetch, pull request, branching, remotes, amending commits, and perhaps more that I can't recall now, but I have a little bit of difficulty understanding stuff like rebasing, cherry picking and "fix up", whatever that is. | 09:58 |
| → otisolsen70 joined | 09:59 |
|
Rashad
| ikke: Haven't heard of it before | 09:59 |
|
| https://git-scm.com/docs/git-bisect -- Interesting concept | 10:01 |
|
| Can someone please explain to me what rebasing is and why is it different from reset? | 10:01 |
|
| Like what is the motivation for such things to exist | 10:01 |
| jinsun__ → jinsun | 10:01 |
|
bookworm
| did you read the corresponding sections in the git book? | 10:02 |
| ← otisolsen70_ left | 10:02 |
|
bookworm
| what wasn't clear in there for you? | 10:02 |
|
| it explains the why's | 10:02 |
|
Rashad
| bookworm A little while ago I did, yes, but I keep forgetting what I read because 1) I don't practice it, or 2) I don't understand why it exists, or rather why it exists as the way it does | 10:03 |
| ← Vonter left | 10:03 |
|
bookworm
| then practice it :) | 10:03 |
|
Rashad
| In my beginner mind I am just looking for an "undo" button. | 10:03 |
|
bookworm
| mess up a commit, then clean up the history | 10:03 |
| ← raxor2k left | 10:04 |
|
bookworm
| there's various level of undo | 10:04 |
| → dscho joined | 10:04 |
|
Rashad
| If I go to intellij and do an "interactive rebase", a lot of things show up and I click, click, click then it says the whole thing needs to abort. | 10:04 |
|
osse
| rebase = re-base = move the base of a series of commits | 10:04 |
|
bookworm
| you don't want to redo all the work, so reset isn't always applicable | 10:04 |
|
osse
| re-base: https://raw.githubusercontent.com/Osse/git-stuff/master/rebase.txt | 10:05 |
|
bookworm
| don't do it on intelliJ if you wanna learn, use git | 10:05 |
|
Rashad
| (At least it asks nicely if I want to abort, so I am not mad at it) | 10:05 |
|
| osse: In that link what happens to E - F - G - H? | 10:06 |
|
osse
| nothing | 10:06 |
|
Rashad
| Oh right I see now... I thought they were removed from the diagram. | 10:06 |
|
| OK so someone already merged another-feature into master and me in feature needs to stay uptodate... right? | 10:07 |
|
osse
| for example, yes. | 10:07 |
|
| master has moved on since the feature branch was created. | 10:08 |
|
Rashad
| So usually I would rebase a feature branch but not the master branch? | 10:08 |
|
| Does rebasing need two branches or can I rebase the same branch onto itself and would that be useful? | 10:09 |
| → Vonter joined | 10:09 |
|
Rashad
| bookworm: I think I understand what you mean now by "move the base of a series of commits" | 10:10 |
|
osse
| you can rebase onto anything. in the diagram you could rebase feature onto any of E-H, or even D itself (which lets you do some interesting things). | 10:10 |
|
bookworm
| not just moving the base, reordering / squashing some commits etc | 10:10 |
|
| you use it to clean up the history as well | 10:10 |
|
Rashad
| Rebase onto D??? | 10:10 |
|
| Isn't that the same thing as before? | 10:11 |
|
osse
| yep | 10:11 |
|
Rashad
| So why would that be interesting? | 10:11 |
|
osse
| let me rephrase: Most of the time it would be a no-op. But the squashing and whatnot can be done here | 10:11 |
|
Rashad
| oh you mean change I - J - K - L along the way while you are rebasing? | 10:11 |
|
| I see I see. | 10:11 |
|
| Is fix-up imortant here? is it like amending a commit while rebasing? | 10:12 |
|
osse
| that's exactly what it is | 10:12 |
|
Rashad
| Nice. | 10:12 |
|
| And cherry picking? | 10:12 |
| ← dimi1947 left | 10:12 |
|
osse
| the squashing and reordering and rewording and all that stuff has been jammed into the rebase command because it fits nicely with how rebase works under the hood. But the problem with that is that the word re-base as sort of lost a bit of its meaning | 10:13 |
|
| what about cherry-picking? | 10:13 |
|
Rashad
| What does it do? | 10:13 |
|
osse
| copies a commit | 10:13 |
|
Rashad
| And deletes the old one? | 10:14 |
|
osse
| no | 10:14 |
|
Rashad
| Oh ok I get it now. | 10:14 |
|
| It copies it from master | 10:14 |
|
| to feature | 10:14 |
|
| No? | 10:14 |
| ← tejr left | 10:14 |
|
osse
| that's up to you | 10:15 |
|
| git cherry-pick abc1243 makes a new commit that does the same changes as abc1243 | 10:15 |
| ← palasso left | 10:16 |
| → Wuzzy joined | 10:20 |
|
Rashad
| In the same diagram: https://raw.githubusercontent.com/Osse/git-stuff/master/rebase.txt what happens if I rebase H onto F? | 10:20 |
|
| Does G get removed? Or does all that depends on what I do during the rebase? | 10:20 |
|
osse
| To do that you'd have to use the --onto flag, in which case G gets removed | 10:21 |
|
Rashad
| But typically one does that with reset? | 10:22 |
|
bookworm
| you can't do it with reset if you have more commits following H | 10:23 |
|
| you'd loose them | 10:23 |
|
s17
| tighten them | 10:23 |
|
bookworm
| reset resets the state to some other commit | 10:23 |
|
osse
| Rashad: no, you typically do that with rebase | 10:23 |
|
bookworm
| it doesn't put your changes somewhere else | 10:23 |
| ← bn_work left | 10:32 |
| ← Betal left | 10:32 |
| → rtjure joined | 10:32 |
|
Rashad
| Yay! just actually used rebase in a useful way in my project! | 10:33 |
|
| Rebase puts my changes somewhere else? | 10:34 |
|
| Can I undo a rebase? | 10:34 |
|
ikke
| reset the branch to the previous commit | 10:35 |
|
| it pointed to before | 10:35 |
|
Rashad
| Makes sense. | 10:35 |
|
| Do these "dangling" commits get deleted eventually after a certain period in time? | 10:36 |
|
ikke
| yes | 10:36 |
|
Rashad
| How much time exactly? | 10:36 |
|
ikke
| after ~90 days | 10:36 |
|
Rashad
| I see. | 10:36 |
|
ikke
| That's the reflog expiry time | 10:36 |
|
Rashad
| So reset is mostly for cases when you perhaps hit commit by mistake? | 10:37 |
|
ikke
| All kinds of situations | 10:37 |
| ← Wuzzy left | 10:40 |
| → Wuzzy joined | 10:40 |
| → spare joined | 10:41 |
| ← otisolsen70 left | 10:42 |
|
Rashad
| https://raw.githubusercontent.com/Osse/git-stuff/master/rebase.txt -- So I' - J' - K' - L' all have a ' because they are actually copies not the original commits.... | 10:47 |
| → computeiro joined | 10:47 |
|
osse
| correct | 10:47 |
| → mikisid joined | 10:48 |
|
Rashad
| osse: And cherry-pick means that I can get to choose which ones exactly get copied? | 10:49 |
|
osse
| that's one way of putting it, I guess | 10:50 |
|
ikke
| Rashad: the main usecase for cherry-picking is to back / forward port changes | 10:50 |
|
osse
| cherry-pick puts the new commit(s) directly on the branch where you are now (as if you did all the work by hand and used git commit). | 10:51 |
|
Rashad
| Aha. | 10:51 |
|
osse
| but yeah if you squint you can sort of view a rebase as a serial cherry-pick | 10:51 |
|
Rashad
| Right now I think rebase is something you must learn if you're going to use git seriously, especially in a team, which is why I am learning this. | 10:52 |
| ← o1lo01ol1o left | 10:52 |
|
Rashad
| If you are a project maintainer and you know how to rebase including using cherry-picking and whatnot, would that be "enough" or would you say there is something as crucial as rebase that needs to be addressed? | 10:53 |
|
| I am assuming knowing how to rebase means you know what commits and branches and remotes are and how to push and pull and fetch. | 10:53 |
|
| (And the details that come with such things like what is a master branch and what is a feature branch and what is a good way to arrange branches into development and production, etc) | 10:54 |
| → dayday joined | 10:54 |
|
Rashad
| I guess reflog is as important as rebase? | 10:54 |
| → ekathva joined | 10:55 |
|
Rashad
| I need to give a git course to my teammates so I am trying to understand how much more I have to learn for being able to use git with confidence to deliver new features. Bisect seems more about debugging so I am excluding it from the current course. | 10:55 |
| ← JibStyle left | 10:55 |
| → ApostleInTriumph joined | 10:57 |
|
Rashad
| Hopefully I can get a chance to cover the more advanced stuff next year, after everyone would know at least the basics. | 10:58 |
|
| Rashad brb | 10:58 |
| → rewrit3 joined | 11:00 |
| → pycurious joined | 11:00 |
| ← Murr left | 11:07 |
| → Murr joined | 11:07 |
|
osse
| I dunno. I'm not a teacher. | 11:09 |
|
| If I were you I'd watch a lot of videos and talks and see what they emphasize | 11:09 |
| ← ApostleInTriumph left | 11:10 |
|
furrymcgee
| git stash maybe useful for rebase | 11:10 |
|
osse
| And use that for inspiration. Try to use your best judgment about what will be relevant for your team | 11:10 |
| → chexum_ joined | 11:10 |
| ← chexum left | 11:10 |
| ← Lunatrius left | 11:13 |
| → pyeverything joined | 11:14 |
|
furrymcgee
| please mention tig text user interface and a suitable difftool like vim | 11:15 |
|
| difftool is essential for succesful git usage | 11:18 |
| → pulse joined | 11:20 |
| ← pyeverything left | 11:23 |
| ← mikisid left | 11:29 |
| ← yeirr left | 11:29 |
|
Rashad
| Thanks osse, furrymcgee, ikke, bookworm | 11:40 |
|
bookworm
| stash is not something I particularly like, for quick one offs sure but anything longer should be in a commit | 11:42 |
|
Rashad
| What's the difference between stash and shelve? | 11:43 |
|
| I already use shelve without completely understanding it but it is still useful. | 11:43 |
| → Lunatrius joined | 11:45 |
|
Rashad
| https://stackoverflow.com/questions/28008139/git-stash-vs-shelve-in-intellij-idea | 11:45 |
| ← jetchisel left | 11:55 |
| ← Gustavo6046 left | 11:56 |
|
osse
| i've no clue what shelve is | 11:59 |
| → Gustavo6046 joined | 11:59 |
|
osse
| ah, it's an IDE thing | 12:01 |
| → jwillikers joined | 12:03 |
| ← LuKaRo left | 12:03 |
| → jetchisel joined | 12:07 |
| ← Tobbi_ left | 12:07 |
| → Tobbi_ joined | 12:07 |
| → igemnace joined | 12:08 |
| ← tuskkk____ left | 12:09 |
| ← coot left | 12:11 |
| ← alkino left | 12:13 |
| → alkino joined | 12:13 |
| → rond_ joined | 12:14 |
| → LuKaRo joined | 12:19 |
| → node1 joined | 12:20 |
| → node1_ joined | 12:20 |
| ← dscho left | 12:20 |
| ← node1_ left | 12:23 |
| ← rahl left | 12:32 |
| → rahl joined | 12:34 |
| ← R2robot left | 12:35 |
| → R2robot joined | 12:35 |
| → yeirr joined | 12:36 |
| → woink joined | 12:38 |
| → R2robot_ joined | 12:42 |
| ← R2robot left | 12:43 |
| → speckz joined | 12:45 |
| → kawics11 joined | 12:47 |
| → hoochmonger joined | 12:48 |
| → coot joined | 12:49 |
| ← ekathva left | 12:52 |
| EnchanterTim → LordOfThePings | 13:01 |
| ← chenqisu12 left | 13:01 |
| → humky joined | 13:03 |
| → pyeverything joined | 13:05 |
| ← Xenguy left | 13:06 |
| ← kawics11 left | 13:07 |
| ← ThorMojito left | 13:07 |
| ← pyeverything left | 13:10 |
|
rond_
| using git submodules vs CMake's FetchContent for third party libraries - which one is preferred and why? | 13:11 |
| → bncn joined | 13:13 |
| ← The_Blode left | 13:14 |
|
pycurious
| how do i tell git to commit all *.py files but not anything else (regardless of path)? | 13:16 |
|
canton7
| pycurious, git add '**/*.py' ? Or leave the **/*.py unquoted to let your shell expand that instead of git | 13:17 |
|
pycurious
| canton7: Thanks! Let me try that | 13:18 |
|
rond_
| pycurious https://stackoverflow.com/questions/26682744/is-there-a-way-to-just-commit-one-file-type-extension-from-a-folder | 13:18 |
| ← speckz left | 13:18 |
|
pycurious
| Thanks! | 13:19 |
| → astroid99 joined | 13:19 |
| LordOfThePings → Hash | 13:22 |
| → roadie joined | 13:23 |
| ← node1 left | 13:33 |
| → speckz joined | 13:34 |
| ← rond_ left | 13:36 |
| ← rewrit3 left | 13:39 |
| → rewrit3 joined | 13:39 |
| ← rewrit3 left | 13:45 |
| → rewrit3 joined | 13:45 |
| → rgrinberg joined | 13:45 |
| ← Misotauros left | 13:49 |
| ← nvmd left | 13:55 |
| → nvmd joined | 13:56 |
| → pyeveryt_ joined | 14:01 |
| ← Assault left | 14:03 |
| ← rgrinberg left | 14:08 |
| → ishutin joined | 14:09 |
| → nyah joined | 14:10 |
| → AbleBacon joined | 14:11 |
| ← R2robot_ left | 14:14 |
| → ravan joined | 14:14 |
| → ChmEarl joined | 14:14 |
| → R2robot_ joined | 14:16 |
| → hnOsmium0001 joined | 14:18 |
| → Misotauros joined | 14:24 |
| ← pulse left | 14:36 |
| → eschwartz joined | 14:44 |
| ← Vonter left | 14:44 |
| → pulse joined | 14:45 |
| → bloody joined | 14:54 |
| → gast0n joined | 15:00 |
| ← astroid99 left | 15:00 |
| → bn_work joined | 15:01 |
| ← thiago left | 15:02 |
| → rgrinberg joined | 15:02 |
| → thiago joined | 15:03 |
| ← pyeveryt_ left | 15:04 |
| ← wyre left | 15:06 |
| ← vdamewood left | 15:06 |
| → wyre joined | 15:06 |
| → durham joined | 15:09 |
| → madewokherd joined | 15:21 |
| → zebrag joined | 15:22 |
| → rsx joined | 15:24 |
| → Vonter joined | 15:25 |
| → Assault joined | 15:26 |
| → justsomeguy joined | 15:34 |
| → Guest276 joined | 15:36 |
|
Guest276
| hi folks | 15:36 |
| ← Vonter left | 15:37 |
|
Guest276
| should i merge master into featue_branche to bring it up to date ? would this be considered bad practice ? | 15:38 |
|
| thanks | 15:38 |
| → Vonter joined | 15:38 |
| → rond_ joined | 15:39 |
|
ikke
| Guest276: it depends on the project. merging master into a feature branch is simpler, but also leads to more complicated (harder to follow) history | 15:39 |
|
| The alternative is to rebase your feature branch onto the latest version of master | 15:40 |
| → ThorMojito joined | 15:41 |
|
Guest276
| ikke: thanks for the reply, with your suggestion, we will keep both branches on same head ? | 15:41 |
|
ikke
| what do you mean with keeping both branches on the same head? | 15:43 |
|
Guest276
| master and feature_branche will be on same commit | 15:45 |
|
ikke
| no | 15:45 |
|
| if you rebase feature_branche onto master, it will be ahead of master | 15:45 |
| → subopt joined | 15:46 |
| subopt → _subopt | 15:46 |
|
Guest276
| so you know how to do this ? | 15:47 |
| ← rfuentess left | 15:48 |
|
ikke
| yes | 15:48 |
|
| git checkout feature_branch; git rebase master | 15:48 |
| ← LuxuryMode left | 15:49 |
| ← rsx left | 15:50 |
| ← pulse left | 15:56 |
| ← R2robot_ left | 15:59 |
|
Guest276
| ikke: many thanks | 16:00 |
| ← rond_ left | 16:01 |
| ← Guest276 left | 16:03 |
| ← justsomeguy left | 16:05 |
| ← kenanmarasli left | 16:06 |
| → hackinghorn joined | 16:06 |
| ← ormaaj left | 16:08 |
| ← Vipulk left | 16:08 |
| ← psydroid left | 16:08 |
| ← morguldir left | 16:08 |
| ← ServerStatsDisco left | 16:08 |
| ← kuhilas left | 16:08 |
| ← cpackham[m] left | 16:08 |
| ← YoungChiefBTW left | 16:08 |
| ← meain left | 16:08 |
| ← t_unix[m] left | 16:08 |
| ← kadoban left | 16:08 |
| ← Helmholtz left | 16:08 |
| ← Celmor[m] left | 16:08 |
| ← securethemews left | 16:08 |
| ← saltrocklamp[m] left | 16:08 |
| ← elemongw[m] left | 16:08 |
| ← ronny left | 16:08 |
| ← Fernando-Basso left | 16:08 |
| ← zfnmxt left | 16:08 |
| ← kedde[m] left | 16:08 |
| ← heftig[m] left | 16:08 |
| ← jmcantrell left | 16:08 |
| ← reddishblue[m] left | 16:08 |
| ← unclechu left | 16:08 |
| ← pinage404 left | 16:08 |
| ← miquella[m] left | 16:08 |
| ← jinsun_ left | 16:08 |
| ← erochow[hehim][m left | 16:08 |
| ← woss[m] left | 16:08 |
| ← Industrial[m] left | 16:08 |
| ← hsiktas[m] left | 16:08 |
| ← igemnace left | 16:09 |
| ← Vonter left | 16:10 |
| → pinage404 joined | 16:12 |
| → justsomeguy joined | 16:17 |
| → psydroid joined | 16:20 |
| → Fernando-Basso joined | 16:20 |
| → cpackham[m] joined | 16:20 |
| → Industrial[m] joined | 16:20 |
| → morguldir joined | 16:20 |
| → kadoban joined | 16:20 |
| → Vipulk joined | 16:20 |
| → ServerStatsDisco joined | 16:20 |
| → elemongw[m] joined | 16:20 |
| → t_unix[m] joined | 16:20 |
| → hsiktas[m] joined | 16:20 |
| → reddishblue[m] joined | 16:20 |
| → kedde[m] joined | 16:20 |
| → unclechu joined | 16:20 |
| → kuhilas joined | 16:20 |
| → YoungChiefBTW joined | 16:20 |
| → zfnmxt joined | 16:20 |
| → securethemews joined | 16:20 |
| → heftig[m] joined | 16:20 |
| → Helmholtz joined | 16:20 |
| → jmcantrell joined | 16:20 |
| → ronny joined | 16:20 |
| → jinsun_ joined | 16:20 |
| → Celmor[m] joined | 16:20 |
| → miquella[m] joined | 16:20 |
| → saltrocklamp[m] joined | 16:20 |
| → meain joined | 16:20 |
| → ormaaj joined | 16:20 |
| → woss[m] joined | 16:20 |
| → erochow[hehim][m joined | 16:20 |
| _subopt → subopt | 16:21 |
| → Trieste joined | 16:22 |
| ← ThorMojito left | 16:23 |
| → The_Blode joined | 16:25 |
| → hbautista joined | 16:26 |
| ← dka left | 16:27 |
| → dka joined | 16:28 |
| ← Trieste left | 16:28 |
| → Trieste joined | 16:30 |
| → Trieste_ joined | 16:36 |
| ← Trieste left | 16:37 |
| ← Assault left | 16:39 |
| ← justsomeguy left | 16:41 |
| → Trieste joined | 16:42 |
| ← jwillikers left | 16:42 |
| ← Trieste_ left | 16:42 |
| → pulse joined | 16:42 |
| → jazzy joined | 16:43 |
| → jwillikers joined | 16:45 |
| → Null_A joined | 16:50 |
| → Null_A_ joined | 16:52 |
| → Vonter joined | 16:55 |
| ← Null_A left | 16:55 |
| ← jwillikers left | 16:57 |
| → kenanmarasli joined | 17:05 |
| ← TomyWork left | 17:06 |
| ← Murr left | 17:07 |
| → Murr joined | 17:07 |
| ← zebrag left | 17:11 |
| ← Rashad left | 17:13 |
| ← Vonter left | 17:13 |
| → Rashad joined | 17:13 |
| → madewokherd` joined | 17:16 |
| ← vladoski left | 17:16 |
| → ekathva joined | 17:17 |
| → rafasc joined | 17:17 |
| ← hbautista left | 17:18 |
| ← madewokherd left | 17:19 |
| ← mei6 left | 17:19 |
| → DoofusCanadensis joined | 17:20 |
| → R2robot joined | 17:21 |
| → lgc joined | 17:22 |
| → jmd joined | 17:24 |
| → Vonter joined | 17:24 |
| → emf joined | 17:27 |
| → ThorMojito joined | 17:27 |
| ← emf left | 17:28 |
| ← Portugol9 left | 17:28 |
| ← Null_A_ left | 17:30 |
| → Null_A joined | 17:30 |
| ← Null_A left | 17:32 |
| ← bkircher left | 17:32 |
| → Null_A joined | 17:32 |
| → pyeverything joined | 17:32 |
| → TomyLobo joined | 17:34 |
| ← ghost43 left | 17:35 |
| → ghost43 joined | 17:35 |
| → emf joined | 17:39 |
| ← pyeverything left | 17:41 |
| ← yeirr left | 17:44 |
| ← Null_A left | 17:45 |
| → bkircher joined | 17:45 |
| ← emf left | 17:45 |
| → emf_ joined | 17:45 |
| → hornhack joined | 17:47 |
| ← hackinghorn left | 17:50 |
| → Null_A joined | 17:53 |
| ← SirRippovMaple3 left | 17:53 |
| → SirRippovMaple3 joined | 17:53 |
| ← dayday left | 17:54 |
| ← spare left | 17:54 |
|
Celelibi
| What's the right way to see the remote a branch is configured to follow? | 17:58 |
|
| Currently I just check .git/config | 17:59 |
|
rafasc
| git branch -vv shows it. | 18:00 |
|
| there's also a format spec for using with for-each-ref %(upstream) | 18:01 |
| ← speckz left | 18:03 |
| → hbautista joined | 18:04 |
| → cek joined | 18:05 |
| ← bkircher left | 18:07 |
| → bkircher joined | 18:20 |
| → batrick joined | 18:22 |
| ← YoungChiefBTW left | 18:24 |
| → YoungChiefBTW joined | 18:24 |
| → MickOfRivia joined | 18:26 |
| → Narrat joined | 18:27 |
| → Nspace joined | 18:34 |
| ← ThorMojito left | 18:35 |
| → ajfriesen joined | 18:42 |
|
nedbat
| if a directory has a .gitignore in it with "*" (to ignore the whole directory), can a .gitignore in the directory above override that with "!subdir" or something? | 18:45 |
| → Assault joined | 18:46 |
|
nedbat
| I'm thinking about a tool that writes reports into a directory, and adds the * as a convenience, but what if the unusual user wants to commit those files, is there something they can do to override the tool-written .gitignore? | 18:46 |
| ← Jong left | 18:46 |
| ← MickOfRivia left | 18:50 |
| → ThorMojito joined | 18:52 |
| ← ThorMojito left | 18:52 |
| ← tirnanog left | 18:53 |
| ← pycurious left | 18:54 |
| ← Nspace left | 18:55 |
|
rafasc
| I don't think it can. | 18:58 |
|
| but in that case they can override the nested .gitignore no? | 18:58 |
| → Nspace joined | 18:59 |
|
rafasc
| or do the one-time git add -f | 18:59 |
| ← FinnElija left | 19:02 |
|
nedbat
| rafasc: "override the nested .gitignore": you mean edit or delete it? | 19:02 |
| ← Nspace left | 19:03 |
|
rafasc
| whatever it works for them? | 19:03 |
|
nedbat
| rafasc: sure, but then running the tool again would recreate the file (potentially). that's why i was hoping something in the directory above could override it. | 19:04 |
| → ThorMojito joined | 19:04 |
| ← Byteflux left | 19:04 |
|
rafasc
| they can write exlusions inside that nested file. But is painful if you have depth. | 19:05 |
| → FinnElija joined | 19:05 |
|
nedbat
| rafasc: well, if they want the directory, they'll want the whole directory (it's an HTML report with multiple pages) | 19:06 |
|
| (and it's flat) | 19:06 |
|
rafasc
| then they can just leave the nested .gitignore empty? | 19:08 |
|
| and your tool just checks for the existence of the .gitignore. | 19:08 |
| ← ThorMojito left | 19:09 |
|
nedbat
| rafasc: true, it can only write the file if none exists | 19:09 |
| ← coot left | 19:10 |
| → ThorMojito joined | 19:11 |
| ← ThorMojito left | 19:11 |
| → ThorMojito joined | 19:12 |
|
rafasc
| I'm not really a fan of tooling adding git ignores, but I don't know your usecase, it could be justifiable. | 19:12 |
|
jmd
| How can I strip a repository? | 19:13 |
|
rafasc
| jmd: what does strip mean in this context? | 19:13 |
|
jmd
| I have a non-bare repo and I want it to be a bare one. | 19:13 |
|
cbreak
| git clone --bare or git clone --mirror | 19:14 |
|
| depending on your goals | 19:14 |
|
| or git init --bare, and push to it | 19:14 |
|
jmd
| I'll check those options. Thanks | 19:14 |
|
cbreak
| you can manually change it I think, that'd involve removing the index, changing the bare setting to true, and likely some other things | 19:15 |
| ← Vonter left | 19:15 |
|
nedbat
| rafasc: why don't you like tools adding .gitignore to their own directories? | 19:15 |
|
jmd
| .gitignore files are the biggest misfeature of git. They should never be used. | 19:16 |
| → pycurious joined | 19:16 |
|
bremner
| bold | 19:16 |
|
nedbat
| jmd: what do you suggest instead? and what's wrong with them? | 19:16 |
|
rafasc
| nedbat: mainly the lack of a counterpart that allows you to ignore tracked changes. | 19:17 |
|
jmd
| I suggest that files are not ignored. And the thing wrong with them is that they cause files to be ignored by tools such as git-status | 19:17 |
| → snedd joined | 19:19 |
|
nedbat
| jmd: so you would commit your .o, .pyc, .cache/*, etc files to git? | 19:19 |
|
rafasc
| that's basically its entire point. If you want status to show ignored fiels, use --ignored. | 19:19 |
|
jmd
| Either a file should exist, or it shouldn't. If it should exist then one should add it using git add. If it shouldn't exist then I want to know about it when it appears. | 19:19 |
| ← hbautista left | 19:19 |
|
bremner
| OK, well you're welcome to things your way, but I don't think the rest of the world will follow | 19:19 |
| → ZacSharp joined | 19:20 |
|
jmd
| Well if the rest of the world wants to commit (either advertently or inadvertently) their build artifacts, that is their choice. | 19:20 |
|
rafasc
| so you track your compiled artifacts? | 19:20 |
|
nedbat
| jmd: the world doesn't want to commit their build artifacts. they prevent it with .gitignore. | 19:21 |
|
| jmd: it sounds like you want to commit them. | 19:21 |
|
jmd
| No. I don't. That is why I want to see them. I DONT want them to be ignored. | 19:21 |
|
nedbat
| jmd: so you always completely clean them before committing? | 19:22 |
|
rafasc
| or work in projects that do not generate intermediate files. | 19:22 |
|
jmd
| ??? | 19:22 |
|
| Why would I do that? | 19:22 |
|
nedbat
| jmd: tell us how you avoid committing the build artifacts | 19:22 |
|
jmd
| nedbat: I never add them | 19:22 |
|
nedbat
| jmd: but you have to constantly see them in your git status then? | 19:22 |
|
rafasc
| how do I deal with git status becoming unusable because there's literally thousands of lines of untracked files? | 19:23 |
|
| that idea may work with small projects, but doesn't work at scale. | 19:23 |
|
ZacSharp
| isn't there a per repo (or per worktree?) location to add ignored files without the ignore file itself being in the repo? | 19:24 |
| ← emf_ left | 19:24 |
|
jmd
| nedbat: No. Normally they should not be shown. But if due to some mistake they do appear, then I WANT git status to list them. Then I know something has gone wrong and can do something about it. Otherwise there is a big risk of them getting committed by mistake. | 19:24 |
|
rafasc
| if you're trying to say that .gitignore files should not be committed, to prevent people forcing rules, I would partially understand. But ignore is a needed feature. | 19:24 |
|
| ZacSharp: yes .git/info/exclude | 19:24 |
|
nedbat
| jmd: what keeps the build artifacts from being shown? | 19:25 |
|
jmd
| I have never found a valid use for them. and I have seen them cause a lot of trouble. | 19:25 |
|
| nedbat: They are not shown because they are not (or at least should not be) in the source tree. | 19:25 |
|
rafasc
| jmd: you don't use git clean? | 19:26 |
|
jmd
| sometimes I do. | 19:26 |
| → molt joined | 19:26 |
|
rafasc
| for me, the main problem is that most people do not realize that .gitignore is not just for ignoring files. It's to ignore disposable files. | 19:27 |
|
| that's where most of the pain about ignores come from. | 19:27 |
|
nedbat
| rafasc: what's the distinction you're making there? How are people using it wrong? | 19:27 |
|
rafasc
| nedbat: gitignore was introduced to deal with intermediate files from compilation. Files that are generally considered trashable. | 19:28 |
|
jmd
| But that is a problem with the build system. | 19:28 |
|
nedbat
| rafasc: what have you seen of people using it for other things? | 19:28 |
| → Byteflux joined | 19:29 |
| → tdaeayusr^^ joined | 19:29 |
|
jmd
| If a compiler dumps crap in the source tree, that compile is buggy. Adding the .gitignore feature means that the compiler bug is just hidden. | 19:29 |
|
rafasc
| nedbat: ignoring configuration files, for example. | 19:29 |
|
nedbat
| rafasc: ah, right. "I need my own dev config" | 19:30 |
|
rafasc
| nedbat: see !config | 19:30 |
|
gitinfo
| nedbat: [!configfiles] It is recommended to store local configuration data in a file which is not tracked by git, but certain deployment scenarios(such as Heroku) may require otherwise. See https://gist.github.com/1423106 for some ideas | 19:30 |
|
nedbat
| jmd: you understand that your "buggy build system" category includes 99.999% of builds, yes? | 19:30 |
| → coot joined | 19:30 |
|
rafasc
| I am really curious about jmd's language of choice. | 19:31 |
|
nedbat
| jmd: what tech stack do you work in? | 19:31 |
|
jmd
| "tech stack" ? | 19:31 |
|
ZacSharp
| I would even consider it bad if the build system does anything outside the repo | 19:31 |
|
nedbat
| jmd: what programming language do you work with? | 19:31 |
| ← snedd left | 19:32 |
|
jmd
| *Shrug* depends on the application. c, lisp, occasionally c++ | 19:32 |
|
nedbat
| ZacSharp: i suspect jmd does not equate the git repo with the project tree. | 19:32 |
|
rafasc
| nedbat: https://public-inbox.org/git/xmqqy4z5go1y.fsf@gitster.dls.corp.google.com/ | 19:34 |
| → Vonter joined | 19:34 |
|
rafasc
| there was a thread a while ago about introducing a "precious" concept, but it's a contrived problem full of edge-cases. | 19:36 |
|
| In the end, it sums it up to: If you don't like it, don't use it. | 19:36 |
| ← Assault left | 19:36 |
|
rafasc
| I hate that commit has the -m flag. And it also causes problems by promoting bad commit messages. | 19:37 |
| ← ekathva left | 19:37 |
|
rafasc
| but that doesn't mean we should remove -m. | 19:38 |
|
jmd
| Yeah I don't. It's just annoying that whenever I start a new repo I have to write a server side hook to stop people pushing .gitignore files. | 19:38 |
|
rafasc
| yeah, but now you broke the rule. Because you're kind forcing other people to play by your rules. | 19:39 |
|
jmd
| Collaboration in a project requires that the team members adhere to basic rules. | 19:39 |
|
rafasc
| :D | 19:39 |
|
| yes, but that doesn't mean it should be *your* rules. | 19:40 |
|
| unless it's your project. | 19:40 |
|
jmd
| it is. | 19:40 |
| → emf joined | 19:49 |
| ← Vonter left | 19:50 |
| ← bkircher left | 19:52 |
| → tnecniv joined | 20:01 |
| ← Null_A left | 20:01 |
| ← Rashad left | 20:02 |
| → tuskkk____ joined | 20:03 |
|
tnecniv
| hello. i'm trying to resolve an issue where i committed a file that is way too large and i need to remove it without removing the commit history. basically i committed an Jupyter notebook that had some fancy images in it that made it over 100MB. This was a number of commits ago and I'm just noticing now. As the notebook is part of the codebase, I | 20:03 |
|
| dont want to mess with the commit history, but I can't currently push the project to my repository. I've already made the pertinent file appropriately svelte in the most recent commit. | 20:03 |
| → Null_A joined | 20:04 |
|
tnecniv
| but my git abilities are quite basic so i'm not sure what to do | 20:04 |
| ← fercell left | 20:05 |
|
rafasc
| you can git rm --cached <big file>; git commit. | 20:05 |
|
tnecniv
| most of the options i found seem like they purge things quite aggressively | 20:05 |
|
| that won't delete the actual file, will it | 20:05 |
|
| just the cache? | 20:05 |
|
rafasc
| basically that will create a new commit without that file in the repo. | 20:05 |
|
| no, if you use --cached, it will not remove the file from your local machine. | 20:05 |
|
tnecniv
| because the notebook is important i dont want to delete it from the disk | 20:06 |
|
rafasc
| if you use git rm <file>; it deletes from your local disk and from the git repo. | 20:06 |
|
| --cached will not delete if from disk. | 20:06 |
|
tnecniv
| and presumably this deletes the old version that's huge from whatever blob its in | 20:07 |
|
rafasc
| this part is a bit of a joke: even if it did, since you committed the file, you would be able to recover most of the changes :D | 20:07 |
|
tnecniv
| haha true | 20:07 |
|
rafasc
| that doesn't delete anything on the server. That 100mb file will be there forever. | 20:07 |
| ← alkino left | 20:08 |
|
tnecniv
| no the 100MB file is only local because github is rejecting my pushes since the payload is too big | 20:08 |
|
rafasc
| ah... | 20:08 |
|
tnecniv
| since i've been committing and pushing via PyCharm, i didnt notice until now | 20:09 |
|
| the error message is quite small | 20:09 |
|
rafasc
| then you probably want to edit your local commits, rewrite the local history, then push. | 20:09 |
|
tnecniv
| how does one do that | 20:09 |
|
rafasc
| the rm --cached will not solve your problem because the blob is there on the history. | 20:09 |
|
tnecniv
| right | 20:10 |
|
rafasc
| there are multiple ways. a rebase is one of the easiest if your history is simple. | 20:10 |
|
| but rebase is a bit of a more advanced operation. | 20:11 |
|
| can you post the output of !lol | 20:11 |
|
gitinfo
| A nifty view of branches, tags, and other refs: git log --oneline --graph --decorate --all | 20:11 |
|
rafasc
| !paste | 20:11 |
|
gitinfo
| Please use a pastebin for snippets longer than one line. Persistent and can be used with a GitHub account: https://gist.github.com/ - one hour auto-delete: https://upaste.de/ | 20:11 |
| ← jmd left | 20:13 |
| ← af left | 20:13 |
|
rafasc
| git rebase -i "commit that added big file"~1 ; mark first comit as 'edit', save and quit, do the git rm --cached; git rebase --continue; | 20:13 |
|
| that's the gist of it ^; I have to leave for now, but I'm sure someone else will be able to assit you. Good Luck | 20:14 |
| → Vonter joined | 20:15 |
| → clime joined | 20:15 |
| ← shabius left | 20:17 |
| → af joined | 20:20 |
|
tnecniv
| rafasc thanks. i actually also have to run but i'm saving this info i'll probably return tomorrow | 20:23 |
| → pyeveryt_ joined | 20:27 |
| → Nspace joined | 20:28 |
| ← coot left | 20:30 |
| ← pyeveryt_ left | 20:32 |
| ← af left | 20:33 |
| ← rafasc left | 20:33 |
| → af joined | 20:33 |
| → linguist joined | 20:34 |
| → bongobrown joined | 20:52 |
| ← af left | 20:52 |
| → dviola joined | 20:55 |
| ← alzgh left | 20:56 |
| ← rgrinberg left | 20:57 |
| → af joined | 20:58 |
| ← roadie left | 21:04 |
| → Cleverness joined | 21:07 |
|
jjakob
| I updated a submodule with new commits but the main project doesn't show any changes? | 21:07 |
| → Guest62 joined | 21:08 |
| ← ThorMojito left | 21:12 |
|
jjakob
| ah I had to set the right branch with submodule set-branch | 21:14 |
| ← wilz left | 21:15 |
| ← kenanmarasli left | 21:15 |
|
jjakob
| no that was not it | 21:16 |
| → rgrinberg joined | 21:18 |
| → sudoforg1 joined | 21:18 |
| ← ZacSharp left | 21:19 |
| → wilz joined | 21:19 |
| → ZacSharp joined | 21:19 |
| ← Null_A left | 21:21 |
| → Lord_of_Life_ joined | 21:25 |
| ← Lord_of_Life left | 21:26 |
| Lord_of_Life_ → Lord_of_Life | 21:26 |
|
jjakob
| hmm seems like going to the superproject of this superproject now shows the change there | 21:26 |
| → Null_A joined | 21:27 |
| → Portugol9 joined | 21:28 |
| → roadie joined | 21:30 |
| ← bongobrown left | 21:30 |
| ← Cleverness left | 21:31 |
| ← yourfate left | 21:31 |
| → yourfate joined | 21:31 |
| ← chexum_ left | 21:33 |
| → chexum joined | 21:33 |
| ← af left | 21:33 |
| → af joined | 21:34 |
| → astroid99 joined | 21:35 |
| cryptone1tor → cryptonector | 21:36 |
| ← Null_A left | 21:37 |
| → awmv joined | 21:41 |
| ← astroid99 left | 21:44 |
| ← Narrat left | 21:47 |
| → JibStyle joined | 21:47 |
| ← Guest62 left | 21:49 |
| → Cleverness joined | 21:52 |
| ← af left | 22:03 |
| → af joined | 22:05 |
| → Thanatermesis joined | 22:06 |
| ← rewrit3 left | 22:08 |
| → zebrag joined | 22:08 |
| → Aurora_v_kosmose joined | 22:15 |
| → ahappydeath joined | 22:15 |
|
Aurora_v_kosmose
| There's this idea of federated git that pops up from time to time that always seems to miss the point. Git is already federated. The question though, is whether something exists for indexing/discovery purposes that doesn't rely on some large company? | 22:15 |
| ← tnecniv left | 22:16 |
| ← wilz left | 22:30 |
| → causasui joined | 22:30 |
| ← mat001 left | 22:31 |
| → wilz joined | 22:33 |
| ← clime left | 22:34 |
| ← ahappydeath left | 22:34 |
| → ahappydeath joined | 22:38 |
|
shush
| How can I recover a popped stash's message? | 22:41 |
| ← gast0n left | 22:43 |
| ← ahappydeath left | 22:44 |
| ← Nspace left | 22:48 |
|
ZacSharp
| uh, I'm not sure but I think the list of stashes itself is the reflog so there is no reflog you could use to recover a stash and the only option left is searching through all unreachable commits (unless you checked out the stash or did other things making it show up in some other reflog) | 22:51 |
| → Null_A joined | 22:52 |
|
ZacSharp
| the manpage for git stash suggests git fsck --unreachable | grep commit | cut -d\ -f3 | xargs git log --merges --no-walk --grep=WIP` but I don't know what that actually does | 22:53 |
|
Aurora_v_kosmose
| I checked and stashes don't leave anything in the reflog once popped. | 22:53 |
| ← cek left | 22:53 |
|
ZacSharp
| "If you mistakenly drop or clear stash entries, they cannot be recovered through the normal safety mechanisms" | 22:54 |
|
| yep | 22:54 |
| → Xenguy joined | 22:57 |
| ← durham left | 22:58 |
| → igemnace joined | 23:00 |
| → pizdets_ joined | 23:03 |
| ← pizdets left | 23:03 |
| → ferdna joined | 23:15 |
| → elkalamar_ joined | 23:22 |
| ← elkalamar left | 23:25 |
| → gast0n joined | 23:45 |
|
nvmd
| what's the point of 'submodule absorbgitdirs'? | 23:46 |
|
| it does what the name says, but why? | 23:47 |
|
| what's the use case? | 23:48 |
| ← af left | 23:56 |