| 2019-02-22 |
| → mven_ joined | 00:00 |
| ← raffo left | 00:01 |
| ← finalbeta left | 00:04 |
| → bjpenn joined | 00:04 |
|
bjpenn
| im working on a feature branch and i did 'git rebase master' on the feature branch | 00:05 |
|
| this put all my commmits on top, of everything on master | 00:06 |
|
| which is great | 00:06 |
|
| but i guess changed the commit numbers for my existing commits prior to the rebase? | 00:07 |
| ← freeman42x left | 00:07 |
| ← mjsir911 left | 00:09 |
|
j416
| why would you assume that? | 00:12 |
|
| what command did you run before the rebase that would change the commits? | 00:13 |
|
| or, do you mean that the rebase caused new commit hashes? | 00:13 |
|
bjpenn
| i think rebase caused new commit hashes | 00:14 |
|
| let me try to explain the scenario | 00:14 |
|
vishal
| normally rebase won't cause new hashes on master (in your case), but it definitely will for the commits that were brought over from 'topic' | 00:15 |
| ← egovirus left | 00:15 |
|
j416
| bjpenn: that's expected. | 00:15 |
|
bjpenn
| im working on a feature branch with a few new commits. I have a PR open for this feature branch | 00:15 |
|
| but since ive been working on this, master has changed quite a bit | 00:15 |
|
j416
| yes; you explained this above | 00:15 |
|
| you rebased and the hashes changed. | 00:16 |
|
bjpenn
| i wanted to locally incorproate the new changes in master, to run some tests, with my changes on top (so i used git pull master; siwtched to feature branch, and ran git rebase master) | 00:16 |
|
| so for the most part, this worked, git log showed my commits all on top | 00:16 |
|
| with the master commits right after ti | 00:16 |
|
| it* | 00:16 |
|
| i wasn't able to push though because it said its a non-fast-forward push | 00:17 |
|
j416
| yes, also expected. | 00:17 |
|
bjpenn
| why is that? | 00:17 |
|
j416
| you altered history | 00:17 |
|
bjpenn
| ah ok | 00:17 |
| ← Essadon left | 00:18 |
| → alyptik joined | 00:18 |
|
bjpenn
| j416: so in this situation how do i get it back to a point where i can push? | 00:18 |
|
| i guess what would be the best way in this scenario to unalter history | 00:18 |
| ← orbyt_ left | 00:20 |
|
vishal
| you can undo the rebase using reflog it it was just for throwaway testing and you care about the hashes on topic. Alternatively you can push --force if you don't care about the history (or if no one depends on it) | 00:20 |
|
bjpenn
| i do care about the history | 00:20 |
|
| hmm | 00:20 |
|
| so whats standard practice when performing a PR? | 00:21 |
|
| if you want to incorporate all the recent changes of master | 00:21 |
| ← yyy left | 00:21 |
|
bjpenn
| if i do a git merge master on my feature branch, and then push the feature branch | 00:21 |
|
| the PR will show every single commit since my changes right? | 00:21 |
|
| the PR will show every change thats already on master, in my PR right? | 00:22 |
|
vishal
| git reflog and git reset --hard HEAD@{XX} where XX is the number that refers to your rebase. I /think/ github is smart enough to figure out your branch was based off an older point in the history of master, and if it is mergeable, it /should/ just show your commits, but don't take my word for it | 00:23 |
| ← basteh left | 00:25 |
|
vishal
| indeed if you're based off an older version of master, the only commits that are in your feature branch, that are not already on master, are yours, and are the ones you want in the PR, right? | 00:26 |
|
bjpenn
| yes | 00:27 |
| → orbyt_ joined | 00:27 |
|
vishal
| the PR won't show commits in upstream's master that you are missing | 00:27 |
| ← orbyt_ left | 00:28 |
|
bjpenn
| before i submit my PR i want to merge with master, to incorporate all the upstream master changes into my branch | 00:28 |
|
| and run some tests | 00:28 |
|
| either rebase or master | 00:29 |
|
| rebase or merge* | 00:29 |
|
vishal
| in that case sounds like you will have to rebase and force push | 00:29 |
|
| or merge, yes | 00:29 |
|
bjpenn
| if i merge onto master from the feature branch | 00:30 |
|
| and then git push to my PR | 00:30 |
|
| will it show every single commit on upstream master, along with my changes | 00:30 |
|
vishal
| I'm not sure how github represents merges in PRs, but I wouldn't expect it to show any commits that are already on master | 00:32 |
|
| it will likely show one additional 'merge commit' | 00:32 |
|
| some upstreams may have a policy around that, if they want to keep their history linear, and in that case ask you to rebase instead of merging | 00:33 |
| → raffo joined | 00:34 |
|
vishal
| if there is not a linear history policy, it is generally recommended that you go the merge with master locally,. and do your testing, but in the PR use the original feature branch if there were no changes resulting from the testing | 00:35 |
|
| (and especially if it merges cleanly) | 00:35 |
|
| that way the project's history will show your topic branch being merged, instead of a random "merge master" which conveys less information | 00:35 |
| ← rothen left | 00:37 |
|
j416
| if the PR is still new and no one started looking at it, I'd rebase and force push. | 00:38 |
|
| if the PR has been looked at (there are comments etc.), I'd address those first and then rebase after a go-ahead from the reviewer(s) to avoid confusion. | 00:38 |
|
| bjpenn: ^ | 00:39 |
| ← n000g left | 00:42 |
| → n000g joined | 00:43 |
| ← mikecmpbll left | 00:45 |
| → renich_ joined | 00:47 |
| ← renich left | 00:47 |
| ← skyikot left | 00:47 |
| → www_t joined | 00:52 |
| ← blackmesa1 left | 00:52 |
| → aeyxa joined | 00:56 |
| ← raffo left | 00:56 |
| → hofmann3900 joined | 00:56 |
| ← Achylles left | 00:59 |
| ← de-facto left | 01:01 |
| → de-facto joined | 01:01 |
| ← vishal left | 01:05 |
| ← brandonkal left | 01:06 |
| → vishal joined | 01:07 |
| → raffo joined | 01:09 |
| ← ozcanesen left | 01:11 |
| → mjsir911 joined | 01:11 |
| ← m0viefreak left | 01:13 |
| ← mat001 left | 01:15 |
| → yohnnyjoe joined | 01:17 |
| ← kerframil left | 01:18 |
| → kerframil joined | 01:18 |
| ← raffo left | 01:21 |
| ← mobile_c left | 01:27 |
| ← kjartan left | 01:32 |
| → kjartan joined | 01:34 |
| → raffo joined | 01:35 |
| ← mjsir911 left | 01:35 |
| ← rafasc left | 01:46 |
| ← Sasazuka left | 01:46 |
| → orbyt_ joined | 01:52 |
| → ozcanesen joined | 01:55 |
| ← xrexeon left | 01:58 |
| ← ozcanesen left | 02:02 |
| → finalbeta joined | 02:06 |
| ← thiago left | 02:10 |
| → justanotheruser joined | 02:10 |
| → eb0t joined | 02:11 |
| ← eb0t_ left | 02:13 |
| → mowcat joined | 02:13 |
| ← aeyxa left | 02:16 |
| → mat001 joined | 02:17 |
| ← mat001 left | 02:18 |
| → mat001 joined | 02:18 |
| → mjsir911 joined | 02:19 |
| → mobile_c joined | 02:20 |
| → skyikot joined | 02:26 |
| → renich joined | 02:28 |
| ← renich_ left | 02:29 |
| ← F0rTex left | 02:30 |
| → F0rTex joined | 02:31 |
| ← null1337 left | 02:43 |
| → null1337 joined | 02:44 |
| ← renich left | 02:51 |
|
bjpenn
| j416 , vishal thanks for your feedback above | 02:55 |
|
| im reading into how to use the reflog now | 02:56 |
|
| seems like reflog is like an activity log | 02:56 |
|
| hopefully i can revert back | 02:56 |
|
| revert back to the point before i rebased on top of master | 02:56 |
| ← SleePy left | 02:57 |
| → SleePy joined | 02:59 |
| ← null1337 left | 03:00 |
| ← polyrob left | 03:00 |
| ← nuc left | 03:00 |
| → polyrob joined | 03:02 |
| → igemnace joined | 03:04 |
|
bjpenn
| in my reflog i can see that it keeps track of all my activity, and keeps of track of me switching branches and the entry in the reflog also corresponds that to a hash and HEAD@{XX} | 03:05 |
|
| is it possible for me to reset it to that point in time? | 03:05 |
| → stitched_unicorn joined | 03:06 |
| → blackbaba joined | 03:06 |
| ← cfoch left | 03:09 |
| ← blackbaba left | 03:09 |
| lagothrix → Guest72529 | 03:09 |
| ← Guest72529 left | 03:09 |
| → lagothrix joined | 03:10 |
| → awkwords joined | 03:11 |
|
bjpenn
| looks like it worked | 03:15 |
| ← inkbottle left | 03:16 |
|
bjpenn
| just using git reset HEAD@{XX} , where HEAD@{XX} corresponds to the most recent commit acitivity i wanted to go revert to, worked | 03:16 |
|
| i didn't try reseting to a commit hash referencing a branch switch though | 03:16 |
| → davidfetter joined | 03:22 |
|
davidfetter
| hi | 03:22 |
|
| Is there any way using only git to see that a flock of patches was part of a particular pull request? | 03:22 |
| → thiago joined | 03:32 |
| ← mowcat left | 03:36 |
| ← Dirak left | 03:47 |
| ← igemnace left | 03:48 |
| → igemnace joined | 03:50 |
| ← wolfshappen left | 03:59 |
| → wolfshappen joined | 04:01 |
| ← jungsubk left | 04:02 |
| ← yohnnyjoe left | 04:07 |
| ← diogenese left | 04:11 |
| → diogenese joined | 04:11 |
| ← mobile_c left | 04:12 |
| ← orbyt_ left | 04:12 |
| ← wyre left | 04:14 |
| → Cabanoss- joined | 04:14 |
| ← Cabanossi left | 04:14 |
| Cabanoss- → Cabanossi | 04:14 |
| → Goplat joined | 04:18 |
| → energizer` joined | 04:18 |
| ← xcm left | 04:18 |
| → xcm joined | 04:18 |
|
energizer`
| when i get merge conflicts i get these things >>>>>>>> and <<<<<<<<<<<<<< | 04:19 |
|
| am i supposoed to manually edit those things away? | 04:19 |
| ← kerframil left | 04:21 |
| ← topdownjimmy left | 04:21 |
| → topdownjimmy joined | 04:21 |
|
davidfetter
| energizer`, yep | 04:22 |
|
| pick one side, the other, or a mix, and remove the lines with those >>>>>>>>>>>>>>>>>>>>> and <<<<<<<<<<<<<<<<<<<<< on them | 04:22 |
| → keepLearning512 joined | 04:23 |
|
energizer`
| davidfetter, alright. i'm honestly a bit surprised i don't see >>>><<< appearing in source code by accident, it seems like an easy mistake to just miss one | 04:23 |
|
davidfetter
| they're there because they're really easy to find with any editor's search functionality | 04:24 |
| ← zulutango left | 04:26 |
| ← keepLearning512 left | 04:28 |
| → client35 joined | 04:31 |
| → zulutango joined | 04:35 |
|
client35
| How would I go about pulling certain branches down that had changes made to them? For example, I have "a" branch, that I'm merging everything into before merging into master. I'm currently working on some code in "b" branch as well as "c" branch. However, when I try pulling git pull origin b I lose files from a and vice versa | 04:37 |
|
| I did stash my code locally b/c I had made changes that were going to be overwritten, but wasn't sure if I needed to repull the entire repo? | 04:37 |
| → esenegoid joined | 04:37 |
| ← diogenese left | 04:38 |
| esenegoid → diogenese | 04:38 |
| → jungsubk joined | 04:41 |
| ← awkwords left | 04:42 |
| → howdoi joined | 04:43 |
| ← zulutango left | 04:47 |
| → mobile_c joined | 04:48 |
| → __rohit joined | 04:51 |
| → miczac joined | 04:53 |
| → zulutango joined | 04:58 |
| ← __rohit left | 04:58 |
| → __rohit joined | 04:59 |
| → mal10c joined | 04:59 |
| → dre_ joined | 05:01 |
| → pks_ joined | 05:02 |
| ← pks left | 05:02 |
| pks_ → pks | 05:02 |
| → v01d4lph4 joined | 05:05 |
| ← v01d4lph4 left | 05:05 |
| → v01d4lph4 joined | 05:05 |
| ← kadoban left | 05:07 |
|
client35
| :/ | 05:10 |
| ← zulutango left | 05:12 |
| ← boombatower left | 05:13 |
|
davidfetter
| client35, this isn't a super active channel. are you more a merger or a rebaser? | 05:16 |
|
client35
| Ah okay, is there a more active channel, maybe slack or discord? I'm kind of new to git - I know how to clone, push pull, checkout branches and push those but I don't have much experience with merging or rebasing I'm afraid | 05:17 |
| ← mven_ left | 05:20 |
| ← ym555 left | 05:20 |
| → zulutango joined | 05:22 |
|
davidfetter
| I believe this is it. I'm kinda new to it, too, so please bear with me. | 05:22 |
|
| what do you mean by "stash my code locally?" is that as in git checkout foo && hackety-hack-hack && git stash | 05:22 |
|
| ? | 05:22 |
|
client35
| No worries, thank you for the help either way :)stash locally meaning I | 05:23 |
| ← mjsir911 left | 05:23 |
|
client35
| err, trying to do new line lol - git stash, rather, just to save some code | 05:23 |
|
| It stashed changes I made to a file locally. Don't worry about it now though because I ended up re-cloning the repo to start over; thank you though. | 05:24 |
|
| I appreciate it | 05:25 |
| → cdown joined | 05:28 |
| ← skyikot left | 05:33 |
| ← deltab left | 05:34 |
| → rsrx joined | 05:35 |
| ← bn_work left | 05:36 |
| → tsdh joined | 05:37 |
| → keepLearning512 joined | 05:38 |
| → deltab joined | 05:41 |
| ← keepLearning512 left | 05:44 |
| ← miczac left | 05:44 |
| → skyikot joined | 05:45 |
| ← jungsubk left | 05:48 |
|
notmike
| stash is a myth perpetrated by the government order to further subjugate the black man | 05:48 |
| ← justanotheruser left | 05:49 |
| ← stitched_unicorn left | 05:53 |
| ← cdown left | 05:54 |
| → justanotheruser joined | 05:57 |
| ← __rohit left | 05:57 |
| → miczac joined | 05:58 |
| → jungsubk joined | 06:13 |
| ← mobile_c left | 06:16 |
| ← energizer` left | 06:17 |
| ← opalepatrick left | 06:29 |
| ← rsrx left | 06:30 |
| ← client35 left | 06:32 |
| ← Cabanossi left | 06:39 |
| ← miczac left | 06:41 |
| → plexigras joined | 06:42 |
| ← de-facto left | 06:45 |
| → Cabanossi joined | 06:46 |
| → de-facto joined | 06:49 |
| ← oojacoboo left | 06:53 |
| ← skyikot left | 06:59 |
|
osse
| Correct | 07:00 |
| → stitched_unicorn joined | 07:05 |
| → lowbro joined | 07:07 |
| → rsrx joined | 07:07 |
| → sauvin joined | 07:09 |
| → wxg joined | 07:16 |
| ← stitched_unicorn left | 07:17 |
| ← netj left | 07:26 |
| ← Trieste left | 07:26 |
| → Trieste joined | 07:28 |
| → netj joined | 07:28 |
| ← Goplat left | 07:31 |
| ← thiago left | 07:32 |
| → miczac joined | 07:32 |
| → chele joined | 07:34 |
| ← netj left | 07:42 |
| → netj joined | 07:45 |
| → n3wborn joined | 07:46 |
| → mven_ joined | 07:46 |
| ← kjartan left | 07:47 |
| → irc_viewer_test joined | 07:48 |
| → oxymoron93 joined | 07:49 |
| → supernov1h joined | 07:50 |
| → kjartan joined | 07:51 |
| ← mven_ left | 07:52 |
| → Makaveli7 joined | 07:53 |
| ← irc_viewer_test left | 07:55 |
| ← xcm left | 07:59 |
| → xcm joined | 08:00 |
| ← zulutango left | 08:06 |
| ← gxt left | 08:07 |
| → theoceaniscool joined | 08:09 |
| → zulutango joined | 08:10 |
| → sQVe joined | 08:11 |
| → dege joined | 08:15 |
| → interrobangd joined | 08:15 |
| ← wxg left | 08:18 |
| ← mat001 left | 08:39 |
| ← rsrx left | 08:40 |
| ← hussam left | 08:45 |
| → blackmesa joined | 08:46 |
| ← SuperLag left | 08:48 |
| → gxt joined | 08:49 |
| → keepLearning512 joined | 08:53 |
| ← sjoshi left | 08:54 |
| ← Sleepy63 left | 08:55 |
| → SuperLag joined | 08:55 |
| → hussam joined | 08:58 |
| ← miczac left | 09:01 |
| → YuGiOhJCJ joined | 09:01 |
| → floppydh joined | 09:03 |
| → mikecmpbll joined | 09:06 |
|
tsdh
| osse: Just got the "git status" shows modified but "git diff" shows nothing again. | 09:06 |
| ← bjpenn left | 09:06 |
|
tsdh
| git commit -am "foo" created no commit and git status still showed the modification. | 09:07 |
|
| git add <modified_file> staged nothing, but now git status is silent again. | 09:07 |
| ← Inline left | 09:08 |
| ← atrigent left | 09:08 |
| ← sQVe left | 09:08 |
| ← netj left | 09:08 |
| ← hofmann3900 left | 09:08 |
| → hofmann3900 joined | 09:09 |
| → netj joined | 09:11 |
| ← esotericnonsense left | 09:12 |
|
osse
| tsdh: are you on a weird file system by any chance? | 09:13 |
| ← howdoi left | 09:14 |
| ← davidfetter left | 09:15 |
|
tsdh
| osse: ext4 but I use autocrlf=input and work in a mostly-windows show where we have a wild mix of files with LF-EOL and CRLF-EOL... | 09:15 |
|
| s/show/shop/ | 09:16 |
|
osse
| tsdh: compare file thatfile.java and git show HEAD:thatfile.java | file - | 09:16 |
| ← netj left | 09:16 |
| ← rafalcpp left | 09:17 |
| ← pyfgcr left | 09:18 |
| → esotericnonsense joined | 09:18 |
| ← esotericnonsense left | 09:18 |
| ← queip left | 09:18 |
| → esotericnonsense joined | 09:19 |
| → pyfgcr joined | 09:20 |
| → netj joined | 09:22 |
| → nixroot joined | 09:23 |
| → WhereIsMySpoon joined | 09:23 |
|
WhereIsMySpoon
| Is anyone able to tell me why if I close a pr on github then rebase+force push, I cant then reopen the pr? Does the rebase/force push do something to the branch that github cant deal with? | 09:24 |
| → grr12314 joined | 09:25 |
| ← dpyro left | 09:25 |
|
osse
| WhereIsMySpoon: do you get an error message? | 09:25 |
|
WhereIsMySpoon
| the button is just greyed out | 09:26 |
|
tsdh
| osse: Same as yesterday, both are "Java source, UTF-8 Unicode text". | 09:27 |
|
osse
| WhereIsMySpoon: https://gist.github.com/robertpainsi/2c42c15f1ce6dab03a0675348edd4e2c | 09:27 |
|
| tsdh: try git update-index --really-refresh | 09:27 |
|
WhereIsMySpoon
| ive seen that | 09:27 |
|
| i want to know _why_ | 09:27 |
|
| not how to fix it | 09:27 |
|
| :) | 09:27 |
|
osse
| I have no idea | 09:27 |
|
| https://github.com/isaacs/github/issues/361#issuecomment-114297034 | 09:28 |
|
floppydh
| someone got impressions of https://gerrit.googlesource.com/git-repo/ ? | 09:28 |
| → Noti joined | 09:28 |
|
floppydh
| feels like there's still a need for something that integrates multiple git repositories | 09:28 |
|
canton7
| WhereIsMySpoon, because "github only lets you re-open a PR if the branch it was opened from hasn't changed", presumably. None of us work at github, so we can't explain why they made that decision | 09:28 |
|
WhereIsMySpoon
| thats...weird | 09:29 |
|
| "> because there is no good way to tell what changes have happened while a pull request was closed and the head branch has changed." surely you can just diff the changes and keep going | 09:29 |
|
canton7
| diff from what? the commit will probably have been garbage-collected | 09:29 |
|
WhereIsMySpoon
| oh really | 09:29 |
| ← nixroot left | 09:29 |
|
WhereIsMySpoon
| im unaware of garbage collection of commits/git refs etc | 09:29 |
|
osse
| But does it matter what happened during the time it was closed? | 09:30 |
| → mimajof joined | 09:30 |
|
tsdh
| osse: Since after "git add"-ing the modified file, it's not shows in git status anymore (neither as staged nor unstaged), I guess I'll have to wait until I'm in the modified-but-no-diff situation again, right? | 09:30 |
|
canton7
| WhereIsMySpoon, garbage collection of unreachable objects is a big part of git's management of its object database | 09:30 |
|
WhereIsMySpoon
| i see :) | 09:30 |
|
canton7
| man git gc | 09:30 |
|
gitinfo
| the git-gc manpage is available at https://gitirc.eu/git-gc.html | 09:30 |
|
osse
| tsdh: I guess. you can try 'git reset' to see if that changes anything, but I doubt it will | 09:30 |
|
tsdh
| osse: Nope, nothing. | 09:31 |
| ← hofmann3900 left | 09:31 |
| → hofmann3900 joined | 09:32 |
|
osse
| tsdh: do you have any idea of what might have happened? Did you modify the file, save, undo then save again or something like that? | 09:32 |
|
WhereIsMySpoon
| osse: if theres no previous commit or HEAD tracking then surely you wouldnt be able to reconstruct history and give the nice commit change history view they provide? | 09:34 |
|
osse
| WhereIsMySpoon: No, but in that case they could just display the PR as if it was new | 09:35 |
|
cbreak
| git commits always refer to their ancestors, if there are any | 09:35 |
|
canton7
| they might keep references to commits referenced by closed PRs, I don't know. I'm speculating, as that's the only thing any of us can do | 09:35 |
|
| maybe it's simply a matter of "we haven't paid for the work to support this yet" /shrug | 09:36 |
| → sQVe joined | 09:36 |
| ← mikecmpbll left | 09:38 |
| → mikecmpbll joined | 09:39 |
| → Inline joined | 09:40 |
|
tsdh
| osse: It always happens when I merge or cherry-pick from another branch. It's quite likely that in that branch, the file has another EOL encoding. And I think it happens only for files where I have a conflict that I need to fixup. | 09:40 |
| → yyy joined | 09:41 |
| ← grr12314 left | 09:41 |
|
tsdh
| osse: On a related note, I sometimes get files marked as conflicting in a merge but when I consult them, there are no conflict markers at all. | 09:42 |
|
floppydh
| what's your most liked alternative to git-submodules? | 09:43 |
| → ben914 joined | 09:48 |
| → miczac joined | 09:50 |
| ← jokajak left | 09:56 |
| → localhorse joined | 09:57 |
|
localhorse
| how can i rebase my local commit to master on top of origin/master without creating a temp local branch? | 09:58 |
|
osse
| tsdh: Everything sound weird. I would toss the PC out the window, quit and become a furniture carpenter | 09:58 |
|
localhorse
| the situation is: someone else committed and pushed to master first | 09:58 |
|
| i want to rebase on his commit | 09:58 |
|
osse
| localhorse: git rebase origin/master | 09:58 |
|
| assuming you're on master | 09:58 |
|
localhorse
| osse: not git pull --rebase origin/master ? | 09:58 |
|
osse
| that works too | 09:58 |
|
localhorse
| ok thanks | 09:59 |
| ← wolfshappen left | 09:59 |
|
osse
| my solution assumes you have fetched first. pull --rebase fetches | 09:59 |
|
localhorse
| ok | 10:00 |
|
| and another situation: feature2 branch forked off feature1 branch that forked off master. now feature1 was rebased on top of master. what to do with feature2 to also rebase it on top of the rebased feature1 branch? | 10:00 |
|
osse
| git rebase --onto=feature1 feature1{1} | 10:00 |
|
| ehh | 10:00 |
|
| git rebase --onto=feature1 feature@{1} | 10:00 |
|
| ehh | 10:00 |
|
| git rebase --onto=feature1 feature1@{1} | 10:00 |
|
localhorse
| why not git rebase origin/feature1 ? | 10:00 |
| → wolfshappen joined | 10:01 |
| → dhollin3 joined | 10:01 |
| ← zulutango left | 10:01 |
| ← interrobangd left | 10:03 |
| ← dhollinger left | 10:04 |
| → venmx joined | 10:05 |
| → achadwick joined | 10:05 |
| ← ben914 left | 10:06 |
| ← supernov1h left | 10:07 |
|
oxymoron93
| osse that command assumes one has checked out feature2 right? | 10:07 |
|
gthm
| I have some SVN repos I plan on converting to Git. The repos have large binaries checked in, so I'd like to involve Git LFS. Does anyone have experience with "retrofitting" Git LFS to an existing repo? | 10:07 |
| → supernov1h joined | 10:08 |
|
gthm
| As SVN history is linear, I can imagine rebasing .gitattributes with the LFS definitions to the start of the history, and then writing some gnarly Perl to walk the history and rewrite the commits that involve binary files to use LFS | 10:08 |
|
| but maybe someone already came up with a better idea | 10:09 |
| → Krafter joined | 10:09 |
| ← miczac left | 10:12 |
|
cbreak
| gthm: something like that was described in some git lfs docs I read years ago I think | 10:13 |
| ← YuGiOhJCJ left | 10:14 |
| → YuGiOhJCJ joined | 10:14 |
| ← dustinm left | 10:15 |
|
gthm
| ha! bfg has a --convert-to-git-lfs option | 10:16 |
| → dustinm joined | 10:17 |
|
gthm
| no perl/dogfood for gthm tonight | 10:17 |
| ← dustinm left | 10:17 |
|
supernov1h
| 1 | 10:19 |
| → dustinm joined | 10:20 |
| ← blackmesa left | 10:20 |
| ← Makaveli7 left | 10:23 |
| → blackmesa joined | 10:27 |
|
Krafter
| So, I have a workflow issue. Here is what I do. | 10:36 |
|
| 1. I checkout a new branch feature-1 from branch master. | 10:36 |
| → zulutango joined | 10:37 |
|
Krafter
| 2. I edit my code and make a few commits. | 10:37 |
|
| 3. I push the branch and ask for review of my PR. | 10:37 |
|
| 4. Before the PR has been accepted I create a new branch of off feature-1 called feature-2. | 10:37 |
|
| 5. I make a few more commits on feature-2 | 10:37 |
|
| 6. feature-1 has been approved and squash merged. | 10:37 |
|
| 7. Now the new feature-2 will have a bunch of "junk commits" from the old feature-1 branch. | 10:37 |
|
| How can I get rid of those? | 10:37 |
|
| I know that I work off the assumption that the PR of feature-1 will be accepted. | 10:38 |
|
supernov1h
| does git diff and git apply care about what commits are in place | 10:42 |
| ← n3wborn left | 10:42 |
|
supernov1h
| I have two identical repos, fetched to the latest revision, and checked out at the same commit but one has a bunch of stuff I want to make a patch of, send to another pc and apply | 10:42 |
|
| where I expect to commit | 10:42 |
| ← WhereIsMySpoon left | 10:43 |
|
osse
| oxymoron93: yes | 10:44 |
|
| localhorse: you said you wanted to rebase on top of feature1 | 10:44 |
|
| so why origin/feature1 ? | 10:44 |
| ← dre_ left | 10:45 |
|
supernov1h
| I ended up having to run diff -urN <(./path/to/file) <(git show <hash>:./path/to/file), modifying the path spec to match and then manually applying patches on a per-file basis | 10:45 |
|
| when I ran git apply it just said "patch does not apply" for all files | 10:45 |
|
osse
| git apply is very strict. I've had better results with patch | 10:46 |
|
| supernov1h: if what you want to make patches of are commits, then git format-patch is the tool to use | 10:47 |
|
supernov1h
| osse: no I just wanted a patch tool that understood the git pathspec and could diff stuff quickly | 10:48 |
|
osse
| sounds like git diff to me :O | 10:48 |
|
supernov1h
| exactly, but like I said, git apply said patch does not apply | 10:48 |
|
| after manually patching everything, the output of git diff -w is identical on both computers now | 10:49 |
|
osse
| if the two repos are on ther same commit, how can one have a bunch of stuff the other doesn't? | 10:50 |
|
tsdh
| osse: Hehe, I'm already working in the furniture industry! ;-) | 10:51 |
|
supernov1h
| patching and git have nothing to do with eachother | 10:51 |
|
gthm
| Krafter: The only thing I can think of is to create a new branch off master once feature-1 is merged and squashed ('feature-2-no-really-this-time') and cherry-pick your commits from feature-2 into it | 10:51 |
|
supernov1h
| git just understands the filesystem of a git archive | 10:51 |
|
| when it comes to generating a diff | 10:51 |
| → Achylles joined | 10:52 |
|
Krafter
| gthm: Thanks! | 10:52 |
|
osse
| Krafter: git rebase --onto is your friend | 10:53 |
|
| git rebase --onto=feature-1 {last junk commit} | 10:53 |
|
| Krafter: i re-read your question: git rebase --onto=master feature-1 | 10:54 |
| ← justanotheruser left | 10:54 |
| ← pix9 left | 10:55 |
|
Krafter
| osse: Doesn't rebase unlike most commands modify both branches? | 10:55 |
|
osse
| Krafter: no | 10:55 |
|
gthm
| osse: will that deal with the squashed commits? | 10:55 |
|
osse
| gthm: yes | 10:55 |
|
| Krafter: git rebase --onto=master feature-1 will take all commits in the range feature-1..HEAD and put them on top of master | 10:55 |
|
| Krafter: so --onto=X takes the same commits rebase would normally concider, but put them on top of X instead | 10:56 |
| ← yyy left | 10:56 |
| ← lankanmon left | 11:00 |
|
Krafter
| osse: Thanks! | 11:01 |
|
osse
| Krafter: in the last two commands i am assuming that feature-1 still points to the same commit as immediately before the merge --squash | 11:02 |
| ← tombusby left | 11:03 |
| → tombusby joined | 11:03 |
| ← cebor left | 11:04 |
| → cebor joined | 11:04 |
|
osse
| supernov1h: agreed. but I realize now I'm lost as to what you're doing. To answer your original answer, the question is no | 11:10 |
|
supernov1h
| I can't figure out why git apply would refuse the output of git diff | 11:10 |
|
| I can run git diff, output it to a file, reset --hard and then run git apply on the file and it refuses to apply it | 11:11 |
|
| why? | 11:11 |
|
osse
| you can try git apply --reject, then it behaves more like patch would, ie. apply what it can and generate reject files for the rest | 11:11 |
|
| hmm, have you configured diff to ignore whitespace/line endings or stuff like that by default ? | 11:11 |
|
supernov1h
| osse: whitespace yes | 11:12 |
|
| usually I run git diff -w | 11:12 |
|
osse
| that could be it then | 11:12 |
|
| git apply --ignore-whitespace maybe | 11:12 |
|
supernov1h
| I ran the output of both through sha256 and the hashes are the same | 11:12 |
|
| eh, for now its just a super laborious process of running it through diff -urN with the <(git show <hash>:./path/to), manually replacing the file path in the diff output and applying it on the other system | 11:14 |
|
osse
| how do you apply it on the other system? | 11:14 |
|
supernov1h
| patch <(cat -Rp1 the.patch) | 11:15 |
|
| p1 because I like leaving the ./ pathspec in there | 11:15 |
|
osse
| I would try using patch with the git diff output | 11:15 |
|
supernov1h
| sorry, patch -Rp1 <(the.patch) | 11:15 |
|
| sec | 11:16 |
| ← sQVe left | 11:17 |
|
supernov1h
| fails on some hunks | 11:18 |
|
| oh hey, so the output for -w IS different, how did I skip over that, the hashes were different... and it works with the output of git diff | 11:18 |
|
osse
| then git apply --ignore-whitespace probably works too with diff -w | 11:19 |
|
supernov1h
| so `git diff > 23-02-2019.patch`, on other system: `patch -p1 < ./22-02-2019.patch` | 11:19 |
| → pix9 joined | 11:20 |
|
osse
| yep, that's how it should be | 11:20 |
|
| or you could actually make a commit and apply that on the other side :P | 11:20 |
|
supernov1h
| yeah so there's a major merge conflict going on here, that's why I'm doing this on Saturday morning | 11:20 |
|
osse
| straya ? | 11:21 |
|
supernov1h
| nz kent | 11:21 |
|
osse
| makes sense | 11:22 |
|
| I'm just back from friday lunch :P | 11:22 |
|
supernov1h
| lol at lunch I watched a woman get sentenced, actually two women, they let one off four assault charges because she went to rehab and had apparently been given the wrong meds or some bollocks | 11:23 |
|
| said that played to her benefit, the fact that her family could afford to send her to a $25k rehab in Thailand | 11:23 |
| → mohabaks joined | 11:24 |
| → mowcat joined | 11:25 |
| → wildermind joined | 11:27 |
| ← jim left | 11:31 |
| → jim joined | 11:31 |
| → rakm joined | 11:32 |
| ← achadwick left | 11:33 |
|
supernov1h
| the judge said that rather, talk about privelege | 11:35 |
| ← rakm left | 11:41 |
| → tarkus joined | 11:44 |
| → adgtl joined | 11:46 |
| → lankanmon joined | 11:47 |
| → yyy joined | 11:47 |
| → wxg joined | 11:48 |
| ← keepLearning512 left | 11:48 |
| → mven_ joined | 11:50 |
| ← Achylles left | 11:51 |
| ← yyy left | 11:52 |
| → staafl_ joined | 11:53 |
| → yyy joined | 11:54 |
| ← mven_ left | 11:54 |
| ← hussam left | 11:55 |
| ← adgtl left | 11:56 |
| ← kjartan left | 11:59 |
| ← Krafter left | 11:59 |
| → miczac joined | 12:00 |
| ← YuGiOhJCJ left | 12:01 |
| ← greatgatsby left | 12:01 |
| ← mohabaks left | 12:01 |
| → kjartan joined | 12:01 |
| → keepLearning512 joined | 12:09 |
| ← keepLearning512 left | 12:09 |
| ← Noti left | 12:14 |
| ← tarkus left | 12:20 |
| ← wxg left | 12:20 |
| → Makaveli7 joined | 12:23 |
| → emsjessec joined | 12:23 |
| → lucasb joined | 12:25 |
| → Achylles joined | 12:26 |
| ← gxt left | 12:27 |
| ← staafl_ left | 12:28 |
| → gxt joined | 12:29 |
| ← Kaisyu left | 12:29 |
| → staafl_ joined | 12:30 |
| → rsrx joined | 12:31 |
| ← adder left | 12:34 |
| → CodeSlingerPaul joined | 12:35 |
| ← tjbp left | 12:36 |
| ← gxt left | 12:37 |
| → tjbp joined | 12:37 |
| ← rjsalts left | 12:38 |
| → rjsalts joined | 12:38 |
| → gxt joined | 12:38 |
| → CryptoDavid joined | 12:39 |
| → Essadon joined | 12:43 |
| ← Essadon left | 12:43 |
| → Essadon joined | 12:44 |
| → bulletmark joined | 12:44 |
| → wxg joined | 12:44 |
| → AtumT joined | 12:50 |
| ← wxg left | 12:52 |
| ← gxt left | 12:52 |
| → gxt joined | 12:53 |
| ← totte left | 12:54 |
| ← supernov1h left | 12:56 |
| ← bulletmark left | 13:00 |
| → totte joined | 13:02 |
| ← SpeakerToMeat left | 13:05 |
| ← tsdh left | 13:07 |
| ← Achylles left | 13:08 |
| ← skered left | 13:12 |
| → inkbottle joined | 13:17 |
| ← Trieste left | 13:19 |
| ← mowcat left | 13:21 |
| → Trieste joined | 13:21 |
| → sjoshi joined | 13:23 |
| ← n-st left | 13:25 |
| ← xcm left | 13:26 |
| ← miczac left | 13:26 |
| → xcm joined | 13:27 |
| ← xcm left | 13:28 |
| → xcm joined | 13:29 |
| ← Makaveli7 left | 13:32 |
| ← gxt left | 13:33 |
| → gxt joined | 13:34 |
| ← venmx left | 13:35 |
| → chaosruler joined | 13:37 |
| → venmx joined | 13:37 |
| ← chaosruler left | 13:38 |
| → Achylles joined | 13:41 |
| → sborza joined | 13:43 |
| → royal_screwup21 joined | 13:43 |
|
royal_screwup21
| Looking at a project where a contributor made 500 additions 90 deletions, in ONE commit. Short of actually making those changes in one commit, is there any other explanation how that could have happened? | 13:45 |
|
osse
| royal_screwup21: those numbers sound reasonable to me | 13:45 |
|
| maybe indentation was changed. that can blow up those numbers | 13:46 |
|
rts-sander
| maybe they squashed a bunch of smaller commits | 13:46 |
|
royal_screwup21
| ah I see | 13:47 |
|
| is squashing good practice though? I mean the tree is basically reset so you can't ever go back to an intermediary point you squashed | 13:48 |
| ← xcm left | 13:48 |
| → xcm joined | 13:48 |
|
osse
| royal_screwup21: depends on why you're squashing | 13:49 |
|
royal_screwup21
| looking at it again, it's 900* additions, not 500 | 13:49 |
|
osse
| those numbers aren't huge. maybe it makes complete sense | 13:49 |
|
rts-sander
| it depends on how you look at it, some prefer high granularity in their commits | 13:49 |
|
| in some teams even large features have to be squashed so that they can find the original ticket / reasons for introducing the change | 13:50 |
| ← sborza left | 13:56 |
| → cd joined | 13:56 |
| → sborza joined | 13:57 |
| → kjnilsson joined | 13:58 |
| ← kjnilsson left | 13:59 |
| ← totte left | 14:00 |
| → sQVe joined | 14:00 |
| → totte joined | 14:03 |
| ← Mattiaslndstrm left | 14:07 |
|
Seveas
| I've had commits with thousands of additions and deletions when vendoring dependencies for example | 14:08 |
|
| or just with thousands of deletions when cleaning up. Those are satisfying :D | 14:08 |
| → queip joined | 14:14 |
| → staafl__ joined | 14:15 |
| → awkwords joined | 14:15 |
|
cbreak
| I've seen commits that deleted 90% of the repository... | 14:17 |
|
Foxboron
| cbreak: Someone removed the accidental commit of node_modules? | 14:18 |
|
| Foxboron hides | 14:18 |
| → skered joined | 14:18 |
|
cbreak
| someone decided that the code was not salvageable and rewrote it | 14:19 |
| → jnewt_ joined | 14:19 |
| ← jnewt_ left | 14:19 |
| ← skered left | 14:20 |
| → mkarray joined | 14:22 |
| → Noti joined | 14:23 |
| → chaosruler joined | 14:24 |
| ← Inline left | 14:25 |
| → Inline joined | 14:25 |
| → awkwords_ joined | 14:27 |
| → fahadash joined | 14:28 |
| ← mkarray left | 14:28 |
| ← awkwords left | 14:29 |
| → n-st joined | 14:31 |
| ← GreenJello left | 14:31 |
| → GreenJello joined | 14:35 |
| ← staafl_ left | 14:35 |
| → mat001 joined | 14:36 |
| ← xcm left | 14:37 |
| → xcm joined | 14:37 |
| → mven_ joined | 14:39 |
| → howell joined | 14:42 |
| → tarkus joined | 14:43 |
| ← chaosruler left | 14:43 |
| → miczac joined | 14:47 |
| → chaosruler joined | 14:47 |
| → Envil joined | 14:48 |
| → orbyt_ joined | 14:50 |
| ← Envil left | 14:51 |
| → Envil joined | 14:52 |
| → rafalcpp joined | 14:53 |
| ← habbah left | 14:54 |
| ← miczac left | 14:56 |
| → Makaveli7 joined | 14:56 |
| → ym555 joined | 14:57 |
| → boombatower joined | 14:58 |
| ← govg left | 14:58 |
| → justanotheruser joined | 14:59 |
| → Mattiaslndstrm joined | 15:01 |
| → chachasmooth joined | 15:10 |
|
igemnace
| wow if he cut it down to 10% and still passed the tests, that's really something | 15:10 |
| ← de-facto left | 15:10 |
| ← chachasmooth_ left | 15:11 |
| → de-facto joined | 15:11 |
| ← hexnewbie left | 15:15 |
| → davidfetter joined | 15:17 |
| → keepLearning512 joined | 15:17 |
| ← mimajof left | 15:17 |
| → millerti joined | 15:18 |
| ← blackmesa left | 15:18 |
| → hexnewbie joined | 15:20 |
| ← yn left | 15:21 |
| → yn joined | 15:27 |
| → baako joined | 15:27 |
| ← Mattiaslndstrm left | 15:28 |
| ← orbyt_ left | 15:29 |
| → dudek joined | 15:29 |
| ← Noti left | 15:33 |
| → hussam joined | 15:36 |
| ← tarkus left | 15:36 |
| → maryo joined | 15:37 |
| ← v01d4lph4 left | 15:38 |
| dhollin3 → dhollinger | 15:38 |
| → skered joined | 15:40 |
| → AbleBacon joined | 15:40 |
| → leeN joined | 15:44 |
| → thiago joined | 15:45 |
| → sandromehic joined | 15:48 |
| ← oxymoron93 left | 15:51 |
| ← PioneerAxon left | 15:53 |
| ← raffo left | 15:53 |
| → PioneerAxon joined | 15:57 |
| ← Inline left | 15:57 |
| ← yuriii left | 15:57 |
| ← igemnace left | 15:59 |
| → Getafix74 joined | 15:59 |
| → wolfshappen_ joined | 16:01 |
| ← wolfshappen left | 16:01 |
| → Inline joined | 16:02 |
| ← pyfgcr left | 16:03 |
| ← jim left | 16:04 |
| → jim joined | 16:04 |
| ← jim left | 16:05 |
| ← lowbro left | 16:05 |
| ← lesshaste left | 16:06 |
| ← Achylles left | 16:07 |
| → fission6 joined | 16:07 |
| → jim joined | 16:08 |
| → treehug88 joined | 16:08 |
| → rafasc joined | 16:10 |
| → irc_viewer_test joined | 16:16 |
| ← chele left | 16:18 |
| ← PioneerAxon left | 16:18 |
| → PioneerAxon joined | 16:18 |
| ← thiago left | 16:19 |
| ← maryo left | 16:20 |
| ← sQVe left | 16:20 |
| ← fission6 left | 16:23 |
| → manuelschneid3r joined | 16:26 |
| → maryo joined | 16:32 |
| → _noblegas joined | 16:33 |
| ← maryo left | 16:36 |
| → maryo joined | 16:37 |
| → yyy- joined | 16:38 |
| ← yyy left | 16:41 |
| → skyikot joined | 16:42 |
| ← maryo left | 16:43 |
| ← sandromehic left | 16:43 |
| → mowcat joined | 16:43 |
| ← R2robot left | 16:44 |
| → Bradipo joined | 16:46 |
| → \void joined | 16:47 |
|
Bradipo
| Is there a possibility that git fetch --all will cause previously committed code to disappear? | 16:47 |
| → jamiejackson joined | 16:47 |
|
Bradipo
| e.g. if the sequence of commands is: git commit -a; git fetch --all | 16:47 |
| → cdown joined | 16:48 |
| → tafa2 joined | 16:48 |
|
rafasc
| Bradipo: no. | 16:49 |
|
Bradipo
| Ok, that's kind of what I thought. | 16:49 |
|
| Somehow some code that I moved in a file came back and I'm unsure how it happened. | 16:49 |
|
rafasc
| fetch only updates the remote tracking branches. And they're read-only. | 16:49 |
| → Arsenick joined | 16:49 |
|
Bradipo
| So the file ended up with the original code and the new code, and git blame shows both the commit where the code was inserted and the commit where it was moved. | 16:50 |
|
| Which seems like a paradox. | 16:51 |
| ← irc_viewer_test left | 16:51 |
| → tarkus joined | 16:52 |
| ← tarkus left | 16:52 |
| → tarkus joined | 16:52 |
| → fission6 joined | 16:53 |
|
rafasc
| how is that a paradox? | 16:53 |
| → maryo joined | 16:55 |
| → SpeakerToMeat joined | 16:58 |
| → opalepatrick joined | 16:59 |
| ← awkwords_ left | 17:01 |
|
Bradipo
| Because there is no commit that shows how they both got in there. | 17:03 |
|
| One commit says it was added, another commit shows the lines moved, and both sets of lines are in the current file. | 17:04 |
|
| How did both get there? | 17:04 |
|
rafasc
| Bradipo: probably a mismerge? | 17:04 |
|
Bradipo
| That's what I'm wondering, but shouldn't the mismerge be recorded? | 17:04 |
|
| Is it possible to track where the lines were reintroduced? | 17:04 |
|
rafasc
| in git everything is recorded. | 17:04 |
| ← mikecmpbll left | 17:04 |
|
rafasc
| you can search for commits that match a regex with git log -G 'pattern' | 17:05 |
|
Bradipo
| So commits that match the lines? | 17:05 |
|
rafasc
| or -S | 17:05 |
| ← floppydh left | 17:06 |
|
rafasc
| -S ignore moves and isn't regex. | 17:06 |
|
| Bradipo: is your repository publicly available? | 17:06 |
|
Bradipo
| No, it's internal. | 17:07 |
|
| And there are others who commit, so it's entirely possible someone did something strange. | 17:07 |
|
| But I'm trying to figure out how it happened so I can instruct on how to avoid it. :-) | 17:07 |
|
rafasc
| well, if someone did something strange it will be there recorded in the history. | 17:07 |
|
Bradipo
| That's what I thought, but so far I haven't been able to find that record. | 17:08 |
| ← keepLearning512 left | 17:08 |
| ← baako left | 17:09 |
|
rafasc
| Bradipo: It could be as simple as someone resolving conflicts wrong. | 17:09 |
|
Bradipo
| Sure, but then that should show up as a conflict resolution commit. | 17:09 |
|
| And I don't see such a thing, but maybe I just haven't looked hard enough. | 17:10 |
|
rafasc
| as in, they' took both sides of the conflict and finished the merge. | 17:10 |
|
Bradipo
| Right, that would make sense. | 17:10 |
| → client35 joined | 17:10 |
|
client35
| if I'm working on multiple branches, i.e. each branch is for different features that eventually get merged into a main repo and then that gets merged into a master repo, is it normal to do this? | 17:10 |
|
| I have a login.py script that is in branch "b" and api script in branch "c" | 17:10 |
| → kneeki joined | 17:12 |
|
rafasc
| Bradipo: not sure how else I can help you. blame, log -S/-G, and !lol. | 17:12 |
|
gitinfo
| Bradipo: A nifty view of branches, tags, and other refs: git log --oneline --graph --decorate --all | 17:12 |
|
rafasc
| That should be enough to find anything that happen. You just need to look in the right places. Having a neat history helps. Which may not be the case. | 17:13 |
| → Achylles joined | 17:14 |
|
rafasc
| client35: That's sounds completely fine. | 17:15 |
| ← fission6 left | 17:15 |
|
rafasc
| not sure if the separating in repos is necessary though. | 17:15 |
|
| you could have something like two branches instead of those two repos. | 17:16 |
|
| feature branch merges into dev branch, dev branch merges into master. | 17:17 |
| ← CryptoDavid left | 17:17 |
| → Regon joined | 17:17 |
|
rafasc
| You can even setup your host to prevent pushing to these two 'protected branches' directly. | 17:17 |
| ← wpkeg left | 17:18 |
| ← ym555 left | 17:20 |
|
client35
| two branches, rather, sorry rafasc | 17:21 |
|
Bradipo
| rafasc: Thanks, I'll keep looking. | 17:21 |
|
rafasc
| client35: then it sounds completely fine. Very similar to !flow | 17:22 |
|
gitinfo
| client35: [!gitflow] The description of the gitflow branch workflow model is at http://nvie.com/posts/a-successful-git-branching-model/ while a tool to help implement this workflow is at https://github.com/petervanderdoes/gitflow See http://sethrobertson.github.com/GitBestPractices/#workflow for other workflow suggestions/references | 17:22 |
|
client35
| master branch hasn't been merged/pushed to yet as my friend and I are only working on separate main branches | 17:22 |
| → adgtl joined | 17:22 |
|
client35
| ah okay | 17:22 |
| → DannyButterman joined | 17:22 |
|
DannyButterman
| Hi there | 17:23 |
|
gitinfo
| DannyButterman: hi! I'd like to automatically welcome you to #git, a place full of helpful gits. Got a question? Just ask it — chances are someone will answer fairly soon. The topic has links with more information about git and this channel. NB. it can't hurt to do a backup (type !backup for help) before trying things out, especially if they involve dangerous keywords such as --hard, clean, --force/-f, rm and so on. | 17:23 |
| ← maryo left | 17:25 |
|
DannyButterman
| I'm new to git, and I want to update the remote repos with my last updates. git pull, then commit then push throw me errors I don't understand : | 17:25 |
|
| "error: Your local changes to 'some file' would be overwritten by merge. Aborting. Please, commit your changes or stash them before you can merge. | 17:26 |
|
| So I do git commit -m some message | 17:26 |
| → v01d4lph4 joined | 17:27 |
|
DannyButterman
| and a list of modified files is displayed( that I didn't modify actually ???) . It ends with : | 17:28 |
|
| # Untracked files: | 17:28 |
|
| # (use "git add <file>..." to include in what will be committed) | 17:28 |
|
| # | 17:28 |
|
| # .buildpath | 17:28 |
|
| # .settings/ | 17:28 |
|
| no changes added to commit (use "git add" and/or "git commit -a") | 17:28 |
|
rts-sander
| DannyButterman, someone else upstream made a change and it's conflicting with your change | 17:30 |
|
rafasc
| DannyButterman: that means the merge is trying to overwrite a file you have uncommitted modifications. | 17:30 |
|
rts-sander
| DannyButterman, try git pull --rebase and fix your commits | 17:30 |
|
| DannyButterman, of course after you abort the current failed merge with git merge --abort | 17:30 |
|
DannyButterman
| git pull --rebase did the trick !! thanks :) | 17:31 |
| → orbyt_ joined | 17:31 |
| ← craftyguy left | 17:32 |
| ← rts-sander left | 17:32 |
| → craftyguy joined | 17:32 |
|
rafasc
| be sure you understand the dangers of --rebase !rewrite | 17:32 |
|
gitinfo
| Rewriting public history is not recommended. Everyone who has pulled the old history will have to do work (and you'll have to tell them to), so it's infinitely better to just move on. If you must, you can use `git push --force-with-lease <remote> <branch>` to force (and the remote may reject that, anyway). See http://goo.gl/waqum | 17:32 |
| ← crater2150 left | 17:34 |
| → misuto joined | 17:35 |
|
DannyButterman
| Sure I don't have much clue about what it all means. It seems like answers to complicated issues that I don't have. Just locking file that I work on would be enough for me :s | 17:35 |
| → adder joined | 17:36 |
| → m0viefreak joined | 17:36 |
| ← craftyguy left | 17:36 |
| → crater2150 joined | 17:37 |
| → craftyguy joined | 17:38 |
| → causa_sui joined | 17:38 |
| → nowhere_man joined | 17:41 |
| → steppentyu joined | 17:41 |
| ← Makaveli7 left | 17:45 |
| → Makaveli7 joined | 17:45 |
| → fission6 joined | 17:46 |
| → keepLearning512 joined | 17:47 |
| ← crater2150 left | 17:49 |
|
cmosguy
| hello git experts, my team and I are using `git flow` for our features, so we do a `git flow feature start ABS-01_some_branch` | 17:50 |
|
| the issue we are having is when we finish a feature, we lose the ability to track the branch `ABS-01_some_branch` feature name | 17:50 |
|
| is there a tip or way to get some tagging involved for this automatically? | 17:50 |
| → Sleepy63 joined | 17:51 |
| → blipz joined | 17:52 |
| ← tjbp left | 17:53 |
|
DannyButterman
| Bye guys thanks | 17:55 |
| ← DannyButterman left | 17:55 |
|
rafasc
| DannyButterman: git was designed precisely to avoid the need of those 'locks'. You work on files without worrying about locks then resolve the conflicts when they arive... | 17:55 |
| → tjbp joined | 17:55 |
|
rafasc
| cmosguy: what do you mean by lose the ability to track? | 17:56 |
| ← mowcat left | 17:57 |
|
rafasc
| does 'git flow' delete the branch when you decide to merge? (finish?) | 17:57 |
|
cmosguy
| @rafasc basically when i loot at all my commits and messages, I have no way to really see the original branch name that was used to facilitate a specific Jira ticket | 17:57 |
|
| for example I have a jira ticket called `ABS-01`, when i create a feature I call it `ABS-01-some-feature` | 17:58 |
|
| i want to see all my history and find this old infor | 17:59 |
|
_ikke_
| The convention is that the merge commit message describes what branch was merged in | 17:59 |
|
| cmosguy: I would not use refnames as permanent records of history | 18:00 |
| → mikecmpbll joined | 18:00 |
| ← gxt left | 18:00 |
|
rafasc
| it is encouraged by the default merge message, but not compulsory. | 18:01 |
|
_ikke_
| right, hence convention | 18:01 |
| → gxt joined | 18:01 |
|
rafasc
| some people use trailers in the merge commit message with additional information. | 18:01 |
|
_ikke_
| But the merge commit message is the place to record these kinds of things | 18:01 |
|
rafasc
| ticket-id: blablabla | 18:02 |
| ← totte left | 18:07 |
|
grawity
| I'd make a commit hook that automatically adds a jira URL into the commit message | 18:09 |
| → totte joined | 18:10 |
| → chaosruler_ joined | 18:18 |
| ← venmx left | 18:19 |
| ← chaosruler left | 18:19 |
| ← theoceaniscool left | 18:22 |
| ← causasui left | 18:23 |
| → fstd_ joined | 18:23 |
| → awkwords joined | 18:23 |
| ← hofmann3900 left | 18:24 |
| → estodiMania joined | 18:27 |
| ← fstd left | 18:27 |
| fstd_ → fstd | 18:27 |
| ← orbyt_ left | 18:27 |
| ← client35 left | 18:31 |
| ← jungsubk left | 18:32 |
|
cmosguy
| @grawity that sounds like an interesting idea | 18:32 |
|
| thanks @_ikke_ and @rafasc I'll take these ideas into consideration | 18:32 |
| → Darcidride joined | 18:33 |
| → R2robot joined | 18:34 |
| → v0lksman joined | 18:34 |
|
v0lksman
| hey all! hopefully someone is willing to discuss this with me but basically I'm trying to figure out the best work flow when dealing with a dev branch. Let's say I have a master that is our production stable code. I then create a dev branch that will get a bunch of new features. I make security fixes to master on a regular basis and want those included in the dev branch so we can test to ensure dev is | 18:36 |
|
| stable before bringing it back inline to master. | 18:36 |
|
| I know of using rebase from the dev branch as "git rebase master" and there is also "git merge master". Can't wrap my head around why I would use one over the other | 18:37 |
| → mjsir911 joined | 18:37 |
|
v0lksman
| like is it safe to continually rebase master after every change to make it part of dev? or am I better off merging the two? | 18:39 |
| → freeman42x joined | 18:40 |
|
rafasc
| v0lksman: merge and rebase are two ways to bring together histories that diverged. Both have pros and cons. | 18:40 |
| ← fission6 left | 18:41 |
|
rafasc
| merge will create a commit that points merges multiple endpoints (branches) together. | 18:41 |
| → ym555 joined | 18:42 |
|
rafasc
| rebase will take the commits from a branch, and recreate them on top of another branch. | 18:43 |
| → SkarmoutsosV joined | 18:43 |
| ← fahadash left | 18:44 |
|
v0lksman
| ok so lets say I make changes to master and want them on dev, so I rebase, and continue to add to dev, then I make another change to master, do I rebase again? It seems that rebase goes back to the first divergence always not what has already been rolled into dev. Is that correct? | 18:44 |
|
_ikke_
| v0lksman: yes, you need to rebase again | 18:45 |
|
rafasc
| ^ and that's one of the "problems" of rebase. | 18:45 |
| ← rsrx left | 18:45 |
|
_ikke_
| Not so sure if it's a problem | 18:45 |
|
v0lksman
| yeah cause that's a lot of work each time I want to apply changes made to master | 18:46 |
|
| well it can be a lot of work | 18:46 |
|
| in my current situation it's a lot of work | 18:46 |
|
| :) | 18:46 |
|
rafasc
| if you have feature branches that branch of dev, you'll have to rebase them too. | 18:46 |
|
v0lksman
| yeah let's not confuse things just yet | 18:46 |
|
| again just trying to figure out best work flow to ensure that security changes to master are added to dev so we can test the full solution before promoting the code back to master for production use | 18:47 |
|
| sounds like I should be merging though | 18:49 |
| ← SkarmoutsosV left | 18:52 |
| → orbyt_ joined | 18:52 |
| → SkarmoutsosV joined | 18:52 |
|
rafasc
| v0lksman: with all due respect, I don't think you understood the difference between rebase and merge yet. | 18:55 |
| → Sasazuka joined | 18:55 |
| ← ghormoon left | 18:55 |
|
rafasc
| both will equally allow you to include the security fixes in your branches. | 18:55 |
|
| how that history is recorded is what changes. | 18:55 |
| → ghormoon joined | 18:58 |
| ← in1t3r left | 19:01 |
| → in1t3r joined | 19:01 |
| → fission6 joined | 19:04 |
| → atrigent joined | 19:04 |
|
v0lksman
| rafasc: yes but it seems that if I use rebase I have to reapply changes if I need to rebase multiple times. Where if I merge, once I do that those changes won't be retried on the next merge, only new changes (commits) will | 19:06 |
| ← v01d4lph4 left | 19:07 |
| ← Darcidride left | 19:07 |
| ← royal_screwup21 left | 19:07 |
| → blackmesa joined | 19:07 |
| → maunix_ joined | 19:08 |
| ← Inline left | 19:08 |
| → Inline joined | 19:08 |
| → royal_screwup21 joined | 19:09 |
| ← royal_screwup21 left | 19:11 |
|
Bradipo
| v0lksman: You can certainly merge. With git, a lot of attention is placed on making the history look nice, and --rebase helps you do that. If you don't care about that, I'm not sure there is a compelling reason to use rebase vs merge. | 19:13 |
| ← yyy- left | 19:15 |
| → yyy- joined | 19:15 |
| → awkwords_ joined | 19:18 |
| ← cdown left | 19:19 |
| ← awkwords left | 19:20 |
| → assemblyman joined | 19:22 |
| grumble → `-_-`grumble | 19:22 |
| → Dirak joined | 19:23 |
| ← jwest left | 19:23 |
| ← sauvin left | 19:24 |
| ← yyy- left | 19:24 |
| ← AbleBacon left | 19:25 |
| ← oprypin left | 19:26 |
| ← gxt left | 19:26 |
| `-_-`grumble → grumble | 19:36 |
| → xrexeon joined | 19:36 |
| ← xrexeon left | 19:37 |
| → xrexeon joined | 19:37 |
| ← mjsir911 left | 19:46 |
| ← skered left | 19:46 |
| ← atrigent left | 19:49 |
| → stitched_unicorn joined | 19:50 |
| → skered joined | 19:51 |
| ← stitched_unicorn left | 19:52 |
|
Bradipo
| rafasc: I found the problem; there was a merge conflict. | 19:52 |
|
| I guess git log -S doesn't search through merge conflicts? | 19:52 |
| → stitched_unicorn joined | 19:53 |
|
rafasc
| I think it does. But -S doesn't consider 'moved lines' | 19:53 |
|
| you need -G for that. | 19:53 |
|
Bradipo
| Ahh. | 19:53 |
|
| And conflict resolution creates moved lines? | 19:53 |
| → atrigent joined | 19:54 |
|
rafasc
| if you move lines as part of your resolution I guess... | 19:54 |
|
Bradipo
| Right, because it shows the lines I moved with a normal commit. | 19:54 |
|
| I'll try log -G now to see if it finds it. | 19:55 |
|
rafasc
| Bradipo: also, forgot to mention. If you know a before and after state, you can use git bisect to find the commit where it changed. | 19:55 |
| ← tarkus left | 20:02 |
| ← Dirak left | 20:05 |
| ← stitched_unicorn left | 20:08 |
| → wildlander joined | 20:22 |
| → Dirak joined | 20:23 |
| ← xcm left | 20:32 |
| → xcm joined | 20:32 |
| ← rkta left | 20:35 |
| → rkta joined | 20:35 |
| → oprypin joined | 20:36 |
| → cdown joined | 20:37 |
| → yourfate joined | 20:39 |
| → n3wborn joined | 20:44 |
| → gxt joined | 20:45 |
| ← manuelschneid3r left | 20:46 |
| ← maunix_ left | 20:46 |
| ← fatalhalt left | 20:47 |
| ← orbyt_ left | 20:48 |
|
Bradipo
| rafasc: Of course, git bisect... that's pretty obvious, not sure why I didn't think to try that. | 20:50 |
| → fatalhalt joined | 20:50 |
| → jwest joined | 20:51 |
|
rafasc
| even better if you can automate the property being tested. | 20:51 |
|
| :) | 20:51 |
| ← emsjessec left | 20:56 |
| → wootehfoot joined | 20:56 |
| → awkwords joined | 20:59 |
| → Lunatrius` joined | 21:00 |
| ← Lunatrius left | 21:00 |
| Lunatrius` → Lunatrius | 21:00 |
| → in1t3r_ joined | 21:01 |
| ← in1t3r left | 21:02 |
|
Bradipo
| Yeah, grep can easily automate the property being tested. :-) | 21:02 |
| ← adder left | 21:02 |
| ← awkwords_ left | 21:02 |
| ← kneeki left | 21:02 |
| → roygbiv joined | 21:05 |
| → awkwords_ joined | 21:06 |
| ← skered left | 21:07 |
| ← assemblyman left | 21:09 |
| ← awkwords left | 21:09 |
| davidfetter → guys | 21:09 |
| guys → davidfetter | 21:09 |
| ← fission6 left | 21:10 |
| ← SkarmoutsosV left | 21:11 |
| → SkarmoutsosV joined | 21:13 |
| → skered joined | 21:14 |
| ← estodiMania left | 21:17 |
| → estodiMania joined | 21:18 |
| ← estodiMania left | 21:18 |
| → estodiMania joined | 21:18 |
| ← n3wborn left | 21:19 |
| ← estodiMania left | 21:19 |
| ← Dirak left | 21:20 |
| → theoceaniscool joined | 21:20 |
| → n3wborn joined | 21:21 |
| ← UrsoBranco left | 21:22 |
| → Dirak joined | 21:24 |
| ← n3wborn left | 21:25 |
| ← in1t3r_ left | 21:26 |
| → in1t3r_ joined | 21:26 |
| → n3wborn joined | 21:27 |
| ← SkarmoutsosV left | 21:27 |
| ← mven_ left | 21:29 |
| → ozcanesen joined | 21:32 |
| → Fernando-Basso joined | 21:32 |
| ← n3wborn left | 21:33 |
| → n3wborn joined | 21:34 |
| → awkwords joined | 21:38 |
| ← roygbiv left | 21:38 |
| ← awkwords_ left | 21:39 |
| ← hays left | 21:42 |
| ← GinoMan2440 left | 21:43 |
| ← awkwords left | 21:43 |
| ← xcm left | 21:43 |
| → xcm joined | 21:43 |
| → hays joined | 21:45 |
| → awkwords joined | 21:45 |
| ← blipz left | 21:47 |
| ← ozcanesen left | 21:51 |
| ← cdown left | 21:52 |
| → raymond joined | 21:53 |
| → irqq joined | 21:54 |
| → blipz joined | 21:54 |
| → dviola joined | 21:55 |
| ← davidfetter left | 21:58 |
| ← wolfshappen_ left | 22:00 |
| ← Makaveli7 left | 22:01 |
| ← keepLearning512 left | 22:01 |
| → Makaveli7 joined | 22:01 |
| → wolfshappen joined | 22:01 |
| → exitcode1 joined | 22:09 |
| → mjsir911 joined | 22:10 |
| ← cliluw left | 22:12 |
| → awkwords_ joined | 22:13 |
| → cliluw joined | 22:14 |
| ← wildermind left | 22:16 |
| ← awkwords left | 22:17 |
| ← awkwords_ left | 22:17 |
| ← camsbury_ left | 22:18 |
| → awkwords joined | 22:18 |
| ← awkwords left | 22:18 |
| → camsbury joined | 22:18 |
| ← exitcode1 left | 22:18 |
| → estodiMania joined | 22:20 |
| ← camsbury left | 22:23 |
| ← xcm left | 22:27 |
| → xcm joined | 22:28 |
| ← SuperLag left | 22:28 |
| → Spacew00t joined | 22:29 |
| ← howell left | 22:32 |
| ← BlessJah left | 22:35 |
| → Karyon joined | 22:41 |
| → BlessJah joined | 22:47 |
| → camsbury joined | 22:49 |
| ← BlessJah left | 22:51 |
| ← lucasb left | 22:54 |
| → freeman42y joined | 22:55 |
| ← estodiMania left | 22:55 |
| ← _noblegas left | 22:56 |
| → irc_viewer_test joined | 22:58 |
| ← freeman42x left | 22:58 |
| ← camsbury left | 23:00 |
| → Mattiaslndstrm joined | 23:00 |
| → camsbury joined | 23:00 |
| ← Lunatrius left | 23:02 |
| ← Mattiaslndstrm left | 23:02 |
| ← hahuang65 left | 23:04 |
| → hahuang6- joined | 23:04 |
| ← camsbury left | 23:07 |
| → BlessJah joined | 23:07 |
| ← mar77i left | 23:10 |
| ← CodeSlingerPaul left | 23:11 |
| ← Makaveli7 left | 23:13 |
| → Makaveli7 joined | 23:13 |
| → daurnimator joined | 23:16 |
| → kerframil joined | 23:16 |
| ← irc_viewer_test left | 23:22 |
| ← Fernando-Basso left | 23:24 |
| → puff joined | 23:25 |
| → bulletmark joined | 23:25 |
| ← bulletmark left | 23:26 |
| ← jamiejackson left | 23:26 |
| ← Trieste left | 23:27 |
| → m1m0 joined | 23:28 |
| ← Achylles left | 23:28 |
| ← mooasaurus left | 23:29 |
| → mooasaurus joined | 23:29 |
| ← Nokurn_ left | 23:29 |
| ← steppentyu left | 23:30 |
| ← dudek left | 23:30 |
| → Trieste joined | 23:30 |
| ← blackmesa left | 23:30 |
| → igemnace joined | 23:31 |
| ← n3wborn left | 23:33 |
| → Nokurn joined | 23:35 |
| → hahuang65 joined | 23:40 |
| ← troyt left | 23:41 |
| → troyt joined | 23:41 |
| → greatgatsby joined | 23:42 |
| ← greatgatsby left | 23:42 |
| → greatgatsby joined | 23:43 |
| → thiago joined | 23:44 |
| → Revan- joined | 23:50 |
| ← Revan- left | 23:53 |
| ← millerti left | 23:54 |
| ← plexigras left | 23:56 |
| ← duderonomy left | 23:56 |
| → weems joined | 23:58 |