Perl 6 - the future is here, just unevenly distributed

IRC log for #git, 2016-12-20

| Channels | #git index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:01 Sasazuka_ joined #git
00:05 FSadino joined #git
00:10 svm_invictvs joined #git
00:13 nettoweb joined #git
00:17 PresidentElect Vampire0: The argument is that "source control is just source control" sigh.
00:17 jaguarmagenta joined #git
00:18 morenoh149 joined #git
00:20 tmsmith joined #git
00:22 Vampire0 PresidentElect, then tell them they are total fools and live with it, or prove them to be wrong. There are even special tutorials on how to convince the boss or how to convince the co-worker.
00:25 linuxmodder joined #git
00:27 diogenese joined #git
00:27 FSadino joined #git
00:30 romerocesar joined #git
00:31 paintenzero joined #git
00:31 painten0 joined #git
00:32 paintenzero joined #git
00:33 jw4242 joined #git
00:33 corn13read joined #git
00:33 [0xAA] joined #git
00:34 llamapixel png to hex to git and then back to png seems to avoid me having to use a binary file ;P
00:38 dsantiago joined #git
00:39 webdev007 joined #git
00:41 overlord_tm joined #git
00:43 HM joined #git
00:43 Mannn joined #git
00:44 linuxmodder joined #git
00:44 _ADN_ joined #git
00:47 _ADN_ joined #git
00:52 SpEcHiDeR joined #git
00:56 llamapixel Perfect works a charm. :P https://usercontent.irccloud-cdn.com/file/TRnZKOgO/Screenshot%202016-12-20%2011.53.49.png
00:56 llamapixel Binary files stored as hex in git without binary file duplication :P
00:58 madewokherd joined #git
01:01 alipoor90 tree objects are directories?
01:02 HM2 joined #git
01:06 los joined #git
01:08 d0nn1e joined #git
01:10 Skch joined #git
01:11 mellernoia-away joined #git
01:11 Vampire0 alipoor90, what?
01:11 dsantiago joined #git
01:12 alipoor90 tree objects, in git glossary, do a tree object is how git stores directory information?
01:14 robattila256 joined #git
01:16 JamesBaxter joined #git
01:16 tmsmith joined #git
01:17 arescorpio joined #git
01:17 rominronin joined #git
01:17 diogenese joined #git
01:17 Vampire0 what exactly do you mean with "directory information"? Do you mean in which directory a file is stored, or something else?
01:20 mischat joined #git
01:20 cqi joined #git
01:21 Vampire0 alipoor90, if yes, then yes. a tree object basically represents a directory.
01:21 Vampire0 alipoor90, also see here: https://git-scm.com/book/en/v2/Git-Internals-Git-Objects
01:21 alipoor90 Thanks
01:22 Sasazuka joined #git
01:27 alipoor90 Vampire0: I want to start learning git, which one is better as start point? gittutorial, git User's manual or Pro git book?
01:28 Sasazuka_ joined #git
01:28 alipoor90 currently I know just very basic add commit functionality ...
01:28 llamapixel alipoor90: make a repo called MyTestingRepo with github or gitlab and make all the mistakes in there.
01:28 llamapixel YOu can revisit this repo as you do tutorials and commit message to the readme that are the instructions you practices.
01:29 llamapixel practiced*
01:29 diogenese joined #git
01:29 alipoor90 good idea
01:29 llamapixel I have one still to this day, sometimes a freelance job has strange layouts.
01:30 kadoban alipoor90: Start there, use git as often as you can. I'd learn the very basics first, however you want. I did pro git I think, but ... just anything. Once you have the basics it's pretty hard to actually lose work. Use git, when you don't know how to do something or you get in weird states, ask in here how to recover.
01:30 llamapixel Did you know at the moment that packtpub has $5 books at the moment if you prefer a nice document alipoor90 ?
01:31 llamapixel https://www.packtpub.com/all?search=git
01:31 llamapixel I just bought 10 raspberry pi books
01:32 tsteinholz joined #git
01:32 FSadino joined #git
01:33 Vampire0 llamapixel, alipoor90 why on GitHub or GitLab? Don't show your faults to public, just make a local repo with `git init`. And if you want to try pushing, pulling, just make a second bare one that you use as remote. Works without problems ;-)
01:33 llamapixel gitlab has private free
01:33 cheezwhiz joined #git
01:34 Vampire0 still, no need to use some server while you can also learn how when and why to create a bare repository ;-)
01:34 llamapixel If you work in a freelance environment experience with those systems also adds to your productivity
01:34 a_thakur joined #git
01:34 llamapixel Learn github, lab and bitbucket for the big ones I come across in projects.
01:35 llamapixel It is rare that a company I work in has their own setups for both sides.
01:35 Vampire0 Learn Git, *then* learn the additions like GitHub, GitLab and BitBucket
01:35 Peng_ joined #git
01:35 llamapixel throw the distributed (n) location in with the learning ;)
01:36 QuestionTime joined #git
01:36 Vampire0 two local repositories one as remote and one as working clone is also distributed ;-)
01:37 Vampire0 that's the point with Git, you don't have to have any server. And two repositories can talk with each other.
01:37 inflames joined #git
01:37 Vampire0 Or the point with all DVCS actually of course
01:37 llamapixel He is being sensible alipoor90  but if you have these web repos, you can practice pulling from them later.
01:38 qqx joined #git
01:38 trelane joined #git
01:38 trelane joined #git
01:38 Vampire0 llamapixel, what is the difference between pulling from a remote that lies on your disk somewhere and pulling from a remote that is hosted on GitHub? It is absolutely the same.
01:39 llamapixel It helps for people who are new to this concept understand that some repos can be on other servers that is all.
01:39 Vampire0 Except that you don't have to learn GitHub first, but you just call `git init --bare`  before you do the `git clone`
01:39 llamapixel Don’t mansplain it and lose face ;)
01:40 svm_invictvs joined #git
01:40 Vampire0 What does mansplain mean?
01:40 Vampire0 And why should I lose my face? I told just correct facts and stand to them. You are just grabbing for straws to rectify your suggestion o_O
01:41 llamapixel lost face mate ;)
01:41 chromity joined #git
01:41 llamapixel Starting either way is ok
01:41 Vampire0 While he should probably get experience with both variants, it is better to learn one new thing first and then the second and not learn too many new things at once.
01:42 Vampire0 You lost your face? I'm sorry for you then, though I don't know why.
01:42 Vampire0 But then, I don't really care acutally. ;-)
01:43 llamapixel Now your thnking correctly again ;)
01:43 llamapixel Don’t worry too much about difference of opinion on the internet. You have a valid argument as well son ;)
01:44 Monokai12357 joined #git
01:45 Vampire0 How old are you?
01:45 llamapixel 45+ tickbox
01:46 Monokai12357 left #git
01:46 Vampire0 Wow, you were really early mature
01:46 llamapixel Is this where I lose focus and reply ;)?
01:47 Vampire0 If you would reply I would actually doubt you are 45+ :-D
01:47 Vampire0 Especially as I didn't ask a question. :-P
01:48 llamapixel take care mate ;) you seem to be a little upset now.
01:48 meZee joined #git
01:49 Vampire0 And you seem to have lost your empathy, I'm amused, not upset
01:49 llamapixel alipoor90:  good luck with your learning, try to ignore this moment in time. ;)
01:50 alipoor90 Thanks
01:50 venmx joined #git
01:51 llamapixel alipoor90:  the touch command is a nice tool for making a quick change to a file but if you prefer use vi /vim /emacs nano etc with a real change of data like names in a list to understand the process easier.
01:52 Vampire0 or simply echo like         echo B >>names.txt            to add B as new line to the end of the file
01:53 llamapixel alipoor90: There is also quite a few online helpers but after tinkering with them do the real thing on your testing project because you will “own” the procedure more to memory. http://learngitbranching.js.org/
01:53 alipoor90 llamapixel: git cares about mtime? even if files have same content?
01:53 llamapixel try it out mate ;)
01:53 llamapixel answer your own questions with that repo and earn the experience ;)
01:54 uranellus joined #git
01:54 uranellus joined #git
01:54 Vampire0 No alipoor90, it does not. But you can touch a new file that does not exist and add that
01:54 dreiss joined #git
01:54 alipoor90 got it
01:55 cheezwhiz left #git
01:56 Nilesh_ joined #git
01:58 mizu_no_oto joined #git
01:59 mischat joined #git
01:59 est31 joined #git
02:00 est31 left #git
02:02 MaggieC joined #git
02:03 MaggieC joined #git
02:06 Gsham joined #git
02:06 morenoh149 joined #git
02:07 swalladge joined #git
02:09 mischat joined #git
02:09 Sleepy63 joined #git
02:09 howitdo joined #git
02:10 romerocesar_ joined #git
02:10 Sasazuka joined #git
02:12 macivy joined #git
02:15 Xarodon joined #git
02:16 talkJS joined #git
02:16 jargan joined #git
02:16 finalbeta joined #git
02:16 Sasazuka joined #git
02:16 talkJS i have a file, that when changed, does not show me any changes  when running git status.    The file .gitignore file had the path listed, but i removed it.   Still not showing me any changes.
02:17 bdonnahue joined #git
02:18 macivy left #git
02:18 jaguarmagenta joined #git
02:19 dh128 joined #git
02:19 phanimahesh joined #git
02:22 FSadino joined #git
02:22 Vampire0 talkJS, execute `git ls-files -v | grep '^h'` and see if the file in question is listed
02:23 talkJS yes it is
02:24 FSadino git add -A
02:24 Vampire0 Then you used `git update-index --assume-unchanged <file>` on it, with is a dangerous option, especially if you forget that you used it. Do `git update-index --no-assume-unchanged <file>` and you are fine to go on
02:24 Vampire0 FSadino, what would that help if the file is assume-unchanged?
02:24 aartist joined #git
02:24 dar123 joined #git
02:24 Vampire0 s/with/which/
02:24 dh128 left #git
02:25 star_prone joined #git
02:25 FSadino It help me when I had the same problem
02:28 Vampire0 FSadino, you didn't have the same problem, otherwise `git add -A` would not have helped, I just tested it to make sure.
02:28 Vampire0 talkJS, you have seen that I gave you the solution you need?
02:30 Lyqyd joined #git
02:31 talkJS that worked!
02:31 talkJS thank you
02:32 Vampire0_ joined #git
02:33 ResidentBiscuit joined #git
02:35 Guest55 joined #git
02:36 arunpyasi joined #git
02:36 d^sh joined #git
02:36 SwingShock joined #git
02:39 pks joined #git
02:39 SwingShock hi. how to reset git to be exactly to the remote repository with the same branches ? to create the same effect of cloning again like deleting branches and files that are not existing in the remote to make it same as it ?
02:41 romerocesar joined #git
02:46 Limes joined #git
02:46 sshine left #git
02:46 ghostlight joined #git
02:46 Vampire0 SwingShock, well, just delete your local branches? And maybe additionally a `git clean -fdx`, but be aware that this deletes all untracked files, including ignored ones and those are not possible to be brought back, it is one of the few irreversible Git commands.
02:46 ResidentBiscuit joined #git
02:49 ilbot3 joined #git
02:49 Topic for #git is now Welcome to #git, the place for git help and serious business | Public logs at http://jk.gs/glog | First visit? Read: http://jk.gs/git | Current stable version: 2.11.0 | Getting "cannot send to channel"? /msg gitinfo .voice | The git-jokes project has been suspended for lack of contribution. Help revive it! https://madeitwor.se/git-jokes
02:50 Vampire0 SwingShock, if you want to make sure that it is like a fresh clone, you can also simply clone the remote again, but use the old clone as reference repository. That means it takes the object files from there. And with an additional option the objects are copied from the old clone to the new clone and not only referenced. This way you can make a fresh clone from remote without downloading unnecessarily and t
02:50 Vampire0 hen delete your old clone if you want.
02:50 Vampire0 SwingShock, see man git clone for more info
02:50 gitinfo SwingShock: the git-clone manpage is available at http://jk.gs/git-clone.html
02:51 Spinkzeit joined #git
02:51 aavrug joined #git
02:52 Vampire0 SwingShock, you are looking for --reference and --dissociate
02:54 SwingShock thanks. but git clean -fdx did not clear the branches. when i use git branch -avv i can still see the branches.
02:58 SwingShock I tried git reset --hard too. but branches are still visible in the list.
02:59 SwingShock Should only clone again using those commands once branches are deleted ?
02:59 bruce_lee joined #git
03:00 ixjlyons joined #git
03:00 artgoeshere joined #git
03:01 pks joined #git
03:04 netj joined #git
03:07 SwingShock i think i will delete all the files in local repository including the .git folder and just clone again for now.
03:09 kisonecat joined #git
03:09 tanuki joined #git
03:10 mischat joined #git
03:11 FilipNortic_ joined #git
03:13 romerocesar joined #git
03:14 tmsmith joined #git
03:15 FilipNortic joined #git
03:17 chachasmooth joined #git
03:19 plos joined #git
03:19 est31 joined #git
03:19 est31 so there is this github page to check out PRs locally
03:19 est31 https://help.github.com/articles/checking-out-pull-requests-locally/
03:20 est31 I did the "git fetch origin pull/ID/head:BRANCHNAME" as advised and it worked great
03:20 est31 now my question is: how can I update?
03:20 est31 git remote update doesn't really catch the PR update
03:21 est31 and yes, I could do git checkout master; git branch -D BRANCHNAME; and re-do the git fetch
03:21 est31 but that will bump all files, and the build system will rebuild everything
03:22 griffindy joined #git
03:24 [Saint] joined #git
03:25 plos joined #git
03:26 SpeakerToMeat joined #git
03:27 diogenese joined #git
03:29 mizu_no_oto joined #git
03:30 Goplat joined #git
03:31 adymitruk joined #git
03:31 chromity joined #git
03:31 Neelixx joined #git
03:31 Noodlewitt joined #git
03:38 Neelixx joined #git
03:39 the_cybersphinx joined #git
03:45 xall joined #git
03:48 thesha joined #git
03:49 dreiss joined #git
03:50 hexagoxel joined #git
03:50 Gsham joined #git
03:51 romerocesar joined #git
03:52 SpeakerToMeat joined #git
03:55 hahuang65 joined #git
03:55 arunpyasi joined #git
03:55 morenoh149 joined #git
03:56 safe joined #git
04:00 sunri5e joined #git
04:02 fstd_ joined #git
04:04 bdonnahue joined #git
04:04 a_thakur joined #git
04:09 pks joined #git
04:11 mischat joined #git
04:14 star_prone joined #git
04:15 Vortex34 joined #git
04:19 jaguarmagenta joined #git
04:20 davimore joined #git
04:20 rominronin joined #git
04:22 PaulCapestany joined #git
04:23 FSadino joined #git
04:25 bdonnahue joined #git
04:29 robotroll joined #git
04:30 Gsham joined #git
04:31 romerocesar joined #git
04:31 duderino joined #git
04:33 function joined #git
04:33 mischat joined #git
04:38 FSadino joined #git
04:41 aruns joined #git
04:45 thesha joined #git
04:46 PaulCapestany joined #git
04:50 venmx joined #git
04:51 pks joined #git
04:52 PioneerAxon joined #git
04:53 subhojit777 joined #git
04:53 Raging_Hog joined #git
04:56 svm_invictvs joined #git
05:01 jephsf joined #git
05:02 jaguarmagenta joined #git
05:07 jephsf joined #git
05:08 duderino3345 joined #git
05:10 ronskisika joined #git
05:11 romerocesar joined #git
05:12 duderino3345 left #git
05:22 govg joined #git
05:22 MaggieC joined #git
05:24 micdo_ joined #git
05:24 ismithers joined #git
05:24 MaggieC joined #git
05:25 robogoat joined #git
05:26 MaggieC joined #git
05:27 MaggieC joined #git
05:29 diogenese joined #git
05:30 inflames joined #git
05:30 syg_ joined #git
05:31 Andrew_K joined #git
05:31 blunaxela joined #git
05:34 mischat joined #git
05:34 Shentino joined #git
05:35 howitdo joined #git
05:36 govg joined #git
05:37 varuog joined #git
05:38 howitdo joined #git
05:42 Cabanossi joined #git
05:42 Andrew_K joined #git
05:44 varuog left #git
05:44 morenoh149 joined #git
05:46 sbulage joined #git
05:51 WhiskerBiscuit joined #git
05:52 rominronin joined #git
05:52 kazantip joined #git
05:54 freimatz joined #git
05:57 aruns joined #git
06:00 varuog joined #git
06:05 ResidentBiscuit joined #git
06:06 queensheba joined #git
06:06 dreiss joined #git
06:07 tarkus joined #git
06:09 rscata joined #git
06:14 thesha joined #git
06:14 Raging_Hog joined #git
06:18 dodobrain joined #git
06:23 bocaneri joined #git
06:24 rwp joined #git
06:24 thesha while doing git push origin master,do i need to write the source repo inplace of origin or by writing git push origin master will solve my branch ahead of origin.master by 6 problem
06:24 cyan__ joined #git
06:26 adymitruk joined #git
06:26 rwp What controls where git-daemon writes its shallow_XXXXXX file? fatal: Unable to create temporary file '/srv/git/foo.git/shallow_EWTUNx': Permission denied
06:27 ngperfex joined #git
06:28 cyphase joined #git
06:28 adymitruk joined #git
06:30 diogenese joined #git
06:30 Shentino joined #git
06:32 romerocesar joined #git
06:38 FSadino joined #git
06:39 cqi joined #git
06:40 aidalgol joined #git
06:44 YuGiOhJCJ joined #git
06:46 ogny joined #git
06:50 Vampire0_ joined #git
06:51 venmx joined #git
06:53 ayogi joined #git
06:54 lordjancso joined #git
06:55 cyphase joined #git
06:55 qt-x joined #git
06:56 jasom joined #git
06:58 govg joined #git
07:00 j416 thesha: "git push origin master" will work
07:00 ThomasLocke joined #git
07:00 morenoh149 joined #git
07:02 xall joined #git
07:03 dermoth joined #git
07:05 armyriad joined #git
07:06 svm_invictvs joined #git
07:07 zeroed joined #git
07:07 Andrew_K|2 joined #git
07:13 gareppa joined #git
07:17 romerocesar_ joined #git
07:18 PioneerAxon joined #git
07:18 roelmonnens joined #git
07:19 Vortex34 joined #git
07:20 govg joined #git
07:21 rominronin joined #git
07:23 freimatz joined #git
07:23 AndChat29841 joined #git
07:23 rominron_ joined #git
07:26 jnavila joined #git
07:26 SwiftMatt joined #git
07:27 zeroed joined #git
07:28 rorro joined #git
07:29 venmx joined #git
07:33 dave0x6d joined #git
07:34 jknetl joined #git
07:35 psyb0t joined #git
07:36 mischat joined #git
07:39 star_prone joined #git
07:41 overlord_tm joined #git
07:42 inflames joined #git
07:43 dminuoso joined #git
07:43 dminuoso Let's say I have some WIP that is not yet committed. Right now I have the need to build a testcase for a compile bug.
07:43 star_prone joined #git
07:44 dminuoso Would you commit the WIP and then use rebase later to get rid of this partial commit?
07:44 bremner sure
07:44 Sceorem joined #git
07:44 phroa consider man git-stash, though I personally just commit any and everything and rebase everything before I push.  !sausage
07:44 gitinfo [!sausage_making] Some developers like to "hide the sausage making", transforming their commits before presenting them to the outside world. See http://sethrobertson.github.com/GitBestPractices/#sausage and !perfect
07:44 gitinfo the git-stash manpage is available at http://jk.gs/git-stash.html
07:45 systemovich joined #git
07:45 polyzen heh
07:45 dminuoso Is there a similar thing to a fixup! for this?
07:46 systemovich joined #git
07:46 jast what's your plan, add to that commit later and turn it into a "proper" one?
07:46 Andrew_K joined #git
07:46 dminuoso Yeah
07:46 jast I don't think so, actually
07:48 jast you could go the other way around, though: use --fixup on your later commits that finish the WIP, then in rebase -i --autosquash just mark the WIP commit as 'reword' manually
07:48 dminuoso jast: Oh that would work. :)
07:49 Orion3k joined #git
07:51 romerocesar joined #git
07:51 rwp Anyone know what conditions git-daemon requires creating a shallow_XXXXXX file?
07:52 rwp I have several installations that work great and --depth 1 works fine. But another one that git-daemon always wants to create a shallow_XXXXXX file but obviously can't due to permissions.
07:53 JeroenT joined #git
07:54 dreiss joined #git
07:57 tobiasBora joined #git
07:59 kazantip joined #git
07:59 sea-gull_ joined #git
08:00 FSadino joined #git
08:03 AndChat|383616 joined #git
08:05 zeroed joined #git
08:05 osse dminuoso, jast: for that I'd use --squash instead of --fixup. saves you from changing pick to reword :)
08:06 jast but then you have to delete more lines from the message editor
08:06 jast so many lines!
08:08 JeroenT joined #git
08:12 danslo joined #git
08:13 Jackneill joined #git
08:16 byte512 joined #git
08:18 spacelord_ joined #git
08:24 romerocesar joined #git
08:24 Sample joined #git
08:25 rorro joined #git
08:26 NimeshNeema joined #git
08:27 a_thakur joined #git
08:30 derk0pf joined #git
08:33 chele joined #git
08:35 osse jdG
08:35 osse dude bruh
08:35 osse do u even
08:35 jast wat
08:36 jephsf joined #git
08:36 mischat joined #git
08:41 JeroenT joined #git
08:42 diogenese joined #git
08:44 adamm joined #git
08:46 Balliad joined #git
08:47 djb-irc joined #git
08:49 Guest60896 joined #git
08:50 tvw joined #git
08:51 elect joined #git
08:51 a_thakur joined #git
08:51 morenoh149 joined #git
08:52 kurkale6ka joined #git
08:52 breezy_ joined #git
08:52 Singmyr joined #git
08:53 roxlu joined #git
08:54 Vampire0 joined #git
08:54 fbwnd joined #git
08:54 mikecmpbll joined #git
08:55 Mannn joined #git
08:56 garethdaine joined #git
08:57 overlord_tm joined #git
08:58 leeN joined #git
08:59 willlondon joined #git
09:00 encod3 joined #git
09:01 romerocesar joined #git
09:02 djb-irc joined #git
09:07 ochorocho__ joined #git
09:09 eduardas_m joined #git
09:10 JeroenT joined #git
09:16 marcogmonteiro joined #git
09:19 nettoweb joined #git
09:20 jaguarmagenta joined #git
09:20 djb-irc joined #git
09:20 ocbtec joined #git
09:22 rajkumar joined #git
09:22 _ADN_ joined #git
09:22 rajkumar hi
09:22 gitinfo rajkumar: 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.
09:24 nettoweb_ joined #git
09:28 elect_ joined #git
09:30 ams__ joined #git
09:31 xall joined #git
09:32 Derderderd joined #git
09:36 [ADN] joined #git
09:37 mischat joined #git
09:37 [ADN] joined #git
09:39 SicoWork joined #git
09:42 nettoweb joined #git
09:43 mattkrea joined #git
09:44 rnsanchez joined #git
09:45 SwiftMatt joined #git
09:47 Sample joined #git
09:48 ochorocho__1 joined #git
09:49 [ADN] joined #git
09:49 Oatmeal joined #git
09:50 chll_ joined #git
09:51 mischat joined #git
09:52 Serpent7776 joined #git
09:56 chris2_ joined #git
10:00 a3Dman joined #git
10:02 orfeo joined #git
10:10 howitdo joined #git
10:11 ferr1 joined #git
10:13 JeroenT joined #git
10:15 ngperfex joined #git
10:16 Sample joined #git
10:18 byte512 joined #git
10:19 roelmonnens joined #git
10:24 mathematic-alpha joined #git
10:24 rivarun joined #git
10:30 sLite joined #git
10:31 dodobrain hi all..
10:31 romerocesar joined #git
10:31 dodobrain i noticed that i have accidentally added credentials into a file in a very old commit
10:31 dodobrain how do i now get rid of the credentials in this file but keep my history after that commit?
10:31 _ikke_ Is rewriting history a problem?
10:32 chromity joined #git
10:32 dodobrain _ikke_, by rewriting history, do you mean all the timestamps for further commits will change?
10:32 Derderderd joined #git
10:33 dminuoso dodobrain: No, rewriting history means that you modify old commits.
10:33 dodobrain or do you mean to ask if this will create problems for other users who have cloned and are tracking my repo?
10:33 dminuoso i.e. all commit hashes would change
10:33 dminuoso dodobrain: Did the change make it into the public repository? If so, change the credentials.
10:33 dodobrain no problems.. i don;t care if commit hashes change as long as the timeline is retained
10:33 _ikke_ dodobrain: what dminuoso says, and yes, that will affect others
10:34 _ikke_ All commits stay, they just get a new hash
10:34 _ikke_ !bfg
10:34 gitinfo A tool designed to remove large files, or passwords from history: https://rtyley.github.io/bfg-repo-cleaner/ (!rewrite applies)
10:34 dodobrain its only on my repo that not public but open to a few select people.
10:34 dodobrain and those people don;t care that the hashes have changed
10:34 dodobrain infact i can simply tell them to cloen the enitre repo again and drop their existing clone (if necessary)
10:35 tcorneli joined #git
10:35 _ikke_ look at that tool
10:35 dodobrain sure, but i would like to know how to do this from scratch as well :)
10:35 _ikke_ The other option, built into git (but slightly more complex) is man git filter-branch
10:35 gitinfo the git-filter-branch manpage is available at http://jk.gs/git-filter-branch.html
10:36 dodobrain _ikke_, i cannot simply git checkout hash_of_commit_with_creds; vi myfile.txt; git commit -a    <- this will not work right?
10:36 star_prone joined #git
10:37 _ikke_ nope
10:37 _ikke_ that will just create a new non-referenced commit
10:37 encod3_ joined #git
10:37 dodobrain how about git rebase -i hash_of_bobo_commit ?
10:37 dodobrain then i edit that particular commit
10:37 _ikke_ dodobrain: Not recommended for history that's older
10:37 _ikke_ git rebase flattens history
10:38 _ikke_ And possibly quite slow
10:40 mathematic-alpha left #git
10:40 morenoh149 joined #git
10:41 mischat joined #git
10:41 cdown joined #git
10:42 jast dodobrain: actually hash_of_bad_commit^ because rebase -i needs the parent of whatever you want to change. yeah, should work. filter-branch can be much faster if all you want to do is delete a file, but if you need to edit out sections of a file, rebase -i is probably the way to go.
10:42 dodobrain jast, yes, that is true. i need one above.
10:43 mischat joined #git
10:43 dodobrain but how would rebase work if i have had merge commits of other branches into my main branch later on?
10:43 dodobrain i mean after my badcommit
10:43 jast you can use the -p flag to preserve merge commits
10:43 jast and cross your fingers ;)
10:43 dodobrain lol
10:44 _ikke_ jast: filter branch in combination with sed should also get you quite far :P
10:46 parasite_ joined #git
10:48 jast quite far down the road of insanity, yes :P
10:48 porsche944 joined #git
10:49 dsantiago joined #git
10:50 _ikke_ :D
10:51 WaReZ joined #git
10:52 JanC_ joined #git
10:54 onmeac joined #git
10:55 QuestionTime joined #git
10:55 QuestionTime joined #git
10:58 ronskisika joined #git
10:59 rafalcpp joined #git
11:02 flavius joined #git
11:03 romerocesar joined #git
11:06 dsop joined #git
11:07 ronskisika joined #git
11:09 pks joined #git
11:11 JeroenT joined #git
11:12 linxm joined #git
11:16 davimore_ joined #git
11:17 tannp joined #git
11:17 cqi joined #git
11:17 star_prone joined #git
11:18 cqi joined #git
11:20 jaguarmagenta joined #git
11:21 DieguezZ joined #git
11:25 achadwick joined #git
11:25 nowhere_man joined #git
11:31 satifant joined #git
11:33 lightstalker joined #git
11:33 Derderderd joined #git
11:36 somaReverse joined #git
11:37 manuel_ joined #git
11:37 mykespb joined #git
11:37 djb-irc joined #git
11:43 danslo joined #git
11:44 PCatinean joined #git
11:44 jfr joined #git
11:46 InfoTest joined #git
11:48 JeroenT joined #git
11:56 ismithers joined #git
11:56 fahadash joined #git
11:57 phanimah1sh joined #git
11:58 chele joined #git
12:00 sLite joined #git
12:01 gareppa joined #git
12:01 buffal0 joined #git
12:03 buffffal00 joined #git
12:03 JeroenT joined #git
12:03 mischat joined #git
12:03 rorro joined #git
12:05 King_Hual joined #git
12:07 ToBeCloud_ joined #git
12:11 djb-irc joined #git
12:13 theoceaniscool joined #git
12:13 encod3 joined #git
12:14 re1 joined #git
12:16 Anticom joined #git
12:17 Anticom Hi all. I think i'm having an issue understanding cherry-picking: https://asciinema.org/a/6ymajydshqh4noloko0gs8ke7
12:19 Anticom Please don't be fooled by the 2nd and 3rd 'g lg' this alias hasn't got the --all flag, hence the 'g lga' at the end
12:19 Anticom Had a little brainfart there :>
12:21 _ikke_ That's why it's not recommended to use aliases when trying to demonstrate something
12:21 _ikke_ We cannot verify anything because we don't know what these aliases do
12:21 Anticom _ikke_: okay, just a second
12:22 selckin issie is probably just those .. ranges being inclusive or not ?
12:24 SicoWork Anticom: the <ref1>..<ref2> you use for cherry pick means everything that is in <ref2> but not in <ref1>, so excludes <ref1>
12:24 JeroenT_ joined #git
12:25 Anticom SicoWork: I thought <a>...<b> meant 'range from commit <a> to commit <b>'
12:25 GavinMagnus joined #git
12:26 denisMone joined #git
12:26 SicoWork Anticom: this page explains it - https://git-scm.com/book/en/v2/Git-Tools-Revision-Selection#Commit-Ranges
12:27 SicoWork it's a common mistake when selecting ranges
12:27 Anticom SicoWork: so in my example i'd just have to flip the sha's?
12:28 Derderderd joined #git
12:28 SicoWork Anticom: no, you'd use the parent of the second hash
12:28 Anticom SicoWork: But cherry-picking is about single commits isn't it?
12:28 djb-irc joined #git
12:29 Anticom i'd like to leave the "Added foo" in feature/foo and pick the other ones to feature/b-stuff
12:29 morenoh149 joined #git
12:29 SicoWork Anticom: cherry pick is usually single commits, but can be multiple (for multiple it is often done as a rebase)
12:30 Anticom SicoWork: Which is basically what i want but without using rebase for educational purposes :)
12:30 SicoWork Anticom: you can specify the 2 commits you want as separate arguments to cherry pick
12:30 SpaghettiCat left #git
12:31 Anticom SicoWork: that is white-space seperated?
12:31 SicoWork Anticom: yeh, and it picks them in the order you specify them
12:31 _ikke_ cherry-pick also works with ranges
12:31 _ikke_ (I haven't extensively looked at the problem yet)
12:31 Anticom SicoWork: do i'd have to pick them from old to new commits to preserve the original order?
12:32 SicoWork Anticom: correct :)
12:32 djb-irc joined #git
12:32 Anticom SicoWork: great, that worked. Is there any flag i can supply to cherry-pick so that it does a move instead of a copy operation?
12:33 Anticom my log now shows the commits in both branches
12:33 SicoWork Anticom: git will never move, you are always creating new commits
12:33 Anticom SicoWork: rebase does move, doesn't it? :p
12:33 SicoWork Anticom: so the old ones always exist, if you don't want them in a branch, you can move where your branch references
12:34 Anticom SicoWork: Rewriting history is not an issue with my repo
12:34 SicoWork Anticom: with rebase, you're usually moving a branch, so the old commits are there but don't show up in a log because there is no branch pointing to them any more
12:34 Anticom hm now you got my head spinning :S
12:35 rorro joined #git
12:35 encod3 joined #git
12:35 rajkumar joined #git
12:35 qqx joined #git
12:35 Anticom Think i'll got back to rebasing for now
12:36 SicoWork Anticom: in this instance you would have the same outcome with a rebase
12:36 SicoWork Anticom: to get baz and bar out of feature/foo, you can do `git branch -f feature/foo 80b640c`
12:39 romerocesar_ joined #git
12:39 Anticom SicoWork: Okay thank you so much
12:42 manuel_ joined #git
12:42 xall joined #git
12:44 altendky joined #git
12:44 kaldoran joined #git
12:44 aard_ joined #git
12:51 djb-irc joined #git
12:51 sdothum joined #git
12:51 rominronin joined #git
12:53 chromity joined #git
12:55 _Vi joined #git
12:56 GavinMagnus left #git
12:56 ojdo joined #git
12:58 jenniferrr joined #git
13:01 johnmilton joined #git
13:02 govg joined #git
13:02 bket joined #git
13:06 ResidentBiscuit joined #git
13:06 sbulage joined #git
13:07 venmx joined #git
13:08 cyan__ joined #git
13:09 chigang joined #git
13:10 varuog joined #git
13:14 nettoweb joined #git
13:14 oskarkv joined #git
13:21 synthroid joined #git
13:21 jaguarmagenta joined #git
13:21 star_prone joined #git
13:23 Ahiiru joined #git
13:24 oskarkv joined #git
13:24 dviola joined #git
13:25 d0nkeyBOB joined #git
13:28 Derderderd joined #git
13:29 oskarkv_ joined #git
13:33 dan2k3k4 joined #git
13:34 perlpilot joined #git
13:34 synthroi_ joined #git
13:34 star_prone joined #git
13:35 JeroenT joined #git
13:35 dreiss joined #git
13:36 kba I think I did a bad merge or something, because now Git is just being stupid. I have a devel branch: https://github.com/Webstrates/Webstrates/tree/devel
13:36 kba Which I tried to merge with the master branch the other day, and it seemed to work. Yet now I notice it says "This branch is 6 commits ahead, 6 commits behind master.
13:37 kba So I click Compare (https://github.com/Webstrates/Webstrates/compare/devel) and it tells me the differences... But those differences don't exist.
13:37 mikecmpb_ joined #git
13:37 kba If you look at the first diff it presents, it says AssetManager.js is different in the two branches.
13:37 kba https://github.com/Webstrates/Webstrates/blob/devel/helpers/AssetManager.js#L104-L107
13:38 kba https://github.com/Webstrates/Webstrates/blob/master/helpers/AssetManager.js#L104-L107
13:38 kba But they're identical.
13:38 kba Doing `git diff origin/devel...origin/master` locally shows me the same thing -- a difference that isn't there.
13:41 roelmonn_ joined #git
13:42 roelmonn_ joined #git
13:43 davimore joined #git
13:45 kadoban joined #git
13:48 theoceaniscool joined #git
13:49 chromity joined #git
13:49 kba A merge and two rebases later, and we're back to normal. Awful.
13:51 Ahiiru do you guys automate your commit/push commands in some way?
13:51 Ahiiru I find writing down every command quite slow
13:52 davimore joined #git
13:52 rafalcpp Ahiiru: bash alias for examples.
13:54 Ahiiru does that pause executing for writing customized data (as for commit comments) then resume again?
13:55 mgoodwin I have a real hard time with git when it comes to making a new project and it comes time to commit. You get to the point where something works and now you have all this code to commit and you're also supposed to break it up into 'ideas' to commit, and I always mess that up during the commit process.
13:56 kadoban mgoodwin: Commit earlier (and more often)?
13:56 mgoodwin Yeah I keep telling myself
13:56 mgoodwin But I work so fast that never seems to happen
13:56 kadoban It comes time to commit as soon as I either copy in whatever skeleton of files or create the first file ...
13:56 mgoodwin It's probably a discipline issue
13:56 star_prone joined #git
13:56 mgoodwin I do that too, but then I don't stop until I get something that somewhat works
13:57 kadoban Yeah, it's just habit, you just have to force yourself to try for a while and it'll become second nature.
13:57 mgoodwin I've used git for years and I know it better than most developers I meet, but I'm not a developer. I've always used it from the ops/QA perspective
13:57 Vampire0_ joined #git
13:57 mgoodwin Now I find myself doing development lately and I find this problem
13:59 mgoodwin I find myself going through the diff and doing a mental-bubble-sort of ... sorts
13:59 cdown joined #git
13:59 mgoodwin Where I pick the first change and visually inspect the rest of the diff and patch add the next thing that relates
13:59 mgoodwin until I can "package an idea into a commit"
14:01 rajkumar joined #git
14:01 mgoodwin It's an odd juxtaposition of being lazy up front intersecting with not wanting to be lazy in the end
14:01 star_prone joined #git
14:01 mgoodwin I could in theory just git add . and commit "This works, here's why:"
14:01 mgoodwin :/
14:04 Gsham joined #git
14:06 SebastianM joined #git
14:06 theoceaniscool joined #git
14:07 kba Ahiiru: What part is it you find slow? I just do `git commit -a` then write my commit message, :x and git push eventually
14:08 romerocesar joined #git
14:08 selckin that just means you where actually changing unrelated things together and should maybe be commiting more often
14:08 Ahiiru kba: maybe I'm just not used to it
14:09 kba Ahiiru: Maybe, it's two fairly brief commands in my opinion
14:09 Ahiiru I take about two minutes to send my changes, it's quite a lot, I think
14:09 kba Writing a good commit message can take some time, but writing `git commit -a` shouldn't take long
14:10 Ahiiru login (wait), password (wait), sync files (wait)
14:10 kba login? password? What?
14:10 kba setup pub/priv key
14:10 steven when running interactive rebase in a branch with 20 merges things get a bit annoying, is there a way to make rebase respect merges as well or does one simply have to suck it up and manually re-merge then continue the rebase?
14:10 kba I don't ever "login" or write a password
14:10 dimi1947 joined #git
14:11 Ahiiru pob/priv keys are a good solution
14:11 kba and you don't really have to wait after pushing for the files to be synched, you can just go about your business
14:11 Ahiiru pub*
14:11 canton7 steven, there's --preserve-merges (which might be incompatible with -i, iirc), but rebase and merge are fundamentally different operations
14:12 jeffreylevesque joined #git
14:12 GodGinrai joined #git
14:12 kadoban -i and --preserve-merges are indeed a bad combination
14:13 steven I don't know enough details about git but I thought a merge was just another commit
14:13 indistylo joined #git
14:13 trobotham joined #git
14:13 steven the commit that just merges stuff from another branch
14:13 markand joined #git
14:14 steven or does git handles merges differently? (well I'd assume it does given that rebasing doesnt work fluently with it)
14:15 canton7 nah, that's what merges are. A rebase is fundementally about flattening history though - rebases get rid of merges
14:15 nowhere_man joined #git
14:16 steven yeah, that I understand. but why does git rebase -i not list merge's when those are just regular commits in my branch?
14:16 steven btw I got it, I am just trying to understand it :)
14:16 jast by default, rebase linearizes merges, i.e. it inserts the individual merged commits instead of the merge
14:16 steven cos when rebase fails and I have to manually merge, I am doing exactly what I did with the merge's.
14:16 canton7 because it's doing a rebase, which by definition linearlizes history and removes merges
14:17 jast you can add -p to make rebase try and re-generate the merges instead
14:17 canton7 it just so happens that the command to go back and edit history is tightly coupled to the command to remove merges
14:18 steven ah ok. so a more general question, if you had a branch of something and prepin' a PR with 10 merges and want to squash them all into single commit
14:18 griffindy joined #git
14:18 steven would you add -p or just manually go thru the changes until rebase is happy?
14:18 morenoh149 joined #git
14:18 canton7 if I was squishing it into a single commit, I'd use 'git merge --squash' :P
14:18 ExoUNX joined #git
14:19 bdonnahue joined #git
14:19 canton7 ... but if I wanted to use rebase to squash a branch down to 2 or 3 commits, I would be removing the merge commits, so I wouldn't use -p
14:19 jast as a maintainer personally I would prefer receiving a PR that is all cleaned up and doesn't have any merge
14:19 nicksloan joined #git
14:19 steven lets be ok now lets figure this out jast, I want to keep my branch up2date with upstream tho to avoid conflicts, what should I do instead of merging upstream?
14:20 steven and canton7 how can I "remove" the merge commits?
14:20 jast you can rebase against upstream instead
14:20 nettoweb joined #git
14:20 jast (git rebase theupstream)
14:20 canton7 steven, rebase removes merge commits.
14:20 masuberu joined #git
14:21 jast there are some potential issues if you do that and publish your intermediate branch state in between, because people will see multiple versions of the same history
14:21 steven ok so rebase removes merges, imma rebase against upstream and have to merge the stuff (I merged previously) again?
14:21 canton7 no
14:21 jast well it can happen that you have to re-fix conflicts
14:21 steven thats what I meant with merge again*
14:21 canton7 when you rebase, you're taking the patch from each of your commits, and re-applying them on top of the upstream branch
14:21 jast downside of switching between merge and rebase
14:21 steven not a merge commit but rather fixing the conflicts again the --continue the rebase
14:21 canton7 because your work is now based on the upstream branch, it already contains all of the changes from upstream
14:21 mgoodwin selckin: How do you not change unrelated things in a new project? I get and have experienced how easy it is to do it with existing projects for which you're merely modifying but that's not what I'm talking about
14:22 jast in fact if you have resolution recording active, try 'git rerere' when there are conflicts, they may get auto-fixed
14:22 manuel_ joined #git
14:22 canton7 there's no need to merge upstream into your branch again - everything in upstream is already in your branch
14:22 selckin mgoodwin: by knowing i'm now changing to a differend problem
14:22 canton7 steven, you should *definitely* not be merging when resolving a rebase conflict - that's going to *really* confuse things
14:22 selckin mgoodwin: when starting a new project its kinda fuzzy, but when its a bit establisched its pritty obvious
14:22 jast canton7: sure, but during the rebase you may have to re-address conflicts initially fixed during the old merges
14:22 canton7 jast, sure, but you don't re-address them by *merging again*9
14:22 [cust] joined #git
14:22 steven ok I kind of start to get it canton7 .. but wouldn this end up in one huge rebase (as in fixing stuff with every step?) instead of just merging regularly?
14:23 jast that was just misworded I think
14:23 jast steven: not quite
14:23 steven also what's merge squash? I think someone mentioned that a few minutes ago
14:23 canton7 steven, once you've fixed a rebase conflict once, it won't appear again. If you first do a merge, then do a rebase which replaces the merge, you'll see the same conflicts again (unless you use rerere)
14:24 jast don't worry about squash merge for now, but basically it's a merge that ends up pretending you made a big commit with all the changes that you merged in, instead of doing a proper merge
14:24 canton7 steven, 'merge --squash' just takes the difference between upstream and your branch, and applies it as a single commit to upstream
14:24 Ahiiru left #git
14:24 jast there are few cases in which it's useful IMO
14:24 jast to get back to rebase: each time you do a new rebase, only the new commits from upstream will be added, so only conflicts introduced by those will need to be fixed
14:25 canton7 it's useful for the "I don't care about all of these intermediate commits and merges, I just want a single commit which contains everything in my branch"
14:25 jast well you don't have that case if you keep your branch reasonably clean in the first place :)
14:25 canton7 sure, but contributers often won't do that :P
14:25 steven canton7: ok, but if you squashed your branch at the end of the iteration anyway wouldnt it be best to just squash the merges as well?
14:25 jast contributors won't really bother using squash merge on a temp branch to then create a pull request on github, either :)
14:26 canton7 steven, what do you mean by "squash the merges"
14:26 steven I mean most of the commits I don't care about, I dont need to know details about fixed typos or reverting a broken commit, etc
14:26 canton7 jast, no, but you can merge --squash their work
14:26 jast urgh :)
14:26 rwb joined #git
14:26 jast squash is all-or-nothing
14:26 jast it's exactly like a normal merge
14:26 steven ^ is this a general rule or your opinion
14:26 steven so either squash or merge?
14:26 jast so if you go on master and 'git merge foo', it merges foo, only then it makes a normal commit with the result instead of a merge commit
14:27 canton7 sorry, I did muddy the waters by talking about merge --squash. Forget I mentioned it
14:27 steven already did
14:27 unbalanced joined #git
14:28 steven so would be rebasing branches against upstream but merging branches into upstream a vague rule of thumb?
14:28 jast it's terrible and an all-around bad idea for your case of 'merge from upstream' because squash merges mess up automatic merging on subsequent merges between the same branches
14:28 jast so you'd only ever use it at the very end of work on a branch, and then get rid of it
14:28 jast well, they *can* mess up automatic merging. if you're lucky they might not. still, why take any chances? :)
14:30 stevenxl Hi folks. I have a two remotes (origin and production). I'd like to replace origin/master with production/master.
14:30 steven ok let me ask you this way, how would you deal with a branch that has a life span of like a couple weeks but upstream changes daily jast canton7 ?
14:30 Derderderd joined #git
14:30 steven cos atm I simply merge upstream every day
14:30 jast rebase (or pull --rebase) in most cases
14:31 steven so you avoid merges in general?
14:31 jast nah
14:31 canton7 that or merge a lot, but with rerere turned on, so I can rebase it easily at the end
14:31 jast think of it like this
14:31 _Cyclone_ joined #git
14:31 JeroenT joined #git
14:32 stevenxl I've tried deleting origin/master, then using git checkout --track production/master. Are those the correct commands?
14:32 jast whenever both branches have changes, a merge is a record of "hey, I took all these commits from here"
14:32 canton7 --track means something completely different
14:32 jast in some situations that's great, because for prosperity it's very useful to know that the merge happened at exactly this point and so on
14:32 jast if you do it every day, on the other hand, the history gets pretty cluttered
14:33 jast so for staying up-to-date I usually prefer rebasing
14:33 JeroenT_ joined #git
14:34 jast stevenxl: not exactly. origin/master is a local mirror of the remote branch, updated by 'git fetch'. you don't need to touch that. you do have to change master, which "tracks" one of the mirror branches (right now it tracks origin/master)
14:34 danslo joined #git
14:35 steven ok so maybe I just have to rebase the next branch and see the difference. but merging branches into master seems to be a common practise, why wouldnt ppl rebase branches into master jast ?
14:35 nickabbey joined #git
14:35 steven everyone just merges, some ppl who don't like it cherry-pick, but almost no one rebases
14:35 jast steven: because in that direction the record is more meaningful: I added this feature to master at this point in time
14:35 jast plus on a branch that sees changes from multiple people, rebasing is very tricky
14:36 steven with a squashed PR tho it'd make more sense to cherry pick since it's a single commit anyway?
14:36 snowkidind joined #git
14:36 a_ok joined #git
14:36 steven I think gerrit does only cherry picks?
14:36 jast so when you're merging not for keeping up-to-date but for integrating something "finished", a merge can be a very sensibleoption
14:36 stevenxl @jast thanks I think that gives me enough info to go on
14:37 jast for something smaller a squash merge, as you explained, or a cherry-pick, can do just as well
14:37 jast in that case you don't have the explicit record of "merge happened here", it just looks like a regular commit to master
14:38 a_ok Is there a way I can perform a pre-stage action?
14:38 jast stevenxl: you can hard reset master to production/master and then update the tracking info (e.g. git branch -u), but be aware that hard resets can lose you uncommitted/unpushed changes
14:38 steven gotcha, well thanks jast canton7 :) imma fiddle around with rebasing in my next branch. maybe that'd work better in my case
14:38 jast a_ok: what do you mean?
14:38 Jupelius joined #git
14:39 jast steven: sure, just keep the golden rule in mind: don't rebase branches that other people are working on, too, unless you've made sure they also use only rebase on that branch
14:39 nickabbey joined #git
14:39 a_ok jast: I have a webplatform that contains tird-party modules. They somethimes contain .gitignore files that ignore to much. I would like to remove all but the top level .gitignore file before staging.
14:40 steven ah good, so as long as I am working on the branch myself imma ok to rebase jast ?
14:40 cyan__ joined #git
14:40 romerocesar joined #git
14:40 jast steven: yep
14:40 steven mostly I do work alone on my branches
14:40 steven but good to know, thanks
14:40 jast that's the easy case
14:40 treehug88 joined #git
14:40 jast on a personal branch you can go all out on history rewriting
14:40 nettoweb1 joined #git
14:40 nickabbey joined #git
14:41 Jupelius joined #git
14:41 jast a_ok: by "staging" do you mean git's "staging" or something else?
14:41 a_ok jast: git staging yes
14:41 CheckDavid joined #git
14:42 jast okay. well, you can actually work around this kind of thing... .gitignore only applies to untracked files, so if you want to add an ignored file, a one-time 'git add -f' on it is enough
14:42 jast the other option is sparse checkout but that's slightly tricky to set up... !sparse
14:42 gitinfo [!sparse_checkout] Sparse checkout can be used to restrict which files/folders are updated with all checkout and status operations. It cannot change the tree the checkout is rooted from. One common use case is locally keeping Git from updating some of the files tracked in your repository. See the "Sparse Checkout" section in man git-read-tree (http://jk.gs/git-read-tree.html).
14:42 mischat joined #git
14:43 jabberwock joined #git
14:43 jabberwock Hi. If I only have the .git directory for a project, is there a tool that lets me glean the original files?
14:44 jabberwock I would think the original files + deltas would be there.
14:44 jast sure
14:44 jast one way is to 'git clone' and use the directory as the source dir/URL
14:44 ToxicFrog jabberwock: you can `git checkout` a commit, or `git clone` it, or (to inspect without dumping files all over your lap) `git show`, `git ls-tree`, and `git cat-file`.
14:45 jast it may fail if the .git dir is lifted out of a normal clone instead of from a hosting ("bare") repo
14:45 jabberwock This is a site (actually many sites) that happen to have /.git/
14:45 jabberwock all the same software as far as I can tell
14:45 synthroid joined #git
14:45 ToxicFrog Generally, you can treat it like a normal git repo where all the files have been deleted from the working copy (and if you "git status" it that's probably what it'll report as)
14:45 jast basically we distinguish between bare repositories (just the metadata from .git) and non-bare repositories (the files are checked out)
14:45 jabberwock I just want to show the client that I can get their source code when they do this
14:46 nickabbey joined #git
14:46 jast so, one way is clone, the other is putting the .git in an empty dir and using 'git checkout .' from there. one of the two will always work.
14:46 jast actually, git checkout HEAD ., just to be sure
14:46 rafalcpp I have bunch of remotes. How to check which one of them on which branch contains given git-rev
14:46 rorro joined #git
14:47 rafalcpp find any remote/branch that contains that git-rev
14:47 jast rafalcpp: git branch --contains, I believe you can use it with -a and -r if you want
14:47 a_ok jast: The issue is that we update and add (or remove but that is not relevant here) modules all the time. It is very hard to check that all the files are present in our git repository.
14:48 jast a_ok: okay, the sparse checkout route can help with that, but you have to set it up manually in each clone of the main repo
14:48 jabberwock jast: Hmm. `git checkout HEAD` did a bunch of deletes
14:48 jabberwock (on files that weren't there)
14:48 jabberwock but it does list filenames which is a step forward
14:48 jast jabberwock: the '.' as the second argument is important
14:48 jast checkout does two different things depending on whether you give a path argument
14:48 jabberwock aha!
14:48 jabberwock thank you :) perfect
14:49 jast what you did without the '.' is switching to the current branch (a no-op), and git then gave you a short status summary, showing how your working tree differs from the current commit :)
14:49 * jabberwock nods
14:49 jabberwock There was a time when I knew this sigh
14:49 jast and git helpfully noticed that all the files were gone
14:49 yehowyada joined #git
14:49 jabberwock yeah that makes sense
14:49 jast just keep using it and it'll be back in non time
14:49 jast *no, dangit
14:49 jabberwock Thanks! That makes this assessment much more interesting
14:49 jast I blame this crummy keyboard
14:49 a_ok jast: I can do it on the clone that we use to update the repository but not on the deployment system.
14:50 jabberwock now I can gitrob to try and find sensitive files
14:50 jaafar joined #git
14:50 jast a_ok: on the deployment system it shouldn't matter since you don't run 'git add' on that, do you?
14:50 jabberwock and look at exif data
14:51 robotroll joined #git
14:52 govg joined #git
14:52 rafalcpp jast: thanks for idea. Close.  no -a -r, but instead just use --contains
14:53 a_ok jast: Ok I will see if that works for us. Else I am just going to write a little git wrapper. Both are undesireble workarounds.
14:53 Es0teric joined #git
14:53 jaguarmagenta joined #git
14:53 rominronin joined #git
14:56 Siegfried joined #git
14:57 jast rafalcpp: -r means look at remotes, -a means look at local branches and remotes. without either, it only looks at local branches. you have to be careful to not put the -a/-r between --contains and the rev, though, because otherwise that's invalid syntax. :)
14:58 jimi_ joined #git
14:58 jast a_ok: you could also add .gitignore files to your main .gitignore (and make an exception for that one), so the .gitignore files don't get added in the first place...
14:58 jast though that's only half of a solution because it doesn't help the person who adds the module
14:59 rafalcpp jast: whoops indeed. need coffey :P
14:59 jast I only remembered to mention that because I did it myself :P
14:59 clmsy joined #git
15:00 arooni joined #git
15:01 a_ok jast: Indeed I do not care about the .gitignore being commited. The problem is indeed that the platform manager can silently create broken builds that have been tested fine.
15:02 Singmyr joined #git
15:03 Dougie187 joined #git
15:03 anonymuse joined #git
15:06 rominronin joined #git
15:06 e14 joined #git
15:07 morenoh149 joined #git
15:08 venmx joined #git
15:10 romerocesar joined #git
15:11 AaronMT joined #git
15:12 tlaxkit joined #git
15:13 Khisanth joined #git
15:19 denisMone joined #git
15:21 Derderderd joined #git
15:22 someone_ joined #git
15:24 [cust] joined #git
15:25 JeroenT joined #git
15:26 JeroenT joined #git
15:26 sammyo joined #git
15:28 danslo joined #git
15:28 [cust] joined #git
15:29 nowhere_man joined #git
15:29 someone235 joined #git
15:30 someone235 Hi, I wanna know what files were affected in post-receive hook. Is it possible?
15:30 xall joined #git
15:30 cdown joined #git
15:30 crose joined #git
15:31 canton7 someone235, post-receive gets the old and new values for a ref, so it can do a diff between them and get a list of all affected files
15:32 [cust] joined #git
15:32 Tatou joined #git
15:32 Tatou Github costs for private repos, but gitlab is free. Is there anything that would put me to one or the other?
15:32 synthroi_ joined #git
15:32 Tatou I feel like gitlab CI would be handy
15:32 cousteau joined #git
15:34 someone235 canton7, how can I get those values?
15:34 canton7 someone235, they're described in man githooks
15:34 gitinfo someone235: the githooks manpage is available at http://jk.gs/githooks.html
15:36 cousteau is there some way to commit a "minor edit", sort of like what Wikipedia has?  Some sort of flag or something indicating the commit relevance that may mark the commit specially (for example, in gray text on github/bitbucket)
15:36 selckin no
15:36 jeffreylevesque is it possible to create an upstream branch on github, and send the pull requests on feature-xx, to upstream-branch-xx?
15:37 jeffreylevesque that way, later in the future i can merge upstream-branch-xx into master?
15:38 SwingShock joined #git
15:39 subhojit777 joined #git
15:39 al-damiri joined #git
15:39 Ranhir joined #git
15:39 t-mart joined #git
15:41 LionsMane joined #git
15:43 Severin42 joined #git
15:45 elect_ I somehow screwed up one intellij module, I re-created a new one from scratch and copy/pasted the src and test directories
15:45 nckpz joined #git
15:45 elect_ I'd like now to simply clean the remote origin and add everything
15:46 elect_ what shall I run in order to achieve that?
15:47 oaao joined #git
15:48 cousteau selckin, k thx :)
15:48 nettoweb joined #git
15:51 PCatinean joined #git
15:54 mischat joined #git
15:55 a_thakur joined #git
15:55 garethdaine joined #git
15:56 elect_ shall I do like here?
15:56 elect_ http://stackoverflow.com/a/18177448/1047713
15:56 desktable joined #git
16:01 d0nn1e joined #git
16:05 rorro joined #git
16:06 PresidentBiscuit joined #git
16:06 Gsham joined #git
16:07 cdg joined #git
16:09 Impaloo joined #git
16:09 axisys joined #git
16:12 corn13read joined #git
16:13 corn13read left #git
16:13 corn13read joined #git
16:13 corn13read what's the best way to check if a branch is merge-able but not do the merge? I want a proper test for my bash script
16:13 Neelixx joined #git
16:14 mikecmpbll joined #git
16:14 _ikke_ corn13read: There is nothing built in git
16:14 boombatower joined #git
16:14 corn13read nothing with an exit 1 if merge fails nicely?
16:14 moritz corn13read: you can merge with --no-commit
16:14 moritz with all the strings attached that come with it
16:14 realg0ld joined #git
16:14 _ikke_ I would setup a separate work-tree for this in a script
16:15 _ikke_ To test it
16:15 tang^ joined #git
16:15 shinnya joined #git
16:15 corn13read well the branch is ephemeral the code won't ever be used, I just want to know if there is a conflict
16:15 _ikke_ git does not do any in-memory merges
16:15 _ikke_ so the only way in git is to do it on disk
16:15 corn13read that's fine
16:16 corn13read but I literally throw it all away when I'm done, I am checking it out and want to know if there is a conflict then I throw it away
16:16 Gsham joined #git
16:16 tyreld joined #git
16:16 moritz the a merge with --no-commit sounds like a fine option
16:17 corn13read okay, I'll play around with it
16:17 corn13read thank you guys
16:17 _ikke_ You can use GIT_WORKTREE=foo to use a separate dir
16:18 _ikke_ You might need to do a checkout first though
16:18 _ikke_ (This way, you don't have a problem with non-clean working trees
16:18 a_thakur joined #git
16:18 _ikke_ Alternatively, you can use git stash to temporarily store the working tree state
16:21 nanga joined #git
16:21 nanga joined #git
16:21 qqx I'd recommend using `git worktree` if you want a place for that type of work rather than setting $GIT_WORKTREE. The latter would still be sharing the index.
16:22 Derderderd joined #git
16:23 _ikke_ right, but you can only have one branch checked out at the same time with worktree I believe
16:23 _ikke_ So it might not work with the current branch
16:24 jabberwock left #git
16:24 j416 you can have the same branch if you do --force
16:24 j416 (disclaimer: didn't read scrollback)
16:24 qqx A branch can only be checked out in a single worktree but there's `git worktree add --detach` which would allow creating a separate worktree pointing the same place as the current branch.
16:25 j416 hmm really?
16:25 j416 I could have sworn there was a here-be-dragons --force flag
16:25 sea-gull joined #git
16:25 _ikke_ Might be outdated
16:25 j416 (but detached makes more sense)
16:25 qqx j416: There is --force as well.
16:26 j416 yay
16:26 qqx But --detach would be the safer method.
16:26 j416 nod
16:26 j416 --force --no-dragon
16:27 star_prone joined #git
16:27 oaao joined #git
16:27 desktable i have a branch with commits but was out of date, so when it pulled it created a merge with the upstream changes AND my new changes. when reverting this merge it undoes my changes and the upstream changes. is there any way out of this without losing history? here's a screenshot to clarify - http://i.imgur.com/zis2bLs.png
16:28 VladGh joined #git
16:28 davimore_ joined #git
16:29 j416 desktable: rebase instead
16:29 j416 desktable: work on a separate branch and rebase that on whatever changed
16:29 j416 desktable: or,
16:29 _ikke_ But is a detached worktree useful for merging?
16:29 elect_ joined #git
16:30 qqx desktable: You should be able to get back to the state before the pull with `git reset --hard a5ecd27`. It you have uncommitted changes you should probably `git stash` first.
16:30 j416 somewhat less convenient imo, work om the samr branch and git pull --rebase
16:31 desktable qqx: we wound up doing the hard reset and had to force push, but it was risky because anyone could've pulled (it had already been pushed)
16:31 romerocesar joined #git
16:31 j416 and a5ecd27 should be HEAD^ so you can use that instead if you prefer
16:31 qqx desktable: Ahh I'd thought you caught it before pushing.
16:32 t-mart joined #git
16:32 desktable i wish :( i'm just trying to figure out what we could've done to not kill history
16:32 j416 desktable: reverting a merge is more tricky because of its implications; linus wrote a great post on it
16:32 j416 but doable.
16:32 qqx _ikke_: You can definitely do a merge in a detached worktree. And if it's just checking for conflicts there wouldn't be much more to it.
16:32 desktable j416: what i really wanted to do was revert everything back to a certain commit, but i couldn't see a way to do that without losing history
16:32 j416 if anyone can find the link; I'm on a phone
16:33 grawity git checkout <commit> -- .
16:33 _ikke_ qqx: right
16:34 j416 desktable: you can revert the merge (git revert -m1 HEAD) and then force-rebase (sic) your branch on the reverted commit. Best way in my opinion if history cannot be modified.
16:34 j416 (because reversions of reversions are a pain when git-blame'ing)
16:35 desktable j416: i did try reverting the merge, but it undid the merges from the earlier commit too. i didn't try the force-rebase though, that's new to me
16:35 j416 desktable: but now since you already force pushed, you're prolly better off from just going from there
16:35 desktable j416: i don't want to change anything, i just want to learn how to do it for next time. i kept a copy of the branch just to try things
16:36 j416 desktable: it's hard to summarise in chat, but try googling that article explaining merge reversions. Sec, I'll ser if I can find it
16:36 cousteau ok, I just realized that the change I had made, tested, verified as working, committed, and pushed did NOT actually work.  m(
16:37 cousteau how do I undo a commit?  Can I undo a previous commit without undoing the last one?
16:37 grawity `git revert <commit>`
16:37 j416 desktable: this one I believe; good read https://www.kernel.org/pub/software/scm/git/docs/howto/revert-a-faulty-merge.txt
16:37 cousteau ok... that reverts all commits up to that, or only that specific commit?
16:38 desktable j416: great i'll check that out thanks, hopefully there's a way out of this, cuz it was nasty
16:38 cdg_ joined #git
16:38 j416 desktable: but remember, reversions of reverts is a bit nasty, I'd much prefer rebase
16:38 jeffreylevesque joined #git
16:39 j416 (and you'll notice why force rebase is needed if you try plain rebase)
16:39 * j416 getting off train; afk o/
16:39 Neelixx joined #git
16:40 rominronin joined #git
16:41 rivarun joined #git
16:41 rominron_ joined #git
16:41 synthroid joined #git
16:42 overlord_tm joined #git
16:45 e14 joined #git
16:45 Gsham joined #git
16:47 jstein_ joined #git
16:47 mischat joined #git
16:48 madewokherd joined #git
16:48 dreiss joined #git
16:53 lucazz joined #git
16:55 corn13read joined #git
16:55 jasondockers joined #git
16:56 HardlySeen joined #git
16:56 HardlySeen joined #git
16:58 cousteau grawity, thanks!
16:58 garethdaine joined #git
17:00 a_thakur joined #git
17:01 Impaloo joined #git
17:02 rominro__ joined #git
17:02 Impaloo joined #git
17:04 Impaloo joined #git
17:05 Impaloo joined #git
17:05 Guest4843 joined #git
17:05 Impaloo joined #git
17:08 venmx joined #git
17:09 fahadash joined #git
17:10 Dougie187 joined #git
17:11 George___ joined #git
17:17 sbeller joined #git
17:21 nickabbey joined #git
17:23 Derderderd joined #git
17:26 algun joined #git
17:27 nickabbey joined #git
17:27 aarobc joined #git
17:27 xall joined #git
17:30 tang^ joined #git
17:33 freimatz3 joined #git
17:34 hfp joined #git
17:34 hfp_work joined #git
17:35 troulouliou_div2 joined #git
17:35 Atm0spher1c joined #git
17:35 encod3 joined #git
17:35 zeroed joined #git
17:35 zeroed joined #git
17:36 svm_invictvs joined #git
17:37 Guest97986 joined #git
17:37 Lipp joined #git
17:40 sea-gull_ joined #git
17:42 holodoc joined #git
17:42 nickthetait joined #git
17:42 nowhere_man joined #git
17:45 dar123 joined #git
17:50 Darcidride joined #git
17:51 denisMone joined #git
17:53 synthroi_ joined #git
17:53 chardan joined #git
17:53 dar123 joined #git
17:57 Lipp joined #git
17:58 hahuang61 joined #git
17:59 romerocesar joined #git
17:59 rwb joined #git
18:01 synthroid joined #git
18:02 bronson joined #git
18:03 menip joined #git
18:04 Spec-Chum joined #git
18:06 jnavila joined #git
18:12 str joined #git
18:13 rominronin joined #git
18:14 star_prone joined #git
18:15 joshszep joined #git
18:16 meLon joined #git
18:16 rishi joined #git
18:20 dreiss joined #git
18:21 jnavila joined #git
18:21 tang^ joined #git
18:23 Derderderd joined #git
18:24 dan2k3k4 joined #git
18:25 marc_v92 joined #git
18:25 garethdaine joined #git
18:27 synthroi_ joined #git
18:32 cagedwisdom joined #git
18:33 griffindy joined #git
18:33 flavius joined #git
18:35 Es0teric joined #git
18:35 meLon joined #git
18:36 spacelord_ joined #git
18:37 Limes joined #git
18:38 ajf- joined #git
18:38 nkuttler err, i suddenly get "fatal: Not a git repository (or any parent up to mount point /home)" while in my repository dir. any idea what could cause this?
18:39 nkuttler the .git directory is right there
18:39 nkuttler hm, happens in other repos as well. wth..
18:39 grawity does it have 'config', 'HEAD' files; 'objects', 'refs' directories?
18:39 grawity do you have $GIT_* set in `env`?
18:40 nkuttler yes, no GIT* vars set
18:40 nkuttler seems to happen in both repos i was just working in
18:40 nkuttler but vim also began to misbehave, probably some external problem
18:42 [0xAA] joined #git
18:43 synthroid joined #git
18:43 nkuttler uh oh, i think /home is dying, or something.. bad index sha1 sig
18:43 Noldorin joined #git
18:44 nidr0x joined #git
18:44 garethdaine joined #git
18:44 chardan A hopefully-quick question: I have a commit that I added some changes to that I don't want; however, now there have been several other commits that are ahead of it. If I "git checkout" the old commit and fix it, how do I get my newer changes to 'replay' over it?
18:44 re1 joined #git
18:45 chardan By doing that checkout, I guess I'll be in detached head mode?
18:45 chardan I need it all to ultimately go back into my branch.
18:46 cjohnson can you just revert that other commit?
18:46 lacour joined #git
18:50 chardan cjohnson: I will have to look up what that means, exactly... there are changes inside of that commit that I do want to keep.
18:50 jstein_ joined #git
18:50 chardan cjohnson: Let me read git-revert...
18:50 cjohnson it makes a new commit which is a negative of the old commit
18:51 cjohnson you could revert, then rebase that revert and strip out the negation of the changes you wanted to keep
18:51 chardan cjohnson: That might be just want I want. What will happen with the newer commits?
18:52 chardan cjohnson: Oh, they will be okay after the rebase because they don't depend on the stuff I'm taking out?
18:53 cjohnson sorry rebase maybe wasn't right. I just meant, create the revert, then rewind one commit to keep the revert's working changes but remove it from history
18:53 cjohnson So you have A B C D and then you make a revert of A, called E
18:54 cjohnson now you have A B C D E. so git reset HEAD~1 and you're back to A B C D except the changes from E are applied
18:54 cjohnson so then git add -p .
18:54 cjohnson only stage the reversal of the parts you wanted to undo, don't stage the bits you wanted to keep
18:54 cjohnson commit as E.2
18:54 cjohnson I'm sure there's an easier way but that's how I would do it
18:54 chardan cjohnson: I thiiiink that's probably what I'm after... thank you, I'll read a bit more and give it a go!
18:56 ghoti joined #git
18:58 rishi joined #git
18:59 [cust] joined #git
19:03 Starky joined #git
19:06 vdv joined #git
19:08 Anja joined #git
19:08 svm_invictvs joined #git
19:09 venmx joined #git
19:09 howitdo joined #git
19:09 chardan cjohnson: Hm.... not /quite/ what I wanted, I don't think. I need to actually edit that commit...
19:10 derk0pf joined #git
19:10 marc_v92 joined #git
19:11 chardan cjohnson: But, certainly useful, thanks for pointing it out! I think I'm getting close.
19:11 cjohnson well, have you pushed that branch already?
19:11 cjohnson you can just rebase
19:12 cjohnson if not
19:12 cjohnson rebase interactive has an option to edit one commit
19:12 cjohnson git rebase --interactive yourCommit^
19:12 cjohnson leave all of them pick except the one to edit, change that to edit
19:13 cjohnson this requires force pushing the branch though since it will rewrite all of the subsequent commits
19:13 cjohnson that's why I suggested a revert instead so no rewriting history
19:14 Sasazuka joined #git
19:15 d0nkeyBOB joined #git
19:15 Balliad joined #git
19:16 Derderderd joined #git
19:17 [cust] joined #git
19:17 Neelixx joined #git
19:17 chardan cjohnson: I guess in this particular case I could get away with rewriting history... I'll read a bit more...
19:18 anonymus_ joined #git
19:18 [cust] joined #git
19:18 leeN joined #git
19:20 romerocesar joined #git
19:21 morenoh149 joined #git
19:23 Mannn joined #git
19:24 jrnieder joined #git
19:24 Siegfried joined #git
19:25 nwkj86 joined #git
19:27 orfeo joined #git
19:29 palisaide joined #git
19:31 denisMone joined #git
19:32 _Vi joined #git
19:35 kaldoran joined #git
19:36 duderonomy joined #git
19:36 hahuang61 joined #git
19:37 heroux joined #git
19:38 strugee joined #git
19:38 aidalgol joined #git
19:40 Mobutils joined #git
19:42 m0viefreak joined #git
19:43 marc_v92 joined #git
19:44 rominronin joined #git
19:45 dsantiago joined #git
19:47 ExoUNX joined #git
19:50 multi_io joined #git
19:54 robotroll joined #git
19:55 tinanoo joined #git
20:00 Starky joined #git
20:01 dar123 joined #git
20:01 cagmz joined #git
20:02 bronson joined #git
20:02 Singmyr joined #git
20:03 e14 joined #git
20:05 realg0ld joined #git
20:06 realg0ld Hello all
20:06 gitinfo realg0ld: 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.
20:07 realg0ld I have a special case where I am trying to push the master branch from a bare repo into a non bare remote repo. Tried setting receive.denyCurrentBranch to ignore but still not luck pushing. any help?
20:08 venmx joined #git
20:09 smaudet joined #git
20:09 renlo joined #git
20:10 renlo is there a way to see all large files which are committed?
20:10 renlo someone on my team dun did guf by pushing a large file to github (without git lfs) and I want to know what the file was
20:10 smaudet quick couple of questions: who provides all this nifty bash autocomplete in git? And if I git fetch <someremote> branch1 - will that create a local branch that I can checkout? I'm thinking it would...however it autocompleted to git fetch main my-branch:my-branch
20:11 askb joined #git
20:11 johnmilton joined #git
20:13 e14 joined #git
20:13 vishal smaudet: the git autocompletion is part of git's source, at contrib/completion/ in the tree.
20:13 vishal smaudet: !fetch4
20:13 gitinfo smaudet: [!fetchfour] [pre 1.8.4 only] We recommend against using 'git fetch/pull <remote> <refspec>' (i.e. with branch argument), because it doesn't update the <remote>/<branch> ref. The easy way to fetch things properly is to get everything: 'git fetch' or 'git pull' are sufficient if you have one remote; otherwise we recommend 'git fetch <remote>' (plus 'git merge <remote>/<branch>' if you wanted to pull/merge).
20:13 DrRobotic joined #git
20:13 smaudet vishal: could you explain the ref concept more
20:14 vishal !refspec
20:14 gitinfo [!refspecs] Refspecs are used by fetch/push to *spec*ify which *ref*s to transmit where. They have the form "source:destination". They can be prefixed with a "+" to force the update, possibly displacing existing history. More info: http://jk.gs/git-fetch.html or http://i.qkme.me/3tke7r.jpg
20:14 smaudet or at least which part I would need to familiarize myself with git to do that sort of thing safely
20:14 smaudet cool, thanks
20:14 jccn joined #git
20:17 chardan cjohnson: Thanks again for your help. I'm still not getting anywhere, but I have more things to look at now! Appreciated.
20:18 ruskie joined #git
20:21 Salander27 joined #git
20:21 chardan Does "git reset <filename>" not have an effect during a rebase -i?
20:22 chardan Basically, in my rebase, I want to "un-add" a couple files (changes I don't want) and edit another one (changes I do want).
20:22 pikajude joined #git
20:22 Derderderd joined #git
20:23 WayToDoor joined #git
20:23 renlo is there a way to see what git is actually downloading when you do a git clone
20:24 grawity nope
20:24 e14 joined #git
20:26 crayon joined #git
20:26 ochorocho__ joined #git
20:27 Shentino joined #git
20:28 cdg joined #git
20:29 Balliad joined #git
20:29 paul424_ joined #git
20:30 Akimb joined #git
20:31 jarnos joined #git
20:32 renlo is there a way to see which commit is large?
20:32 renlo because someone made a change, and I have no clue what it was, but now cloning takes forever
20:32 renlo and I want to know what happened
20:33 markand left #git
20:33 renlo someone committed a large file or something
20:35 jimi_sanchez joined #git
20:40 manuelschneid3r joined #git
20:40 paul424 joined #git
20:41 renlo So basically I should make a tool that does this
20:41 johnny56 joined #git
20:42 renlo a tool which finds all of the large files that were committed, who committed them and in which commit, and then also a way to rewrite history by deleting them or something
20:46 SwiftMatt joined #git
20:47 rominronin joined #git
20:47 renlo very talkative bunch here
20:47 renlo good to converse with people
20:47 renlo left #git
20:49 snowkidind joined #git
20:50 cjohnson chardan: git rebase -i yourCommit^
20:50 cjohnson chardan: then go to the commit you want to edit, change the word at the beginning to "edit"
20:50 cjohnson and then exit your editor
20:51 cjohnson at this point, it will be like you went back in time to when that commit was staged
20:51 cjohnson at this point, you can unstage as normal
20:51 diogenese joined #git
20:51 cjohnson then complete your commit and carry on with the rebase
20:52 finalbeta joined #git
20:52 venmx joined #git
20:52 chardan cjohnson: I *think* I did that... then I got a message saying that my branch had diverged, and I should do a git pull... and I think that I just made a mistake.
20:52 chardan Ugh
20:52 qqx cjohnson: When interactive rebase stops for editing a commit it's already completed the new version of that commit.
20:53 finalbeta joined #git
20:53 qqx So those changes can't just be unstaged, and when done you'd generally want to do `git commit --amend`.
20:54 chardan cjohnson: I think I need to take a break. Thanks for the hand!
20:55 devhost_ left #git
20:55 manuelschneid3r joined #git
20:58 jnavila joined #git
20:58 ottanta joined #git
20:59 ottanta how's it going
21:00 snowkidind joined #git
21:01 cjohnson chardan: that message was correct: after rebasing, you had diverged your branch from remote
21:01 cjohnson after rebasing you have to force push to overwrite remote
21:01 cjohnson qqx: wait that doesn't make sense. so changing the word to "edit" next to commitA won't let you edit commitA?
21:03 _ikke_ ottanta: it's going
21:03 ottanta that's good
21:03 ottanta I'm furiously googling for a good way to view all commits and diffs on a file
21:03 qqx cjohnson: It will let you edit it, but you need to do so as if you're doing that right after the commit was made.
21:03 bronson joined #git
21:03 ottanta do you guys know of any like, gui programs that actually make that interactive? I've spent years working with git and am kinda tired of pure cli
21:04 thesha joined #git
21:04 ottanta like it's cool and intuitive to use porcelain but it's been like 10 years I want some cool interactive trees like from cyberpunk movies
21:04 cjohnson qqx: weird
21:05 rominronin joined #git
21:05 cjohnson github ottanta
21:05 ottanta cjohnson: so nothing client-side?
21:05 ottanta that you'd recommend
21:05 qqx cjohnson: Doing it that way helps to preserve the original commit message (if wanted) as well as the author id and timestamp.
21:09 cjohnson ottanta: nope, client side I just use the git cli
21:09 cjohnson qqx: I guess that makes sense. is there a command in rebase that does what I'm talking about?
21:09 cjohnson edit before hand
21:09 qqx No
21:11 howitdo joined #git
21:11 nickabbey joined #git
21:11 rominronin joined #git
21:12 cjohnson could you git reset HEAD~1, make changes, and then commit?
21:12 cjohnson and after committing does that continue the rebase?
21:13 qqx cjohnson: You can use reset, although that will make it difficult to keep (or start with) the original commit message.
21:13 cjohnson right, understood. just trying to figure out how to rebase and modify a commit
21:13 Macaveli joined #git
21:13 cjohnson instead of simply picking,dropping,orsquashing
21:13 nhOmega joined #git
21:13 qqx Committing doesn't automatically continue the rebase, for that you need to use `git rebase --continue` no matter how you make changes to the commit (or even if you don't).
21:14 cjohnson noted
21:16 rorro joined #git
21:16 dreiss joined #git
21:16 rominron_ joined #git
21:17 UTAN_dev joined #git
21:17 swkmh joined #git
21:17 snowkidind joined #git
21:21 FunkyAss joined #git
21:22 lucz joined #git
21:24 nickabbey joined #git
21:29 e14 joined #git
21:29 uub joined #git
21:29 netj joined #git
21:31 WaReZ joined #git
21:31 e14 joined #git
21:35 tmg joined #git
21:40 ersk1ne joined #git
21:41 MillerBoss joined #git
21:41 snowkidind joined #git
21:41 JanC_ joined #git
21:43 ferr1 joined #git
21:45 Starky joined #git
21:45 FSadino joined #git
21:47 orfeo joined #git
21:49 davimore__ joined #git
21:50 mekeor joined #git
21:51 Dougie187 left #git
21:53 jstein_ joined #git
21:58 romerocesar joined #git
22:01 e14 joined #git
22:02 Nilesh_ joined #git
22:02 fk joined #git
22:03 dodobrain joined #git
22:03 Gsham joined #git
22:03 nickabbey joined #git
22:04 Neelixx joined #git
22:04 crayon joined #git
22:07 nikivi joined #git
22:08 buffal0 joined #git
22:10 kfunk joined #git
22:11 NeonSynth joined #git
22:12 neilthereildeil joined #git
22:13 xall joined #git
22:13 neilthereildeil i did a "git pull" from a remote. however, my refs/heads/master is still at some old commit, so when i git checkout, it goes to refs/heads/master
22:13 neilthereildeil how can i update refs/heads/master to point to the latest commit from the remote that i copied?
22:14 osse neilthereildeil: git checkout master; git merge origin/master
22:15 neilthereildeil should i not be doing git pull anymore? should i be running a different command to auto-update master each time?
22:15 Es0teric joined #git
22:15 met joined #git
22:15 sea-gull_ joined #git
22:15 osse neilthereildeil: pull = fetch + merge.  fetch updates all those refs/remotes/origin/blah thingies. the merge after updates the current branch (possibly master)
22:16 osse i don't know what you should be doing. but there's no need to update master if you don't use it for anything
22:16 neilthereildeil osse: then why didnt pull update my master to point to the latest commmit after it was copied from remote?
22:16 cdown joined #git
22:16 osse neilthereildeil: did you have master checked out?
22:16 neilthereildeil not the tip, but i was on master branch
22:17 hdon joined #git
22:17 dreiss joined #git
22:17 hdon hi all :) i checked out a detached head (earlier revision) and now i don't know how to get back to HEAD. i was just about to push to a remote repo. did i just blow away my work?
22:17 sQVe joined #git
22:17 osse neilthereildeil: what does git rev-parse master@{u} saỳ ?
22:18 osse hdon: git checkout somebranch
22:18 neilthereildeil fatal: No upstream configured for branch 'master'
22:18 neilthereildeil i downloaded the whle remote tree to my /tmp, and pulled from there
22:18 osse neilthereildeil: that's why. merge doesn't know what you want to merge with. pull should have said something... git branch -u origin/master master && git pull
22:18 hdon thanks osse
22:20 neilthereildeil is there a way to do all this in 1 branch?
22:21 osse neilthereildeil: if all you ever use is master then do this thing i told you and never thing about it again
22:21 osse neilthereildeil: short answer: no
22:21 neilthereildeil that creates a new branch??
22:21 osse no...
22:21 guardian what's the proper command to run when a submodule changes url? (not necessarily breaking fast forward)
22:21 osse it fixes this error:  fatal: No upstream configured for branch 'master'
22:23 neilthereildeil osse: git branch -u origin/master master
22:23 neilthereildeil error: the requested upstream branch 'origin/master' does not exist
22:23 osse bleh
22:24 osse what does ''git config remote.origin.fetch'' say?
22:25 neilthereildeil nothing
22:25 osse well then
22:25 met left #git
22:25 neilthereildeil i havent configured remotes
22:25 johnville joined #git
22:25 osse then what are you trying to do?
22:25 neilthereildeil i just D/L the remote tree into temp and pull from there every time
22:25 osse what does "D/L the remote tree" mean?
22:25 cjohnson guardian: you changed it in .gitmodules?
22:25 neilthereildeil i am trying to pull changes from a tree that exists on a different machine
22:26 neilthereildeil download
22:26 cjohnson guardian: git submodule sync && git submodule update --init --recursive
22:26 neilthereildeil i download the whole remote repo into /tmp
22:26 osse and how do you download a remote tree?
22:26 neilthereildeil sftp
22:26 osse for pull to work you need to configure a remote
22:26 osse or write git pull <URL> master
22:26 met77 joined #git
22:27 King_Hual joined #git
22:27 neilthereildeil my remote can be the git repo in /tmp
22:27 Rapture joined #git
22:27 osse then clone it somewher eelse
22:27 osse or do you already have two0 repos?
22:28 neilthereildeil nah i cant keep cloning it everytime
22:28 Rapture my git commands appear to be outputting in trace mode, can't for the life of me figure out why or how to make it more along the lines of INFO
22:28 neilthereildeil cuz i have tags in my local tree
22:28 Siegfried joined #git
22:28 cjohnson your remote can be another path on the same filesystem yes neilthereildeil
22:29 neilthereildeil yea so when i pull from it, my master is not updated
22:29 osse neilthereildeil: clone it once properly instead of sftp and everything will work just fine
22:29 neilthereildeil yea i already cloned it the first time
22:29 neilthereildeil and every time since then, i download the repo to /tmp and pull from it
22:29 neilthereildeil but my master points to the wrong commit
22:30 neilthereildeil i wanna fix it to point to the same commit that /tmp's master points to
22:30 osse why won't you just pull instead of dowenload?!!?
22:30 neilthereildeil because i dont have a git server setup on the remote machine
22:30 neilthereildeil im gonna do that soon
22:30 neilthereildeil but havent gotten therer yet
22:30 cjohnson you don't need a special server for pulls
22:31 chardan cjohnson: I just must not understand something important. I now have a whole set of what look to be duplicate commits.
22:31 osse neilthereildeil: then where do you clone from?
22:31 cjohnson chardan: you pulled your remote after rewriting history
22:31 cjohnson chardan: you were supposed to force push after the rebase to overwrite the remote with your now-rewritten history
22:31 neilthereildeil osse: i pulled once in the beinning
22:31 neilthereildeil from /tmp
22:32 neilthereildeil and ever since then, i delete the tmp repo every time, get the new repo via sftp, and pull from it
22:32 FSadino osse: I think you helped me out with my git add -A problem, I can't remember... Just want to thank you, it worked
22:32 cjohnson chardan: at this point you will have to git reset back to the last commit in your rebase (before the original remote commits) and force push that state over top of remote
22:33 MillerBoss joined #git
22:34 chardan cjohnson: I think I see... my rebase altered the local tree and the pull added the changes from that diverging point. I'm going to rewind and then replace the remote. Am I getting it?
22:34 osse neilthereildeil: that should work
22:34 refried_ joined #git
22:34 osse neilthereildeil: so the config commands were run in /tmp? do it in the other repo
22:34 guardian cjohnson: thanks
22:35 neilthereildeil ok
22:35 Gsham joined #git
22:35 neilthereildeil once i set the remote via config, what next?
22:35 chardan cjohnson: Thanks.
22:36 osse neilthereildeil: the other repo that is not /tmp should already have one
22:36 King_Hual joined #git
22:36 neilthereildeil but its still the same problem. once i pull, how can i update refs/heads/master?
22:37 mellernoia joined #git
22:37 osse neilthereildeil: what do the conmmands i asked you to run show??
22:37 osse is master checked out?
22:37 cjohnson chardan: exactly. np
22:38 anth0ny joined #git
22:39 neilthereildeil forgetit. i manually changed .git/refs/heads/master to point to the latest commit i pulled from remote
22:39 cjohnson guardian: if you have an older git you mighth ave to do some manual cleanup steps, this SO outlines them: http://stackoverflow.com/a/19126528
22:39 osse :(
22:40 rwb joined #git
22:41 cjohnson haha neilthereildeil what the hell are you doing? why don't you just clone once and continually pull?
22:41 cjohnson seems like a weird thing you are doing
22:41 neilthereildeil thats what i do
22:41 neilthereildeil i cloned it a couple months ago
22:42 neilthereildeil i cloned what was in tmp
22:42 neilthereildeil and now i just download the whole remote to /tmp and pull each time
22:42 Starky joined #git
22:42 cjohnson ok so why are you needing to update .git manually?
22:42 cjohnson git can pull over ssh/sftp natively
22:43 cjohnson no special server needed
22:43 pelegreno joined #git
22:46 sea-gull_ joined #git
22:46 cjohnson git clone sshuser@ssh-server.com:path/to/repo YourFoo
22:46 cjohnson then git pull in YourFoo will just pull in updates
22:47 osse if the clone is set up properly then pull should Just Work if you already have master checked out
22:47 osse and clones usually are set up properly unless you used special flags while cloning
22:48 aard_ joined #git
22:48 rominronin joined #git
22:49 YuGiOhJCJ joined #git
22:51 Noodlewitt joined #git
22:53 Siegfried joined #git
22:55 theoceaniscool joined #git
22:56 venmx joined #git
22:57 aard__ joined #git
22:57 neilthereildeil cjohnson: if i do it over ssh, it will update local master as well?
22:57 smaudet joined #git
23:00 cjohnson neilthereildeil: git pull will merge the fetched remote master into local master, yes
23:00 neilthereildeil how can i set that up over ssh?
23:01 aard_ joined #git
23:01 cjohnson I showed you above
23:01 fmeerkoetter joined #git
23:01 neilthereildeil and why doesnt it do that when i just point to an FS directory?
23:02 osse can't you just run those config commands and tell what they say :'(
23:02 rwp What controls where git-daemon writes its shallow_XXXXXX file? fatal: Unable to create temporary file '/srv/git/foo.git/shallow_EWTUNx': Permission denied
23:02 cjohnson I don't think you did that. as you said, you don't have any remote defined
23:02 cjohnson lol osse
23:03 rwp I have several installations that work great and --depth 1 works fine. But another one that git-daemon always wants to create a shallow_XXXXXX file but obviously can't due to permissions.
23:03 pingwindyktator joined #git
23:03 hahuang61 joined #git
23:03 pingwindyktator Hello. I want to run 'git diff --exit-code' in a custom git directory. I'm trying 'git --git-dir diff --exit-code' but it gives me  'Not a git repository'
23:03 JackMc joined #git
23:04 pingwindyktator ^ Well, it's 'git --git-dir some/git/dir diff --exit-code'
23:04 bronson joined #git
23:06 osse cjohnson: he has two local repos. one in /tmp that works as a remote and one other.
23:07 rwp pingwindyktator, Are you diff'ing against a file in your local working copy? Or between two objects in the git repository?
23:08 Mobutils joined #git
23:08 rwp pingwindyktator, You might try using GIT_DIR=some/git/dir git diff --stuffhere and see if that handles your case better.
23:08 snowkidind joined #git
23:09 pingwindyktator rwp: git diff gives me information about diff between working dir and remote branch. I want to run 'git diff' in custom directory, not in my present one
23:09 xaviergmail joined #git
23:10 chachasmooth joined #git
23:10 Charliechin joined #git
23:10 pingwindyktator rwp, it works, thank you ;)
23:10 rwp pingwindyktator, Try the "GIT_DIR=/path/to/repository git diff ..." method and see if that handles your case.
23:10 rwp Oh good!
23:11 osse pingwindyktator, rwp: FYI: if you use --git-dir Git will still assume the current directory is the work tree
23:11 osse maybe you want -C ?
23:11 venmx joined #git
23:11 rwp If you ever need to cd to the other directory momentarily then use a subshell. (cd /some/path && GIT_DIR=/some/repos git command) All parts can be customized.
23:12 mand0 joined #git
23:12 rwp Yes, I think -C should behave the same too. Noting that -C needs to be passed to the "git" part and not to the "git-diff" part.
23:13 osse -C is exactly like cd'ing first
23:13 osse fairly literally, in fact. it makes git use chdir() early on
23:13 rwp (Often the option processing confuses people who are used to putting all options at the far right.  Darn ms-windows influence.)
23:13 aard__ joined #git
23:13 m0viefreak joined #git
23:13 pingwindyktator 'cd'ing first' was exactly what I wanted to do, but in more elegant way than 'cd /some/git/dir; git dif....'
23:14 rwp osse if you know the internals do you know about my earlier question about --depth 1 and git-daemon trying to create shallow_XXXXXX in the repository and failing?
23:14 osse oh really? I've heard "fuckin GNU people" when I write stuff like 'tar files -xf file'
23:14 osse pingwindyktator: in that case -C is definitely what you want
23:15 osse rwp: sorry, no clue. i don't know much about *those* interals :p
23:15 JackMc left #git
23:15 rwp MS-Windows requires their /options to be at the fart right. Which is why the GNU getopt processor added that as a feature.
23:15 osse ooohh
23:15 xaviergmail joined #git
23:15 rwp Me being a long time Unix hacker likes options they way they were always intended, left to right.
23:15 osse you mean the *other* right !
23:15 osse i misunderstood
23:16 rwp It confuses people when an option it needs to be between the git and diff parts.
23:16 osse somewhat understandable
23:17 aard_ joined #git
23:17 rwp When it comes to tar I never use that new fangled dash that is now allowed there.
23:17 osse that said the whole thing could have been 'git --diff' from the outset :p
23:17 rwp But originally it was git-diff from the outset. The git diff I thought was just to reduce the number of commands in /usr/bin.
23:17 Siegfried joined #git
23:18 rwp Oh well.  More time browsing through the source code of git-daemon for me.
23:19 rwp I have several systems where git:// and the git-daemon handle clone --depth 1 just fine. But one system it fails trying to create shallow_XXXXXX in the repository directory.
23:19 rwp Which of course I haven't given it permissions (nobody) to write to. And I don't intend to.
23:19 rwp But I can't figure out what is different between the two systems.  Identical versions of git on both.
23:20 osse i haven't really played around much with shallow clones.
23:20 Starky joined #git
23:20 osse Either download more free space, or use git archive to obtain a tar ball :p
23:20 joki joined #git
23:20 rwp I personally have not much either. But other people want it to work. And they have a point when it is a large repository. So I am trying to make it work.
23:21 osse they can be quite taxing on the server, though.
23:21 * rwp drops afk for a bit...
23:21 Anja joined #git
23:22 osse https://github.com/CocoaPods/CocoaPods/issues/4989#issuecomment-193772935
23:23 spacelord_ joined #git
23:23 ParkerR left #git
23:23 rorro joined #git
23:25 jccn joined #git
23:27 refried_ joined #git
23:29 jimi_ joined #git
23:30 morenoh149 joined #git
23:30 f0rks joined #git
23:31 cagedwisdom joined #git
23:32 tsteinholz joined #git
23:38 inflames joined #git
23:38 Sample joined #git
23:39 star_prone joined #git
23:40 dsantiago joined #git
23:41 Tatou joined #git
23:42 Tatou If I am using multiple git servers (github and work one)
23:42 Tatou Is there a good way to specify different name +email based on the hostname?
23:43 preaction no, especially since that info is baked into the commit
23:43 preaction you can set those on a per-repo basis though, using git config
23:43 osse Tatou: not very straight forward. remove the email from your global commit and set it per reo
23:43 Tatou Will have to try that. I've just found my github commits attributed to some random person because of my config -_-
23:44 osse Tatou: git config --global --unset user.email && git config user.email Tatou@gmail.com
23:44 Tatou Thanks osse :-)
23:45 anonymuse joined #git
23:45 Tatou I am loving this git thing. It's so nice as a quic backup of files as well
23:45 osse Tatou: you can, if you wish, have a git() shell wrapper that sets the correct email when you clone or something... but git will remind you once it needs it so i personally haven't bothered
23:46 Tatou Oh yea
23:46 Tatou Fair enough. I'll end up removing the global then
23:47 osse Tatou: i had this lying around... http://sprunge.us/RiON
23:48 marc_v92 joined #git
23:49 Vampire0 Tatou, that's also how I do it, not having user.email set globally but per repo and then decide after first commit when it complains which e-mail I want for this repo
23:49 Vampire0 Works great
23:52 umpc joined #git
23:59 nd joined #git

| Channels | #git index | Today | | Search | Google Search | Plain-Text | summary