| 2020-09-22 |
|
sybariten
| and actually, what should i correctly call this newest repo at bitbucket | 00:01 |
|
rewt
| sybariten: `git fetch` to fetch commits that the remote has that you don't | 00:02 |
|
sybariten
| uh... i'm not sure it did something.... i mean it didnt ask for PW , which i would have expected | 00:05 |
|
| hm wait i'm stupid , this repo specificcally, is public... hm | 00:06 |
| ← tiin57 left | 00:12 |
| ← perrier-jouet left | 00:15 |
| → tiin57 joined | 00:15 |
| → perrier-jouet joined | 00:16 |
|
sybariten
| no rewt i can't really see it happening ... i'm checking against the bitbucket site, the files there are different than what i have in my local dir here | 00:16 |
|
rewt
| what does git status say? | 00:17 |
|
| and are you looking at the same branch? | 00:17 |
| ← Gurkenglas left | 00:19 |
| ← yokoyamachan left | 00:21 |
| ← blahboybaz left | 00:22 |
| → nvmd joined | 00:22 |
| → fstd_ joined | 00:23 |
|
sybariten
| hm, as far as i know i only have one branch.... isn that a slightly more advanced feature of git? Let me try git status | 00:24 |
|
| aaah okay, now git status says i'm behind with 8 commits... so i should do git pull? | 00:24 |
|
rewt
| `git pull` is the same as `git fetch` followed by `git merge`, and since you've already done fetch, you can do just merge | 00:25 |
|
sybariten
| kind of confusing to me that the actual command git fetch itself, never said "you're behind with 8 commits" ... but that i have to do git status. But this is probably logical with how git works. | 00:25 |
| ← lankanmon left | 00:25 |
| ← arcatech left | 00:26 |
| ← fstd left | 00:27 |
| fstd_ → fstd | 00:27 |
|
sybariten
| ok yeah that worked fine, thank you rewt ! | 00:27 |
| → th_ joined | 00:31 |
| ← mowcat left | 00:36 |
| ← Aki-lucky left | 00:37 |
| → arcatech joined | 00:39 |
| ← tiin57 left | 00:42 |
| ← flex14 left | 00:44 |
| → tiin57 joined | 00:45 |
| → cupstudio joined | 00:52 |
|
cupstudio
| Hi... this might be a dumb question, because I haven't been able to find an answer using google. | 00:52 |
|
| When I merge my development branch into master, master gets a merge commit | 00:53 |
|
| Then it looks like develop is behind master - should I update develop from master and bring the merge commit in? That seems odd... | 00:53 |
|
| maybe I'm just expecting the two branches to be equal and they won't ever be | 00:54 |
| ← Betal left | 00:57 |
| ← andreas303 left | 00:59 |
| → Betal joined | 00:59 |
| → andreas303 joined | 01:03 |
| → Xenguy joined | 01:04 |
| ← mozgalom left | 01:04 |
| → inkbottle joined | 01:06 |
| ← kilobyte_ch left | 01:06 |
| ← maxzor left | 01:06 |
| → mozgalom joined | 01:07 |
| ← zebrag left | 01:08 |
| ← tiin57 left | 01:12 |
| ← dfee left | 01:14 |
| → tiin57 joined | 01:16 |
| ← POQDavid left | 01:18 |
| → POQDavid joined | 01:19 |
| ← mindCrime_ left | 01:19 |
| → kilobyte_ch joined | 01:20 |
| ← F0rTex left | 01:20 |
| → F0rTex joined | 01:22 |
| ← aw1 left | 01:24 |
| ← kerframil left | 01:31 |
| ← dionysus69 left | 01:36 |
| → macrover joined | 01:38 |
| → greggerz joined | 01:41 |
| ← tiin57 left | 01:42 |
| ← vicfred left | 01:42 |
| → flex14 joined | 01:45 |
| → tiin57 joined | 01:46 |
| ← inkbottle left | 01:47 |
| ← heyitsrama left | 01:47 |
| ← mozgalom left | 01:47 |
| → inkbottle joined | 01:47 |
| ← flex14 left | 01:47 |
| Shentino_ → Shentino | 01:48 |
| → flex14 joined | 01:48 |
| ← flex14 left | 01:51 |
| → flex14 joined | 01:51 |
| ← andreas303 left | 01:52 |
| → kerframil joined | 01:52 |
| → yonder joined | 01:52 |
| → andreas303 joined | 01:54 |
| ← gast0n left | 01:55 |
| ← flex14 left | 01:55 |
| → flex14 joined | 01:55 |
| ← flex14 left | 01:59 |
| → flex14 joined | 01:59 |
| → lankanmon joined | 02:00 |
| → mns joined | 02:00 |
| → heyitsrama joined | 02:04 |
| ← mns left | 02:04 |
| → gschanuel9 joined | 02:08 |
| ← gschanuel left | 02:11 |
| gschanuel9 → gschanuel | 02:11 |
| ← tiin57 left | 02:12 |
| ← cupstudio left | 02:13 |
| → tiin57 joined | 02:15 |
| ← heyitsrama left | 02:16 |
| ← macrover left | 02:18 |
| → dastan joined | 02:18 |
| → Muimi joined | 02:20 |
| ← tryte left | 02:21 |
| ← oprypin left | 02:21 |
| → tryte joined | 02:21 |
| → raven-au_ joined | 02:21 |
| ← raven-au left | 02:21 |
| raven-au_ → raven-au | 02:21 |
| → Wetmelon joined | 02:22 |
| ← bdeferme_ left | 02:22 |
| → oprypin joined | 02:23 |
| → Fusl joined | 02:25 |
| → bdeferme_ joined | 02:25 |
| → Xenguy_ joined | 02:27 |
| ← Xenguy left | 02:27 |
| ← Kaisyu7 left | 02:30 |
| ← lagothrix left | 02:31 |
| → lagothrix joined | 02:31 |
| ← greggerz left | 02:35 |
| Xenguy_ → Xenguy | 02:37 |
| → yamashitatan joined | 02:38 |
| → macrover joined | 02:38 |
| ← cuppajoeman left | 02:39 |
| → Kaisyu7 joined | 02:39 |
| ← tiin57 left | 02:42 |
| ← pikapika left | 02:43 |
| ← macrover left | 02:43 |
| ← acetakwas left | 02:43 |
| → pikapika joined | 02:43 |
| ← POQDavid left | 02:43 |
| → acetakwas joined | 02:44 |
| → POQDavid joined | 02:44 |
| → dimi1947 joined | 02:45 |
| → tiin57 joined | 02:45 |
| → crose joined | 02:46 |
| ← Jookia left | 02:49 |
| → Jookia joined | 02:49 |
| ← acetakwas left | 02:51 |
| ← justanotheruser left | 02:51 |
| → acetakwas joined | 02:52 |
| ← Cabanoss- left | 02:53 |
| → Goplat joined | 02:55 |
| ← acetakwas left | 02:56 |
| → Cabanossi joined | 02:58 |
| → acetakwas joined | 02:58 |
| → snowkidimd joined | 02:59 |
| ← davispuh left | 03:03 |
| ← arcatech left | 03:05 |
| ← nikivi left | 03:06 |
| → nikivi joined | 03:06 |
| ← tiin57 left | 03:12 |
| ← wallace_mu left | 03:12 |
| → tiin57 joined | 03:15 |
| ← kerframil left | 03:18 |
| ← relipse left | 03:21 |
| → kerframil joined | 03:34 |
| ← AnAverageHuman left | 03:36 |
| → veegee joined | 03:37 |
| → blahboybaz joined | 03:42 |
| ← tiin57 left | 03:42 |
| ← yamashitatan left | 03:44 |
| → tiin57 joined | 03:45 |
| → vicfred joined | 03:46 |
|
igemnace
| you can expect them to be equal if a) you bring the merge commit back into develop (like you said), or b) if you forgo having the merge commit at all (e.g. a fast forward) | 03:47 |
|
| some shops do b). they rebase all their branches onto master to make sure it's cleanly fast-forwardable every time. it depends on what your team values out of the VCS | 03:48 |
|
| oh... he's not even here | 03:48 |
| → milkt joined | 03:52 |
| ← flex14 left | 03:54 |
| → macrover joined | 03:54 |
| ← iNs left | 04:03 |
| → iNs joined | 04:04 |
| ← thomasross left | 04:04 |
| → dfee joined | 04:05 |
| ← ninjin_ left | 04:06 |
| → ninjin_ joined | 04:06 |
| ← pac1_ left | 04:08 |
| ← donofrio left | 04:10 |
| ← tiin57 left | 04:12 |
| → heyitsrama joined | 04:12 |
| → tiin57 joined | 04:15 |
| ← veegee left | 04:22 |
| ← dfee left | 04:26 |
| → arcatech joined | 04:26 |
| ← jaziz left | 04:27 |
| ← fuzzmz left | 04:29 |
| → fuzzmz joined | 04:29 |
| ← rnsanchez left | 04:30 |
| ← vngx left | 04:30 |
| ← dastan left | 04:39 |
| → dastan joined | 04:39 |
| ← tiin57 left | 04:42 |
| → Newami joined | 04:43 |
| → tiin57 joined | 04:45 |
| ← corelax left | 04:45 |
| ← Newami left | 04:46 |
| ← vicfred left | 04:47 |
| ← heyitsrama left | 04:49 |
| ← macrover left | 04:54 |
| → corelax joined | 04:55 |
| ← dastan left | 04:56 |
| ← corelax left | 04:59 |
| ← FH_thecat left | 05:00 |
| → vicfred joined | 05:02 |
| → justanotheruser joined | 05:07 |
| → corelax joined | 05:10 |
| ← tiin57 left | 05:12 |
| → hexnewbie joined | 05:14 |
| → tiin57 joined | 05:14 |
| ← snowkidimd left | 05:14 |
| ← arcatech left | 05:22 |
| ← corelax left | 05:22 |
| → duderonomy joined | 05:22 |
| → corelax joined | 05:22 |
| → dfee joined | 05:23 |
| ← inkbottle left | 05:29 |
| → konrados joined | 05:37 |
| ← tiin57 left | 05:42 |
| → tiin57 joined | 05:45 |
| ← konrados left | 05:46 |
| → konrados joined | 05:49 |
| → theoceaniscool joined | 05:49 |
| ← blahboybaz left | 05:50 |
| ← kupi left | 06:02 |
| ← terabyte left | 06:03 |
| → mightyjens joined | 06:07 |
| → mirrorbird joined | 06:08 |
| ← tiin57 left | 06:12 |
| → qpdb joined | 06:13 |
| → tiin57 joined | 06:16 |
| ← kjartan left | 06:22 |
| → kjartan joined | 06:23 |
| ← lankanmon left | 06:25 |
| → tarkus joined | 06:26 |
| ← tryte left | 06:28 |
| → rfuentess joined | 06:28 |
| → tryte joined | 06:28 |
| ← nvmd left | 06:34 |
| ← tpaper left | 06:35 |
| → tpaper joined | 06:37 |
| ← independent left | 06:38 |
| ← HourGate left | 06:39 |
| → independent joined | 06:39 |
| → lankanmon joined | 06:41 |
| ← tiin57 left | 06:42 |
| ← kjartan left | 06:42 |
| → morfin joined | 06:44 |
|
morfin
| hello. How can i change old unpushed commit? | 06:45 |
| → tiin57 joined | 06:46 |
|
morfin
| seems like i need to rebase? | 06:47 |
| ← LordRyan left | 06:47 |
| → kjartan joined | 06:48 |
| → benfelin joined | 06:48 |
| → maxzor joined | 06:48 |
| → a-l-e joined | 06:49 |
|
selckin
| 'interactive rebase' is the magic keyword | 06:49 |
|
morfin
| sounds scary | 06:50 |
| ← mirrorbird left | 06:50 |
|
selckin
| as all things git are initially | 06:51 |
|
| but its quite simple | 06:51 |
| ← Wetmelon left | 06:52 |
| ← thiago left | 07:01 |
| ← unluckyshrubbery left | 07:02 |
| ← kjartan left | 07:04 |
| → FH_thecat joined | 07:06 |
| ← sgn left | 07:11 |
| ← durham left | 07:11 |
| ← tiin57 left | 07:12 |
| ← Xenguy left | 07:13 |
| → jaziz joined | 07:13 |
| → tiin57 joined | 07:15 |
| → kjartan joined | 07:17 |
| → Anticom joined | 07:21 |
| ← Hello71 left | 07:22 |
| ← yonder left | 07:22 |
| → Hello71 joined | 07:22 |
| → chele joined | 07:24 |
| → sgn joined | 07:25 |
| → leeN joined | 07:25 |
| ← Goplat left | 07:28 |
| ← leeN left | 07:29 |
| → zillolo joined | 07:37 |
| ← tiin57 left | 07:42 |
| → oxymoron93 joined | 07:43 |
| → tiin57 joined | 07:45 |
| → wrobinson joined | 07:50 |
| ← wrobinso1 left | 07:52 |
| ← Mattiaslndstrm left | 07:56 |
| → PJBoy joined | 07:57 |
| → dermoth_ joined | 08:03 |
| ← dermoth left | 08:03 |
| dermoth_ → dermoth | 08:03 |
| ← cd left | 08:04 |
| ← zumba_addict left | 08:08 |
| ← cyphase left | 08:08 |
| ← tiin57 left | 08:12 |
| ← mir100 left | 08:13 |
| → tiin57 joined | 08:15 |
| ← benfelin left | 08:19 |
| ← dimi1947 left | 08:20 |
| ← duderonomy left | 08:27 |
| → Tawonga joined | 08:29 |
| → unluckyshrubbery joined | 08:30 |
| → cyphase joined | 08:31 |
| ← hussam left | 08:34 |
| → duderonomy joined | 08:36 |
| ← lankanmon left | 08:38 |
| ← tiin57 left | 08:42 |
| → lankanmon joined | 08:42 |
| → tiin57 joined | 08:45 |
| ← Furai left | 08:46 |
| → Noti joined | 08:47 |
| → LordRyan joined | 08:58 |
| → mozgalom joined | 08:58 |
| → Furai joined | 08:59 |
| ← cerna left | 09:00 |
| → calcul0n joined | 09:07 |
| → OnkelBlade joined | 09:09 |
| → neverwas joined | 09:09 |
| ← tiin57 left | 09:11 |
| ← cdown left | 09:13 |
| → Lucas_Gray joined | 09:14 |
| → tiin57 joined | 09:15 |
| → cdown joined | 09:15 |
| → cdown_ joined | 09:17 |
| ← Jookia left | 09:18 |
| ← tubaman left | 09:18 |
| → Jookia joined | 09:19 |
| ← cdown left | 09:20 |
| cdown_ → cdown | 09:20 |
| → mobidrop joined | 09:25 |
| → dionysus69 joined | 09:27 |
| ← DiffieHellman left | 09:31 |
| → cosimone joined | 09:32 |
| ← opal left | 09:35 |
| ← Betal left | 09:36 |
| → mirrorbird joined | 09:37 |
| → opal joined | 09:37 |
| → feriman joined | 09:39 |
| ← tiin57 left | 09:42 |
| ← EvanCarroll left | 09:44 |
| ← dhollinger left | 09:44 |
| ← Guest20 left | 09:44 |
| → tiin57 joined | 09:45 |
| → EvanCarroll joined | 09:45 |
| → dhollinger joined | 09:45 |
| → Guest20 joined | 09:48 |
| → benfelin joined | 09:52 |
| ← maxzor left | 09:57 |
| → maxzor joined | 09:58 |
| ← howdoi left | 10:00 |
| ← flowinho left | 10:01 |
| → flowinho joined | 10:01 |
| ← sunri5e left | 10:04 |
| → sunri5e joined | 10:05 |
| → Mattiaslndstrm joined | 10:05 |
| → flex14 joined | 10:08 |
| → calcul0n_ joined | 10:08 |
| ← sunri5e left | 10:10 |
| ← nickmass left | 10:10 |
| → sunri5e joined | 10:11 |
| ← calcul0n left | 10:11 |
| ← tiin57 left | 10:11 |
| → nickmass joined | 10:12 |
| → tiin57 joined | 10:15 |
| → Tobbi_1 joined | 10:16 |
|
selckin
| any way to make git stash show, list new files? | 10:19 |
| ← Tobbi_ left | 10:19 |
| Tobbi_1 → Tobbi_ | 10:19 |
| → jast joined | 10:19 |
| ← BtbN left | 10:19 |
| → BtbN joined | 10:20 |
|
osse
| selckin: what do you mean, exactly? make them stand out from the rest? | 10:21 |
|
| you can use --diff-filter=A to filter the rest out | 10:21 |
|
selckin
| doesn't show them either, maybe i changed some default, talking about, echo foo > bar; git stash -u; git stash show # always empty no mather the options i can find to pass | 10:23 |
| ← acetakwas left | 10:25 |
|
osse
| huh | 10:25 |
| ← POQDavid left | 10:25 |
|
osse
| weird implementation | 10:25 |
| ← pikapika left | 10:25 |
|
osse
| the untracked files are stored in a separate object | 10:25 |
| → POQDavid joined | 10:25 |
| → pikapika joined | 10:25 |
|
osse
| selckin: try this: git log --graph HEAD..stash | 10:26 |
| → acetakwas joined | 10:26 |
| ← Noti left | 10:26 |
| → benyoo joined | 10:27 |
|
osse
| git ls-tree stash^3 | 10:27 |
|
selckin
| aliasing the log graph then, thanks! | 10:28 |
|
osse
| better: git log --graph HEAD~..stash | 10:28 |
|
| one commit was missing | 10:28 |
|
ikke
| It makes sense untracked objects are stored seperately | 10:28 |
| ← Tobbi_ left | 10:28 |
|
ikke
| You don't want them end up in the index | 10:29 |
| → Gurkenglas joined | 10:29 |
| → vngx joined | 10:29 |
|
osse
| agreed, but it would also make sense for git stash show to show them | 10:29 |
| → ehostunreach joined | 10:30 |
|
osse
| git stash show should show what was stashed, regardless of impl details, imo | 10:30 |
| ← la_croix left | 10:30 |
| → Tobbi_ joined | 10:31 |
| → p-core joined | 10:31 |
| → la_croix joined | 10:33 |
| ← tiin57 left | 10:42 |
| → tgunr joined | 10:42 |
| → minhaj-sixbyte joined | 10:43 |
| ← minhaj-sixbyte left | 10:43 |
| ← flex14 left | 10:43 |
| → Guest20_ joined | 10:44 |
| → minhaj-sixbyte joined | 10:44 |
| ← minhaj-sixbyte left | 10:44 |
| → tiin57 joined | 10:45 |
| → minhaj-sixbyte joined | 10:45 |
| ← Guest20 left | 10:45 |
| ← minhaj-sixbyte left | 10:45 |
| → cdown_ joined | 10:46 |
|
selckin
| agree! | 10:47 |
| ← impermanence left | 10:48 |
|
osse
| selckin: git diff --diff-filter=A --name-only stash~ stash^3 | 10:48 |
|
| BAM | 10:48 |
| ← cdown left | 10:48 |
| cdown_ → cdown | 10:48 |
|
selckin
| what does stash^3 mean here | 10:50 |
|
| oh the other object | 10:50 |
| ← oatmealraisin left | 10:51 |
|
osse
| third parent of the stash commit | 10:52 |
|
| it only exists if there are untracked files | 10:52 |
| ← kjartan left | 10:54 |
| ← chele left | 11:04 |
| → chele joined | 11:04 |
| → kjartan joined | 11:05 |
| → mat001_ joined | 11:08 |
| → Noti joined | 11:08 |
| ← mat001 left | 11:09 |
| ← tiin57 left | 11:12 |
| ← mirrorbird left | 11:14 |
| → tiin57 joined | 11:15 |
| ← Muimi left | 11:17 |
| ← kerframil left | 11:18 |
| ← mgedmin left | 11:22 |
| → mgedmin joined | 11:25 |
| → cdown_ joined | 11:26 |
| ← p-core left | 11:26 |
| → p-core joined | 11:27 |
| ← splud left | 11:27 |
| ← Guest20_ left | 11:28 |
| ← cdown left | 11:29 |
| cdown_ → cdown | 11:29 |
| → SteffanW joined | 11:32 |
| → splud joined | 11:33 |
| ← Noti left | 11:33 |
| → cuppajoeman joined | 11:38 |
| ← magic_ninja left | 11:41 |
| ← tiin57 left | 11:42 |
| → magic_ninja joined | 11:43 |
| ← benyoo left | 11:45 |
| → benyoo joined | 11:45 |
| ← p-core left | 11:45 |
| → tiin57 joined | 11:46 |
| → oatmealraisin joined | 11:50 |
| ← kjartan left | 11:51 |
| ← benyoo left | 11:51 |
| ← mijndert left | 11:52 |
| ← la_croix left | 11:53 |
| → mijndert joined | 11:53 |
| ← theoceaniscool left | 11:54 |
| → la_croix joined | 11:54 |
| → kjartan joined | 11:55 |
| ← flowinho left | 11:56 |
| → flowinho joined | 11:57 |
| ← ehostunreach left | 11:57 |
| ← kjartan left | 12:00 |
| → kjartan joined | 12:07 |
| ← tiin57 left | 12:11 |
| → tiin57 joined | 12:15 |
| ← tarkus left | 12:17 |
| ← igemnace left | 12:18 |
| → igemnace joined | 12:20 |
| ← Kaivo left | 12:26 |
| ← dqx_ left | 12:27 |
| ← cheater left | 12:34 |
| ← milkt left | 12:35 |
| → milkt joined | 12:35 |
| → flex14 joined | 12:36 |
| ← la_croix left | 12:36 |
| ← jaziz left | 12:37 |
| → la_croix joined | 12:39 |
| ← nikivi left | 12:40 |
| ← acetakwas left | 12:40 |
| ← POQDavid left | 12:40 |
| ← pikapika left | 12:41 |
| → POQDavid joined | 12:41 |
| → acetakwas joined | 12:41 |
| → pikapika joined | 12:41 |
| → nikivi joined | 12:41 |
| ← tiin57 left | 12:41 |
| ← acetakwas left | 12:42 |
| ← pikapika left | 12:43 |
| → acetakwas joined | 12:43 |
| → pikapika joined | 12:45 |
| → tiin57 joined | 12:45 |
| → Maxattax joined | 12:47 |
| → impermanence joined | 12:48 |
| ← POQDavid left | 12:49 |
| ← pikapika left | 12:49 |
| → POQDavid joined | 12:49 |
| → pikapika joined | 12:50 |
| ← nikivi left | 12:51 |
| → nikivi joined | 12:51 |
| ← kjartan left | 12:52 |
| ← nikivi left | 12:52 |
| ← acetakwas left | 12:53 |
| → nikivi joined | 12:53 |
| → acetakwas joined | 12:53 |
| → kjartan joined | 12:53 |
| ← pikapika left | 12:55 |
| → pikapika joined | 12:56 |
| → Wetmelon joined | 12:58 |
| ← DarthRadar left | 13:06 |
| → ttl joined | 13:07 |
| → mowcat joined | 13:09 |
| → Xenguy joined | 13:10 |
| ← Xenguy left | 13:10 |
| ← tiin57 left | 13:12 |
| → tiin57 joined | 13:15 |
| → nvmd joined | 13:16 |
| → CodeSlingerPaul joined | 13:18 |
| → Muimi joined | 13:25 |
| ← ghost43 left | 13:28 |
| → donofrio joined | 13:28 |
| ← opal left | 13:31 |
| → ghost43 joined | 13:31 |
| → opal joined | 13:32 |
| → sudoforge joined | 13:36 |
| ← dhollinger left | 13:37 |
| → dhollinger joined | 13:41 |
| ← tgamblin left | 13:41 |
| ← tiin57 left | 13:42 |
| ← Lucas_Gray left | 13:43 |
| → theoceaniscool joined | 13:44 |
| → LionsMane joined | 13:45 |
| → tiin57 joined | 13:45 |
| → thijso joined | 13:48 |
| ← OnkelBlade left | 13:49 |
| → OnkelBlade joined | 13:50 |
| → mns joined | 13:51 |
| → p-core joined | 13:52 |
| → macrover joined | 13:54 |
| ← epoll left | 13:54 |
| → epoll joined | 13:55 |
| → thiago joined | 13:55 |
| ← impermanence left | 13:57 |
| → haymawk joined | 13:57 |
| → rafasc joined | 14:06 |
| ← tiin57 left | 14:12 |
| ← kjartan left | 14:14 |
| → tiin57 joined | 14:15 |
| → kjartan joined | 14:18 |
| ← macrover left | 14:22 |
| ← p-core left | 14:22 |
| → Aki-lucky joined | 14:23 |
| ← mns left | 14:23 |
| → hussam joined | 14:24 |
| → gast0n joined | 14:26 |
| → rak joined | 14:28 |
|
rak
| Is there an environment variable or equivalent that I can rely on in git hooks that points to GIT_DIR? AFAICT, GIT_DIR isn't set when hooks run | 14:28 |
|
| I just want to know what the root/base directory for the git repo is. | 14:29 |
| ← OnkelBlade left | 14:29 |
| → irc_user joined | 14:30 |
| → OnkelBlade joined | 14:30 |
|
osse
| rak: if the repo is bare then GIT_DIR is simply the current directory | 14:31 |
|
rafasc
| rak: git rev-parse has a couple of --options, like | 14:31 |
| → Lucas_Gray joined | 14:31 |
|
osse
| otherwise, yeah that thing | 14:31 |
| → impermanence joined | 14:31 |
|
rafasc
| git rev-parse --git-dir, for example. | 14:31 |
| → relipse joined | 14:34 |
| → AnAverageHuman joined | 14:35 |
| → tgamblin joined | 14:38 |
|
rak
| rev-parse does the trick. Thanks all! | 14:38 |
| → mns joined | 14:38 |
| ← tiin57 left | 14:41 |
| ← benfelin left | 14:42 |
| ← mowcat left | 14:43 |
| → greggerz joined | 14:43 |
| ← konrados left | 14:43 |
| → tiin57 joined | 14:45 |
| → iffraff joined | 14:47 |
|
iffraff
| Hi, when I do a git log, I see all the commits sorted by date. However for commits that were merged in, the date seems to be ... well I think it's the date the commit got merged into the current branch or into master. Not the date that it was created. So I kind of loose the real time line | 14:49 |
|
| a) is this true :) b) if so is there a way to see the created date stamp? | 14:50 |
|
rafasc
| git log --author-date-order | 14:50 |
| ← sweatsuit left | 14:50 |
| ← AnAverageHuman left | 14:51 |
|
rafasc
| it's also a good idea to use something like !lol | 14:51 |
|
gitinfo
| A nifty view of branches, tags, and other refs: git log --oneline --graph --decorate --all | 14:51 |
|
rafasc
| So you can see the topological relation between commits. | 14:51 |
| → Ironman3000 joined | 14:52 |
|
Ironman3000
| Hi, does anyone here use BitBucket and knows how to create a pull request on the linux CLI? | 14:52 |
|
iffraff
| sweeet! thanks folks! | 14:54 |
| → arcatech joined | 14:56 |
|
rafasc
| Ironman3000: there's probably something out there, but it's only possible if the 3rd party provides a api for it. | 14:57 |
|
| https://community.atlassian.com/t5/Bitbucket-questions/Re-How-do-I-create-a-pull-request-from-the-command-line/qaq-p/585738/comment-id/16408#M16408 | 14:57 |
|
| this seems the closest I could find googling "bitbucket merge request cli" | 14:57 |
|
Ironman3000
| thanks | 14:58 |
|
rafasc
| https://stackoverflow.com/questions/8721730/bitbucket-send-a-pull-request-via-command-line/15046966#15046966 | 14:58 |
| ← iffraff left | 14:59 |
| ← flex14 left | 14:59 |
| → sweatsuit joined | 15:02 |
| ← tgamblin left | 15:03 |
| ← SteffanW left | 15:11 |
| ← tiin57 left | 15:12 |
| ← OnkelBlade left | 15:12 |
|
osse
| !hub | 15:13 |
|
gitinfo
| Hub is a wrapper around git which provides specific github features to the git cli. See https://github.com/github/hub for details. | 15:13 |
|
osse
| hmm | 15:13 |
|
| !spindle | 15:13 |
|
gitinfo
| [!git-spindle] https://github.com/seveas/git-spindle is a handy tool to use the features of GitHub (and GH Enterprise), GitLab, BitBucket and possibly more from the command line. | 15:13 |
|
osse
| Ironman3000: see above | 15:14 |
| → tiin57 joined | 15:15 |
|
shailangsa
| anybody know why "error.GitError: None: remote omnirom does not have refs/heads/android-8.1" appears when trying to sync the repo using the 8.1 branch for the minimal twrp manifest using "repo init --depth=1 -u git://github.com/minimal-manifest-twrp/platform_manifest_twrp_omni.git -b twrp-8.1" , https://pastebin.com/qg1a4wr6 ? | 15:16 |
| ← oxymoron93 left | 15:17 |
|
osse
| Where is Seveas anyway | 15:17 |
| ← a-l-e left | 15:20 |
|
ikke
| Last message was end of Augus | 15:20 |
| ← mightyjens left | 15:21 |
| ← zillolo left | 15:21 |
| ← chele left | 15:21 |
| → AnAverageHuman joined | 15:21 |
| ← Lucas_Gray left | 15:23 |
| ← mobidrop left | 15:23 |
| → Lucas_Gray joined | 15:26 |
| → mir100 joined | 15:28 |
| ← mns left | 15:31 |
| → hiro joined | 15:31 |
|
hiro
| ok hello everybody. huge channel i see :D | 15:32 |
|
| this problem keeps on coming up for me: https://stackoverflow.com/questions/6155359/git-diff-ignore-renaming-of-variables | 15:32 |
|
| and i waste a lot of time doing either 1) sed -i 's/newname/oldname/' * */* */*/*; git checkout -b oldnames; commit -a; git diff mainbranch oldnames | 15:33 |
|
| or 2) the answer from stackoverflow (git diff | egrep -v 'oldName|newName' | egrep '^[+-]') | 15:33 |
| → tgamblin joined | 15:34 |
|
hiro
| 2) is a bit limited bec. it drops also commits where on one line the variable name got changed in *addition* to another change that i actually would like to see | 15:34 |
| ← greggerz left | 15:35 |
|
hiro
| i hope after nearly 10 years of everybody finding this stackoverflow on google, there might be more robust solutions now? | 15:35 |
|
| in my case sed sometimes works better, but only if the variable name is very unique | 15:36 |
|
| otherwise it would be better to use more cues from the diff instead to prefilter everything, but that's a lot of steps and it happens way too often for me | 15:37 |
|
osse
| hiro: Not what you're looking for, but I suggest you stage the changes. That way git diff won't display them | 15:37 |
|
hiro
| the motivation here is to try and quickly understand a commit log that has lots of commiters that have no idea about basic git hygiene :) | 15:38 |
|
| to quickly see all the relevant changes that actually functionally effect anything at all | 15:39 |
|
| there is git diff -w which helps a lot for commits where people mix in whitespace changes | 15:39 |
|
osse
| git diff -S/-G might help. Would be nice with a way to negate them. That would be perfect | 15:39 |
|
hiro
| but basically i'd need the same for loads of other bad habits that people tend to have | 15:39 |
|
| osse: yeah esp. if i can do a "strict" match where it only works if there is no other change but the matched regex on the line | 15:40 |
| ← tiin57 left | 15:42 |
| → tiin57 joined | 15:45 |
| ← AnAverageHuman left | 15:45 |
| → bamdad joined | 15:45 |
|
hiro
| osse: to negate them i think it might be possible to make a branch from before the diversion, apply this patch, rebase upon it and then revert :D | 15:48 |
|
| this patch == git log -S oldname -S newname -w -p > patch | 15:48 |
| → zebrag joined | 15:50 |
| → Kaivo joined | 15:50 |
| → Muimi_ joined | 15:51 |
| → thomasross joined | 15:52 |
| ← Muimi left | 15:53 |
| Muimi_ → Muimi | 15:53 |
| ← tryte left | 15:55 |
| → tryte joined | 15:55 |
| ← cebor left | 15:55 |
| → Aquazi joined | 15:56 |
| → cd joined | 15:56 |
| → cebor joined | 15:56 |
| ← cebor left | 15:58 |
| → cebor joined | 15:58 |
| → init_ joined | 16:00 |
| ← tilpner left | 16:03 |
| → tilpner joined | 16:04 |
| ← tilpner left | 16:05 |
| → tilpner joined | 16:06 |
| ← Lunatrius left | 16:07 |
| ← Kaisyu7 left | 16:07 |
| → Lunatrius joined | 16:07 |
| → Kaisyu7 joined | 16:08 |
| ← roflin left | 16:08 |
| ← warthog9 left | 16:08 |
| → warthog9 joined | 16:08 |
| → roflin joined | 16:10 |
| ← tiin57 left | 16:11 |
| → laertus joined | 16:15 |
|
laertus
| once i do a "git fetch", how do i diff the changes? | 16:15 |
| → mowcat joined | 16:15 |
| → tiin57 joined | 16:15 |
|
laertus
| "git diff" by itself doesn't show anything, but "git fetch" did show that some changes were there | 16:16 |
|
ikke
| laertus: diff against the remote tracking branch | 16:16 |
|
| for example: git diff HEAD @{u} | 16:16 |
|
laertus
| what does the @{u} stand for? | 16:17 |
|
ikke
| short for HEAD@{upstream}, the remote tracking branch for the currently checked out branch | 16:18 |
|
laertus
| hmmm... i'm tracking origin/master, and i had first tried "git diff origin/master" but seems to give me different results than "git diff HEAD @{u}" | 16:19 |
| ← mikkel left | 16:19 |
| ← zebrag left | 16:19 |
|
ikke
| The command you ran would be equal to git diff origin/master HEAD, the order is switched | 16:20 |
|
laertus
| ah | 16:20 |
|
ikke
| (it should show the inverse) | 16:20 |
|
laertus
| ok, so would "git diff HEAD origin/master" be the same as "git diff HEAD @{u}" ? | 16:20 |
|
ikke
| If you are on master, then yes | 16:20 |
|
laertus
| i see | 16:21 |
|
| thank you | 16:21 |
|
ikke
| you're welcome | 16:21 |
|
laertus
| actually, i have another question... | 16:22 |
|
ikke
| You have 2 more questions before your trial ends :P | 16:22 |
|
laertus
| :) | 16:22 |
|
| some time back i did a "git fetch" on another repo, and after reviewing the changes did a "git apply" (from within magit), and it seems i got a merge conflict | 16:22 |
|
| in #emacs i was advised not to use "git apply" and instead do a fast-forward merge | 16:23 |
|
ikke
| apply in emacs is something different from git apply | 16:23 |
|
laertus
| is that good advice, and if so why would a fast-forward merge work when an apply failed? | 16:23 |
|
ikke
| You would use apply only in certain circumstances | 16:24 |
|
| A fast-forward merge is certainly the best thing to do when grabbing upstream changes | 16:25 |
| → benfelin joined | 16:26 |
|
laertus
| ok, thank you | 16:27 |
|
| and how would i actually do a fast-forward merge directly from the command line? | 16:27 |
|
ikke
| git merge --ff-only @{u} | 16:27 |
| ← rfuentess left | 16:27 |
|
laertus
| great, thanks again | 16:27 |
|
| i think i've used up all my questions :) | 16:28 |
|
ikke
| git rebase @{u} would also do a fast-forward when possible (and rebase otherwise) | 16:28 |
| → mikkel joined | 16:32 |
| → a-l-e joined | 16:35 |
| ← PacKetSlayer left | 16:35 |
| ← mikkel left | 16:36 |
| → PacKetSlayer joined | 16:37 |
| → shtrb joined | 16:37 |
|
shtrb
| Is there a way I could extract a GPG public key from commits (or from github) ? | 16:38 |
|
ikke
| Not from commits, it would only contain the signatures | 16:39 |
| ← tgunr left | 16:39 |
|
shtrb
| My only option is to request each person to send their public keys correct ? | 16:39 |
|
ikke
| or use some kind of gpg key server | 16:40 |
|
shtrb
| yes (ofc). thanks | 16:40 |
|
ikke
| github might publish users gpg public keys as well | 16:41 |
|
shtrb
| Oh , thanks , how ? | 16:41 |
|
| if you have a clue . | 16:41 |
| ← tiin57 left | 16:41 |
|
ikke
| https://github.com/<username>.keys perhaps, but not sure if that's only ssh keys, or also gpg keys | 16:42 |
|
| https://developer.github.com/v3/users/gpg_keys/#list-gpg-keys-for-a-user | 16:42 |
|
| also an API endpoint apparently | 16:42 |
|
shtrb
| Thank you ! | 16:42 |
|
ikke
| https://github.com/<user>.gpg_keys | 16:43 |
| → orbyt_v7 joined | 16:43 |
|
shtrb
| WOW ! thank you | 16:44 |
|
| how did you find that urls ? | 16:44 |
|
ikke
| deduced it from the api documetation | 16:44 |
| ← POQDavid left | 16:45 |
| → tiin57 joined | 16:45 |
| → POQDavid joined | 16:45 |
|
| shtrb facepalm | 16:46 |
| ← pikapika left | 16:52 |
| → pikapika joined | 16:52 |
| ← Lucas_Gray left | 17:00 |
| → archwizard56 joined | 17:01 |
| ← Ironman3000 left | 17:01 |
| → howdoi joined | 17:03 |
| ← archwizard left | 17:04 |
| → tgunr joined | 17:05 |
| ← mozgalom left | 17:05 |
| ← tiin57 left | 17:11 |
| → OnkelBlade joined | 17:13 |
| → Human_G33k joined | 17:14 |
| → tiin57 joined | 17:15 |
| ← HumanGeek left | 17:17 |
| → Guest20 joined | 17:19 |
| ← mir100 left | 17:20 |
| ← thiago left | 17:25 |
| ← mowcat left | 17:26 |
| → Muimi_ joined | 17:27 |
| → Betal joined | 17:28 |
| ← Muimi left | 17:30 |
| Muimi_ → Muimi | 17:30 |
| → wootehfoot joined | 17:31 |
| ← lightstalker left | 17:32 |
| → lightstalker joined | 17:34 |
| → moo joined | 17:34 |
| ← wootehfoot left | 17:36 |
| → AnAverageHuman joined | 17:37 |
| → thiago joined | 17:38 |
| ← crose left | 17:38 |
| ← Muimi left | 17:40 |
| → davispuh joined | 17:41 |
| ← tiin57 left | 17:41 |
| ← Guest20 left | 17:43 |
| → tiin57 joined | 17:45 |
| ← arcatech left | 17:46 |
| ← moo left | 17:47 |
| → wootehfoot joined | 17:47 |
| → saveNexit joined | 17:51 |
| ← Anticom left | 17:52 |
| → strobelight joined | 17:54 |
| → mirrorbird joined | 17:54 |
| → arcatech joined | 17:55 |
| → mozgalom joined | 17:56 |
| → dqx_ joined | 17:58 |
| ← duderonomy left | 18:00 |
| ← saveNexit left | 18:00 |
| ← maxzor left | 18:03 |
| ← wad left | 18:04 |
| ← tgunr left | 18:07 |
| → stats4647 joined | 18:08 |
| → tgunr joined | 18:09 |
| ← AnAverageHuman left | 18:10 |
| ← tiin57 left | 18:12 |
| → tiin57 joined | 18:15 |
| ← tejr left | 18:17 |
| → tejr joined | 18:17 |
| ← Sauvin left | 18:24 |
| → UlrichH joined | 18:24 |
| → duderonomy joined | 18:25 |
| ← tgunr left | 18:27 |
| → tgunr joined | 18:30 |
|
hiro
| hahahahaha after many many hours i randomly realize a much more obvious and useulf solution to undo this. so simple. just do the git log -S oldname -S newname -w -p| sed 's/^-/+/; s/^+/-/' > patch !!!! then look at diff. done. | 18:33 |
|
| noooo | 18:34 |
|
| i'm wrong | 18:34 |
|
ikke
| hiro: diff -R | 18:34 |
|
hiro
| recursive diff? | 18:35 |
| ← flowinho left | 18:35 |
|
ikke
| reverse | 18:35 |
|
hiro
| yeah, but i made an error :( | 18:35 |
|
| i'd need to add one more step | 18:35 |
|
| though i can't accept that i'm the only one trying to come up with this in a slightly more stable way... | 18:35 |
| ← laertus left | 18:36 |
| → flowinho joined | 18:36 |
| ← orbyt_v7 left | 18:39 |
| ← tiin57 left | 18:41 |
| ← flowinho left | 18:42 |
| → flowinho joined | 18:43 |
| ← OnkelBlade left | 18:44 |
| → zebrag joined | 18:44 |
| → ericl joined | 18:45 |
|
ericl
| Does anyone know how MingW relates to Git? | 18:45 |
|
| It shows up on my terminal | 18:45 |
| → tiin57 joined | 18:45 |
| ← mozgalom left | 18:45 |
|
hiro
| so for a trivial patch file like | 18:46 |
|
| -test(bla) | 18:46 |
|
| +test(blub) | 18:46 |
|
| cat diff | sed -n '/^+/{s/^+/+/; p}; /^-/{s/^\(-.*\)bla\(.*\)$/\1blub\2/; p}' | 18:46 |
|
| -test(blub) | 18:46 |
|
| +test(blub) | 18:46 |
|
| this will ignore all diffs that are just changing bla to blub | 18:46 |
| → mozgalom joined | 18:46 |
|
hiro
| but it can only happen once | 18:46 |
|
| you can basically apply that patch and look at the diff afterwards | 18:46 |
|
| it's a lot of back and forth | 18:46 |
|
| but it can be automated fully if you just run parts of it multiple time until it all checks out | 18:47 |
|
| but i *bet* somebody found an even better way | 18:47 |
|
| this is very naive approach | 18:47 |
| → gehn joined | 18:47 |
|
ikke
| ericl: it's a third party system that git for windows uses | 18:48 |
|
gehn
| how might I take a branch and "turn it into" a set of uncommitted changes? I googled for this, but all I get is results for the opposite of what I want | 18:48 |
| → yonder joined | 18:48 |
|
ericl
| Oh I see what u mean | 18:48 |
|
| thanks sm for the reply @ikke | 18:48 |
|
gehn
| like basically the equivalent of `git stash apply` but from a branch not a stash | 18:49 |
|
ericl
| This is an important distinction — instead of getting just a working copy, Git receives a full copy of nearly all data that the server has. | 18:50 |
|
| Can someone explain this sentence? | 18:50 |
|
| Is the difference for git that it copies the commit history too? | 18:50 |
|
| or is there anything else going on behind the scenes | 18:50 |
|
| thanks | 18:50 |
| ← tgunr left | 18:51 |
| → tgunr joined | 18:52 |
|
ikke
| Yes, you get the entire history of the repository | 18:53 |
| → ash_worksi joined | 18:53 |
|
ash_worksi
| what is the command to pull a branch to just have it to checkout out but not to pull remote files to your actual file system (in otherwords don't overwrite the current files) | 18:54 |
|
| fetch! | 18:54 |
|
ikke
| quick | 18:57 |
|
| quack | 18:57 |
| ← ttl left | 18:57 |
|
Lewix
| I git fetch and I have the following: | 18:59 |
|
| error: refs/heads/584-twilio-webhook-for-stop-lastsent does not point to a valid object! | 18:59 |
| → orbyt_v7 joined | 19:00 |
| ← arcatech left | 19:01 |
| ← haymawk left | 19:04 |
| → Phylock joined | 19:04 |
|
ikke
| did you have a computer crash or something like that? | 19:05 |
| ← gschanuel left | 19:05 |
|
Lewix
| ikke: nope, my coworker pushed, then I git fetch and it occured | 19:05 |
| → arcatech joined | 19:06 |
| → maxzor joined | 19:08 |
| ← gehn left | 19:10 |
| → gehn joined | 19:10 |
| ← tiin57 left | 19:11 |
| ← duderonomy left | 19:12 |
| → tiin57 joined | 19:15 |
| ← orbyt_v7 left | 19:15 |
| ← impermanence left | 19:17 |
| → mark4 joined | 19:19 |
|
mark4
| im having extreme git issues here - im on branch A i want to be on branch B i say git checkout B and now im in detached head state | 19:20 |
|
| what the hell is going on? | 19:20 |
|
| i dont understand i need to be on branch B why does it not simply switch to branch B when i tell it to | 19:20 |
| ← wootehfoot left | 19:23 |
|
ikke
| mark4: seems like B is not a branch | 19:24 |
|
mark4
| it is but i was specifying origin/feature/B not just feature/b | 19:25 |
|
| sorry figured it out :) | 19:25 |
| ← vicfred left | 19:27 |
| → KnoP joined | 19:27 |
|
ikke
| :) | 19:27 |
|
| Lewix: Just fetching is very unlikely to cause these issues | 19:28 |
| → gschanuel joined | 19:28 |
| ← cosimone left | 19:29 |
| → duderonomy joined | 19:30 |
| → cosimone joined | 19:30 |
| → Anticom joined | 19:30 |
| ← UlrichH left | 19:30 |
| ← a-l-e left | 19:31 |
| ← tgunr left | 19:31 |
| → leeN joined | 19:36 |
| → tgunr joined | 19:37 |
| ← dqx_ left | 19:37 |
| ← mark4 left | 19:38 |
|
ericl
| how can i see permissions on a git repo | 19:39 |
|
| like which branches can i push too | 19:39 |
|
ikke
| ericl: depends on the remote system | 19:40 |
|
| that's not something git itself offers (there is no built-in acl) | 19:40 |
|
ericl
| i'm trying to modify a github repo | 19:40 |
|
| i got in on my computer using git clone | 19:40 |
|
| and there's like a ton of branches | 19:40 |
|
| i'm not sure if i can just edit the master branch directly on my local computer | 19:40 |
|
| and tehn push it to remote | 19:40 |
|
| or if i have to do pull request | 19:41 |
|
| and i'm not even sure why i should fork | 19:41 |
|
| this is so confusing | 19:41 |
| → dqx_ joined | 19:41 |
|
ikke
| Are you a contributor (and marked as such) in github for that project? | 19:41 |
| ← tiin57 left | 19:41 |
|
ericl
| yes | 19:42 |
|
| i got added | 19:42 |
| ← Phylock left | 19:42 |
| ← tgamblin left | 19:44 |
| ← theoceaniscool left | 19:44 |
| → tiin57 joined | 19:45 |
| ← random_yanek left | 19:46 |
| → random_yanek joined | 19:47 |
| ← ericl left | 19:47 |
| ← st-gourichon-fid left | 19:51 |
| ← duderonomy left | 19:53 |
| → duderonomy joined | 19:58 |
| ← dionysus69 left | 20:03 |
| → matelot joined | 20:06 |
| ← shtrb left | 20:08 |
| → vicfred joined | 20:09 |
| ← Maxattax left | 20:10 |
|
gehn
| `git checkout master; git merge --no-commit my-branch` is close to what i want, except that I don't want to be considered in the middle of a merge, and also I want changes to be listed as not staged | 20:11 |
| ← tiin57 left | 20:11 |
| ← mozgalom left | 20:12 |
| → st-gourichon-fid joined | 20:13 |
| → mozgalom joined | 20:14 |
| ← ash_worksi left | 20:14 |
| → tiin57 joined | 20:15 |
| ← dqx_ left | 20:16 |
| ← random_yanek left | 20:16 |
| ← duderonomy left | 20:17 |
| ← strobelight left | 20:18 |
| → strobelight joined | 20:18 |
| → random_yanek joined | 20:20 |
| → cdown_ joined | 20:20 |
| → tgamblin joined | 20:21 |
| ← cdown left | 20:22 |
| cdown_ → cdown | 20:22 |
| → dqx_ joined | 20:23 |
|
rafasc
| gehn: use git merge --squash my-branch instead. | 20:24 |
| → sqwishy joined | 20:26 |
|
rafasc
| after that, unstage the changes with: git reset; | 20:27 |
| → wootehfoot joined | 20:28 |
|
sqwishy
| I have `[credentials] helper` set in a git --local config & global. And running `git config --get-all credentials.helper` shows both. I think it's using the global helper first. Is there a way to use the local one first/only? | 20:28 |
| ← st-gourichon-fid left | 20:29 |
| mozgalom → bomb-on | 20:29 |
| → BackupBackupNick joined | 20:29 |
|
gehn
| rafasc, looks like --squash and --no-ff are mututally exclusive? would it ever be possible e.g. for a single commit branch to accidentally fast forward? | 20:29 |
|
rafasc
| can you run with --show-origin or --show-scope? | 20:29 |
|
gehn
| or does --squash also always prevent fast forward? | 20:29 |
| → st-gourichon-fid joined | 20:29 |
|
rafasc
| gehn: what you are asking makes no sense. Why do you care about --no-ff; if you're not even making a merge? | 20:30 |
|
| When you're just using git merge to the the files? | 20:30 |
|
| If that's not the case, I completely missed your intention. | 20:31 |
|
gehn
| https://git-scm.com/docs/git-merge because "Note that fast-forward updates do not create a merge commit and therefore there is no way to stop those merges with --no-commit. Thus, if you want to ensure your branch is not changed or updated by the merge command, use --no-ff with --no-commit." | 20:31 |
| ← arcatech left | 20:32 |
|
rafasc
| --squash already implies --no-commit; | 20:32 |
| ← st-gourichon-fid left | 20:32 |
|
gehn
| ok so then that begets "Thus, if you want to ensure your branch is not changed or updated by the merge command, use --no-ff with --no-commit." | 20:32 |
| ← Aki-lucky left | 20:32 |
|
gehn
| so does --squash also imply --no-ff | 20:33 |
|
rafasc
| --no-ff makes no sense for --squash. | 20:33 |
|
| what are you trying to do> | 20:33 |
|
| ? | 20:33 |
| → st-gourichon-fid joined | 20:33 |
|
gehn
| git checkout -b my-feature; echo "some change" >> README.txt; git add README.txt; git commit -m "my msg"; | 20:34 |
|
| now I want to change back to master, and get the changes from my-feature as if they were unstaged and I hadn't made a branch nor committed them | 20:34 |
|
| like git stash apply | 20:34 |
|
| but I'd like to "apply" a branch | 20:35 |
|
rafasc
| git checkout master; git restore --source=my-branch --worktree; | 20:37 |
|
| correction: git checkout master; git restore --source=my-branch --worktree :/ ; | 20:37 |
|
| with older versions of git, you can: git chekout master; git checkout my-branch -- :/ ; git reset | 20:37 |
|
| or yet another one: git checkout master; git merge --squash my-branch; git reset; | 20:38 |
|
gehn
| ok | 20:40 |
| → duderonomy joined | 20:40 |
| → SunWuKung joined | 20:41 |
|
rafasc
| there are multiple ways to do it, you just have to understand how the different commands affect the worktree, the staging area and HEAD. | 20:41 |
| ← init_ left | 20:41 |
|
gehn
| is the ":/ ;" a required part of the command or is :/ an emoticon? | 20:41 |
| ← tiin57 left | 20:41 |
|
rafasc
| it's not an emoticon, :/ the root of the repository. | 20:42 |
|
gehn
| ah ok so that would be the <pathspec> then? | 20:42 |
|
rafasc
| correct. It's a pathspec for the root of the repository. | 20:43 |
|
| man git glossary | 20:43 |
|
gitinfo
| the git manpage is available at https://gitirc.eu/git.html | 20:43 |
|
rafasc
| man gitglossary | 20:43 |
|
gitinfo
| the gitglossary manpage is available at https://gitirc.eu/gitglossary.html | 20:43 |
| → arcatech joined | 20:44 |
| ← ghost43 left | 20:44 |
| → ghost43 joined | 20:44 |
| → tiin57 joined | 20:45 |
|
gehn
| which chapter+section in https://git-scm.com/book/en/v2 covers worktrees? | 20:45 |
| ← st-gourichon-fid left | 20:46 |
|
rafasc
| git worktree is relatively recent, I'm not sure if the book covers it. | 20:46 |
|
gehn
| hmm, so what is a worktree? | 20:47 |
| ← Jackneill left | 20:47 |
|
rafasc
| hmm wait. | 20:47 |
|
| worktree can either refer to: man git worktree | 20:47 |
|
gitinfo
| the git-worktree manpage is available at https://gitirc.eu/git-worktree.html | 20:47 |
|
rafasc
| or your directory. | 20:47 |
| → st-gourichon-fid joined | 20:48 |
|
rafasc
| the place where git materializes the files that exist on the repo. The directory that usually contains the .git/ directory. | 20:48 |
|
gehn
| I'm interested in https://gitirc.eu/git-worktree.html | 20:48 |
|
| it's informative, but not very descriptive | 20:48 |
|
| e.g. it never defines what a worktree is or what the use case is | 20:48 |
|
rafasc
| you cannot explain every single term every time it occurs. | 20:50 |
|
| working tree | 20:50 |
| → Habbie joined | 20:50 |
|
rafasc
| The tree of actual checked out files. The working tree normally contains the contents of the HEAD commit’s tree, plus any local changes that you have made but not yet committed. | 20:50 |
|
| the glossary I linked earlier contains the definition. | 20:50 |
| → ch joined | 20:50 |
|
rafasc
| and the description contains some use cases. | 20:51 |
|
gehn
| there's no description in the glossary | 20:52 |
|
ch
| hi! | 20:52 |
|
gitinfo
| ch: 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:52 |
|
gehn
| unless you mean the DESCRIPTION section at the top of this https://git-scm.com/docs/git-worktree | 20:52 |
|
| which I will go ahead and disagree that it has any verbiage around describing use cases | 20:53 |
|
rafasc
| gehn: there's a description on the glossary of what a worktree means, there's a description of the usescases of git worktree on the manpage, along with a example on the botton. | 20:53 |
|
gehn
| by manpage do you mean this? https://git-scm.com/docs/git-worktree | 20:53 |
|
rafasc
| yes | 20:53 |
|
gehn
| no use cases in that description | 20:53 |
|
rafasc
| In its simplest form, git worktree add <path> automatically creates a new branch whose name is the final component of <path>, which is convenient if you plan to work on a new topic. For instance, git worktree add ../hotfix creates new branch hotfix and checks it out at path ../hotfix. To instead work on an existing branch in a new working tree, use git worktree add <path> <branch>. On the other hand, | 20:54 |
|
| if you just plan to make some experimental changes or do testing without disturbing existing development, it is often convenient to create a throwaway working tree not associated with any branch. For instance, git worktree add -d <path> creates a new working tree with a detached HEAD at the same commit as the current branch. | 20:54 |
|
ch
| i'm often in the situation that i want to swap the order of the two last commits (so HEAD~1). is there a nice/fast way of doing this, without rebase -i and an editor? | 20:54 |
| ← Cabanossi left | 20:54 |
| ← opal left | 20:54 |
|
gehn
| well I think we are somehow not looking at the same document | 20:54 |
|
| because that text does not occur in the "DESCRIPTION" section of https://git-scm.com/docs/git-worktree | 20:55 |
| ← wootehfoot left | 20:55 |
|
gehn
| actually nowhere on the page even | 20:55 |
| → Cabanossi joined | 20:55 |
|
rafasc
| gehn: https://gitirc.eu/git-worktree.html | 20:55 |
|
gehn
| why is there a separate set of docs for IRC? | 20:56 |
| → Jackneill joined | 20:56 |
| _raymond → raymond | 20:57 |
|
rafasc
| The docs on gitirc are generated from source by jast, looks like there's a mismatch for some reason. | 20:57 |
|
| gehn: https://git-scm.com/docs/git-worktree#_examples | 20:58 |
|
| but there's still an example at the end. | 20:58 |
| ← benfelin left | 20:59 |
|
rafasc
| ch: why are you trying to avoid rebase -i/editor? | 20:59 |
|
| ch: for just two commits, you could so something like: git reset --hard HEAD~2; git cherry-pick <commit> <commit> | 21:00 |
|
ch
| rafasc: i do this so often, its annoying to wait for vim to start, manipulate the lines and quit again | 21:00 |
| ← BackupBackupNick left | 21:01 |
|
rafasc
| ch: I have a trick for you, wait a sec. | 21:02 |
|
ch
| rafasc: i found this on stackoverflow, but ... there has to be a better way -> https://stackoverflow.com/a/33388211/2298386 | 21:02 |
|
rafasc
| ch: I was thinking something similar: GIT_SEQUENCE_EDITOR=tac | 21:06 |
|
Habbie
| tac is nicer than sed :) | 21:07 |
| ← feriman left | 21:07 |
| ← bomb-on left | 21:09 |
| ← arcatech left | 21:09 |
|
rafasc
| Habbie: tac doesn't work. It needs to save the file, not pipe it. | 21:10 |
|
Habbie
| right | 21:10 |
| ← tiin57 left | 21:11 |
|
rafasc
| for a quick swap, It's usually pretty quick: git rebase -i HEAD~2; ddp:wq | 21:13 |
| → mozgalom joined | 21:14 |
| → tiin57 joined | 21:15 |
| ← sudoforge left | 21:17 |
|
rafasc
| GIT_SEQUENCE_EDITOR='todo=$(tac "$1"); echo "$todo" >"$1"' git rebase -i HEAD~2; | 21:22 |
|
| something like that. | 21:23 |
|
ch
| heh, alright | 21:23 |
|
rafasc
| You need to read and write on separate invocations, as reading and writing to the same file can have unintended effects. | 21:24 |
|
ch
| thanks for taking the time. i'll see about making a script sometime soon :) | 21:24 |
| ← vdamewood left | 21:25 |
| ← oatmealraisin left | 21:28 |
| ← matelot left | 21:30 |
| → matelot joined | 21:34 |
| → arcatech joined | 21:36 |
|
rafasc
| GIT_SEQUENCE_EDITOR='f(){ mapfile <"$1"; printf '%s' "${MAPFILE[@]}" | tac >"$1" ;};f' | 21:37 |
| → Irish joined | 21:38 |
| ← mirrorbird left | 21:39 |
| ← Kaivo left | 21:40 |
| ← tiin57 left | 21:41 |
| → silverwhitefish joined | 21:45 |
| → tiin57 joined | 21:45 |
| → mns joined | 21:57 |
| ← rafasc left | 21:59 |
| ← KnoP left | 22:00 |
| → stormsz joined | 22:02 |
| gitinfo set mode: +v | 22:03 |
| ← irc_user left | 22:04 |
| → s2013 joined | 22:04 |
| ← carlesc left | 22:04 |
| ← rustyshackleford left | 22:04 |
| ← OvermindDL1 left | 22:04 |
| ← dmlloyd left | 22:04 |
| ← afisher left | 22:04 |
| ← SrPx left | 22:04 |
| ← itok left | 22:04 |
| ← hussam left | 22:04 |
| → OvermindDL1 joined | 22:04 |
| → itok joined | 22:05 |
| ← Anticom left | 22:05 |
| → hussam joined | 22:05 |
| → davispuhh joined | 22:05 |
| → SrPx joined | 22:05 |
| → carlesc joined | 22:05 |
| → irc_user joined | 22:05 |
| → rustyshackleford joined | 22:06 |
| → dmlloyd joined | 22:06 |
| → afisher joined | 22:06 |
| ← davispuh left | 22:06 |
| → Xenguy joined | 22:06 |
| ← ch1astre left | 22:07 |
| → ch1astre joined | 22:09 |
| ← tiin57 left | 22:11 |
| ← milkt left | 22:12 |
| → tiin57 joined | 22:15 |
| ← mns left | 22:15 |
| ← Irish left | 22:23 |
| ← CodeSlingerPaul left | 22:33 |
| ← leeN left | 22:34 |
| ← arcatech left | 22:35 |
| ← tiin57 left | 22:41 |
| → tiin57 joined | 22:45 |
| ← thiago left | 22:48 |
| ← dqx_ left | 22:48 |
| ← Xenguy left | 22:54 |
| → Xenguy joined | 22:58 |
| → mns joined | 23:00 |
| → thiago joined | 23:06 |
| ← s2013 left | 23:07 |
| → mat001 joined | 23:08 |
| ← PJBoy left | 23:08 |
| ← mat001_ left | 23:09 |
| ← gehn left | 23:10 |
| → gehn joined | 23:11 |
| ← tiin57 left | 23:11 |
| → Oatmeal joined | 23:12 |
| ← mns left | 23:13 |
| → tiin57 joined | 23:15 |
| → hineios joined | 23:16 |
| ← calcul0n_ left | 23:20 |
| → jaziz joined | 23:21 |
| → opal joined | 23:25 |
| → arcatech joined | 23:28 |
| → DiffieHellman joined | 23:29 |
| ← gehn left | 23:29 |
| ← mozgalom left | 23:29 |
| → mozgalom joined | 23:31 |
| ← kent\n left | 23:31 |
| ← rkta left | 23:32 |
| → rkta joined | 23:32 |
| → ycon_ joined | 23:37 |
| → init_ joined | 23:41 |
| ← tiin57 left | 23:41 |
| → tiin57 joined | 23:45 |
| ← bamdad left | 23:46 |
| → bamdad joined | 23:47 |
| → BUSY joined | 23:49 |
| ← hineios left | 23:52 |
| → hineios joined | 23:55 |
|
ycon_
| Hi, I'd like to know what I'm doing wrong here with sub modules | 23:57 |
|
| I keep having to run "git submodule update --recursive" . Is that because I've used a push force-with-lease? | 23:57 |
| ← Aquazi left | 23:57 |
|
ycon_
| (reason I have to run update, is it constantly shows (new commits) in the submodules | 23:57 |