IRCloggy #git 2022-07-23

Logs Search ←Prev date Next date→ Channels Documentation

Provider of IRC logs since 2005.
WARNING: As Freenode became unjoinable and lost all warnings in topics, we cannot log channels on Freenode anymore.

2022-07-23

cousteau left00:01
pulse left00:03
atrigent_ joined00:04
justmatt left00:10
ramblebamble left00:10
ferdna joined00:11
rgrinberg left00:11
de-facto left00:12
de-facto joined00:12
rama left00:13
lucasta left00:17
Sasazuka left00:18
lucasta joined00:23
squirrel joined00:27
kenanmarasli left00:27
Sasazuka joined00:28
dflick__ joined00:29
dflick_ left00:32
Sasazuka left00:33
lolok left00:37
pulse joined00:40
elkalamar left00:42
stewie925 left00:42
forgotmynick left00:53
cdown left00:57
lxsameer left00:59
bn_work joined01:01
rgrinberg joined01:02
kantlivelong left01:06
Betal left01:07
kantlivelong joined01:11
kantlivelong left01:17
madewokherd joined01:19
kantlivelong joined01:19
madewokherd` left01:20
atrigent_ left01:21
moldorcoder7 left01:24
rgrinberg left01:24
umbramalison left01:26
umbramalison joined01:26
rgrinberg joined01:29
bambanxx joined01:30
vysn joined01:37
Sulky joined01:39
kevr left01:45
kevr joined01:46
mat001 left01:47
mat001 joined01:48
Vonter joined01:48
Yruama left01:48
dflick__ left01:54
vdamewood joined01:55
rickay left02:02
ferdna left02:04
bindu left02:07
de-facto left02:07
fling left02:07
kevr left02:07
crabbedhaloablut left02:07
GNUmoon left02:07
adanwan left02:07
gxt left02:07
FinnElija left02:07
ghost43 left02:07
chexum left02:07
crabbedhaloablut joined02:10
chexum joined02:10
de-facto joined02:10
adanwan joined02:10
ghost43 joined02:10
FinnElija joined02:10
fling joined02:10
kevr joined02:10
bindu joined02:10
pulse left02:11
Strom joined02:16
de-facto left02:16
kevr left02:16
bindu left02:16
bindu joined02:17
kevr joined02:17
de-facto joined02:17
ackyshake left02:23
ghost43 left02:25
ghost43 joined02:25
FinnElija left02:27
finn_elija joined02:27
finn_elijaFinnElija02:27
lucasta left02:28
FinnElija left02:29
lucasta joined02:29
FinnElija joined02:30
Murr left02:35
Murr joined02:35
Strom left02:37
Xenguy joined02:39
rgrinberg left02:42
dsrt^ left02:44
squirrel left02:46
sakitami joined02:47
kevr left02:52
kevr joined02:52
Leonarbro joined02:53
bindu left02:58
FinnElija left02:58
kevr left02:58
ghost43 left02:58
junktext joined02:59
junktext_ left03:00
hbautista joined03:04
ghost43 joined03:06
kevr joined03:06
bindu joined03:07
FinnElija joined03:07
Welp left03:09
ghost43 left03:10
ghost43 joined03:11
vysn left03:16
Crassus joined03:22
nate4 joined03:23
nate4 left03:29
pretty_dumm_guy left03:34
terminaldweller left03:35
terminaldweller joined03:35
de-facto left03:37
fling left03:37
adanwan left03:37
crabbedhaloablut left03:37
chexum left03:38
dflick__ joined03:39
tyson2 left03:40
hoochmonger joined03:42
fling joined03:45
sudoforge left03:48
tsraoien joined03:48
de-facto joined03:52
de-facto left03:52
regedit left03:53
gast0n left03:54
de-facto joined03:55
tsraoien left03:59
lolok joined04:02
off^ joined04:04
sakitami left04:05
bond joined04:06
Welp joined04:08
crabbedhaloablut joined04:12
chexum joined04:12
adanwan joined04:12
bket left04:16
adanwan left04:16
adanwan joined04:17
FinnElija left04:18
bindu left04:18
ghost43 left04:18
fling left04:18
de-facto left04:18
kevr left04:18
bket joined04:19
fling joined04:19
de-facto joined04:19
ghost43 joined04:19
kevr joined04:19
FinnElija joined04:19
bindu joined04:19
de-facto left04:27
de-facto joined04:28
lolok left04:39
lolok joined04:39
lolok left04:43
lolok joined04:43
madewokherd` joined04:44
madewokherd left04:46
Betal joined04:48
bambanxx left04:52
chexum left04:57
chexum joined04:59
adanwan left05:05
chexum left05:05
adanwan joined05:06
bindu left05:07
bindu joined05:08
chexum joined05:12
crabbedhaloablut left05:16
de-facto left05:16
crabbedhaloablut joined05:17
FinnElija left05:18
de-facto joined05:19
FinnElija joined05:20
de-facto left05:20
de-facto joined05:21
de-facto left05:23
de-facto joined05:26
zebrag left05:28
bn_work left05:30
oncall-pokemon left05:31
de-facto left05:35
de-facto joined05:37
de-facto left05:37
bloody left05:41
thiago left05:42
jazzy left05:48
rsx joined05:52
dflick__ left05:57
stewie925 joined05:58
de-facto joined06:03
lucasta left06:04
lucasta3 joined06:05
lucasta joined06:05
stewie925 left06:05
lucas_ta left06:07
Jong left06:07
de-facto left06:10
jinsun__ joined06:18
jinsunGuest222406:18
jinsun__jinsun06:18
Sakitami joined06:19
Sakitami left06:20
Guest2224 left06:20
sakitami joined06:21
wallabra_ joined06:22
gas51627 joined06:22
wallabra left06:24
wallabra_wallabra06:24
Murr left06:34
Murr joined06:35
cdown joined06:37
sakitami left06:39
maryo joined06:45
maryo I have migrated from SVN to GIT Using Subgit tool.. My SVN Revisions was around 37000 but after migrations, I could see only 13750 commits only in Git.. Am I missing out something?06:46
EvilDMP joined06:49
srinidhi joined06:52
The_Blode joined06:55
Artea joined06:58
infernix left07:02
gco joined07:07
gco left07:15
jrm joined07:17
skapata left07:20
infernix joined07:21
causasui left07:24
nate4 joined07:25
ghost43 left07:26
loulou_ left07:27
ghost43 joined07:28
nate4 left07:30
john_johnk joined07:32
hamburgler left07:44
zan joined07:50
jinsun__ joined07:52
jinsunGuest374507:52
jinsun__jinsun07:52
feriman joined07:54
Guest3745 left07:55
kenanmarasli joined07:57
iomari891 joined07:57
sakitami joined07:58
gco joined07:59
vysn joined08:09
elastic_dog joined08:09
igemnace joined08:10
zeenk joined08:14
john_johnk left08:14
lucasta3 left08:15
Tobbi_1 joined08:16
coot joined08:18
dionysus69 joined08:18
Tobbi_ left08:18
Tobbi_1Tobbi_08:18
elkalamar joined08:27
vqueiroz left08:32
Visne left08:33
Visne joined08:34
lxsameer joined08:38
Sulky_ joined08:38
tirnanog joined08:41
Sulky left08:41
gas51627 left08:59
elkalamar left09:02
rsx left09:02
gco left09:16
vysn left09:18
___nick___ joined09:28
Betal left09:31
srinidhi left09:35
poprostumieciek joined09:41
adanwan left09:42
poprostumieciek left09:42
adanwan joined09:43
bindu left09:44
FinnElija left09:45
loki_val joined09:45
finn_elija joined09:45
finn_elijaFinnElija09:45
bindu joined09:45
crabbedhaloablut left09:47
maryo left09:47
maryo joined09:47
dviola joined09:55
G30RD13 joined10:15
FinnElija left10:24
loki_val left10:24
crabbedhaloablut joined10:24
FinnElija joined10:24
indy left10:25
Celelibi left10:28
nyah joined10:30
node1 joined10:33
elkalamar joined10:34
vishal left10:40
GNUmoon joined10:41
Sazhen86 left10:41
vishal joined10:41
DF32 joined10:50
coot left10:51
dionysus69 left10:54
maryo left10:55
coot joined10:56
sepples joined11:01
mort joined11:02
momomo joined11:03
fflam left11:03
momomo So I have a work related git and github enterprise account ... now when I committed some code to a public github repository ... it decided to include my name ... how can I ensure shit like this don't fucking ever happen again ?11:04
fuck11:04
elkalamar left11:05
dflick__ joined11:06
Crassus left11:07
indy joined11:07
ikke Your name is part of the commit that you create11:09
You can use includeIf configuration directives to set this per directory11:09
so that projects in a certain directory always get committed with a certain name and e-mail address11:09
coot left11:10
mon_aaraj joined11:11
moldorcoder7 joined11:14
m0viefreak joined11:17
justmatt joined11:22
lxsameer left11:25
nate4 joined11:27
zeenk left11:27
lxsameer joined11:27
maryo joined11:30
jonosterman joined11:31
nate4 left11:31
maryo left11:32
maryo joined11:32
hex_ joined11:34
moldorcoder7_ joined11:35
moldorcoder7 left11:36
node1 left11:37
coot joined11:38
tyson2 joined11:42
hex_ left11:43
momomo Is there not a way to define it in the git global?11:43
Like per domain kind of thing?11:43
Kind of annoying that if you define a git global user .. it will use it everywhere unless you are wizard11:44
I think i will just disable the global user and I guess force set it on the locals11:44
adanwan left11:46
adanwan joined11:47
dav1d momomo, sure, you have a git config per repository11:48
I dont have it globally set e.g.11:48
momomo only issue is you have to keep configure it after a clone11:49
zer0bitz joined11:49
momomo you'd think git clone could do it for you11:49
dav1d how would git know11:50
maybe you can tie the config to the upstream URL (no idea), but then what happens if you have multiple upstreams11:50
momomo dav1d i think by 2022 someone could have figured out a scheme ... like github supplied username on the git clone url11:50
cbreak username? heh :D11:51
mackerman In theory someone could write a script to figure it out, clone the repo and set the user config in it11:51
cbreak I'd be called "git" everywhere11:51
lxsameer left11:51
mackerman Parsing GitHub repo URLs is abit outside the scope of core git11:51
cbreak momomo: if you want git to know who you are globally, configure it globally. Otherwise do not.11:52
dav1d momomo, do you clone 20x a day? make a (git) alias if it's that much trouble11:52
momomo git clone command could have that built it as an argument11:52
cbreak if you want to configure it differently everywhere, you can write a script for it.11:52
momomo so that github could provide you with a ready to go command11:52
cbreak but honestly, is your name not the same everywhere?11:52
Celelibi joined11:52
momomo dav1d no, that is the issue .. i don't have 20 everyday ... the issue is when I do it rarely like update a repo to be nice ... and then I am fucked and my entire work name and email is exposed11:53
and i have to spend hours to unwind it11:53
dav1d momomo, then don't set it globally11:53
momomo 1 year from now being nice all over again .. i will have forgotten all about this11:53
cbreak changing an e-mail address / name isn't a matter of hours11:53
momomo dav1d i hope i can remember that on the next job11:53
mackerman man gitmailmap for a way to have all git tools report something different for name and email11:53
gitinfo the gitmailmap manpage is available at https://gitirc.eu/gitmailmap.html11:53
cbreak it's a matter of minutes, if you notice it early enough11:53
momomo dav1d and then i still have to rememeber to set it locally after each git clone11:53
cbreak git will complain if you don't set it11:54
dav1d momomo, no worries git will remind you11:54
momomo let me trye11:54
dav1d if there is no user/email set you cannot commit11:54
ikke momomo: a repository can have more than one remote11:54
You can even commit without a remote11:55
dav1d the only thing that is annoying that most auto generated commands include the `--global` flag11:55
momomo dav1d yes, it will remind to fuck up all over again11:55
as a noob 1 year from now, the suggestion is:11:55
git config --global user.email "you@example.com"11:55
git config --global user.name "Your Name"11:55
so set the glboal one and of course 99% will bite11:55
dav1d yeah, but now you know ;)11:55
cbreak of course that's the suggestion11:55
dav1d and for most users this is the correct suggestion11:55
cbreak because 99% of the time, your name will be the same everywhere11:55
elkalamar joined11:56
dav1d Personally I would probably just make an alias11:56
cbreak and 25.7% of the time, the e-mail address too11:56
momomo now i create a git bash command and hopefull i can run that .. i just wish to there was a way to git clone .. cd in to whatever was cloned and then my.git.config.local11:56
dav1d `git clone-work` or something like that11:56
momomo dav1d and keep changing the global settings ?11:56
the question is why in git global it is not per domain11:56
mackerman You don't have to use git's hints exactly as is11:56
dav1d momomo, nah no global settings but the alias would initialize the repo11:56
cbreak momomo: domain what?11:57
configurations are per repo or per user11:57
momomo on the global scope11:57
dav1d momomo, how does that help? I have private github repos and company github repos on the same domain11:57
momomo ssh config has this:11:57
Host 192.168.0.17511:57
AddKeysToAgent yes11:57
UseKeychain yes11:57
so you define rules depending on host11:57
cbreak for SSH, that makes sense.11:57
momomo same could work on the global gitconfig11:57
cbreak for git it's dumb.11:57
momomo why?11:58
cbreak because IP addresses change all the time11:58
and servers are not significant for this11:58
momomo it does not have to be ip11:58
it could be repo11:58
ikke momomo: what you have 2 remotes in the same repository with conflicting settings?11:58
cbreak you can do per-repo configuration already11:58
momomo i mean the idea of git global seems wack anyway11:58
cbreak yes, which is very local11:58
cbreak of course. it's per repo.11:58
momomo Host *github.com*11:59
ikke momomo: some people don't like to have to reconfigure every repo for settings they want to have consistently11:59
momomo done11:59
ikke momomo: you forget that git is decentralized11:59
dav1d momomo, https://git-scm.com/docs/git-config#_includes ctrl+f "conditional includes" if the link doesnt link to that section already11:59
momomo ikke exactly i am one of those11:59
so I don't have to manage all local repos config11:59
ikke a repository does not belong to a single remote11:59
momomo i want them in global11:59
but i can only have one11:59
gnoo momomo: a per-host name wouldn't work if you have multiple projects with the same host (e.g. a lot of things now use centralized, non-free host) and want to use different names on those11:59
cbreak gnoo: yeah, or even free ones like github12:00
momomo so define them more specific if your wildcard is matching too many12:00
ikke momomo: the simpler, and already working solution, is to divide these projects in directories per 'persona'12:00
gnoo cbreak: github is non-free(dom respecting)12:00
momomo i just figured this was already in git global config .. and i did not know how to configure it12:00
dav1d momomo, closest you will get is through the conditional includes, might be able to match on a local directory, e.g. ~/company/* is automatically a different git config12:00
cbreak gnoo: it's free though12:00
ikke yes, which is what I already suggested earlier12:00
gnoo cbreak: not libre12:01
english is stupid12:01
cbreak now that's not really important, is it? :)12:01
dav1d ah there is also `[includeIf "hasconfig:remote.*.url:https://example.com/**"]` no clue if that works12:01
momomo, ^12:01
momomo i mean right now i think will just git clone .. .disable the git global completely ... even for work12:01
dav1d it looks so obtrusive .. where does that go anyway?12:01
cbreak momomo: you could use a different user for work12:02
dav1d momomo, read the manpage I linked you12:02
momomo cbreak what do you mean?12:02
log in and out ?12:02
lol12:02
cbreak momomo: different users have different .gitconfig12:02
you don't have to log out12:02
bookworm su is a thing12:02
cbreak just log in with an other user in addition12:02
momomo yes, i'd skip that12:02
before i commit? how will intellij integration like that?12:02
cbreak for working12:02
work on work work with your work account12:03
momomo dav1d where does that infludeIf go?12:03
dav1d momomo, how about you read the manpage I linked you12:03
cbreak and privately work on private work with your private account12:03
dav1d momomo, I even linked to the correct section12:03
:(12:03
cbreak and if you put the repos into the documents directory of the respective user, you won't get too confused which user to use12:03
momomo dav1d and five foo.inc for every local repo ?12:04
dav1d momomo, absolute path should work12:04
momomo i mean right now .. i could define my own momomo.git.clone command that takes a name and email ... but the issue is how do you clone and cd dafely ?12:05
dav1d momomo, "If the pattern starts with ~/, ~ will be substituted with the content of the environment variable HOME."12:05
momomo dav1d too much work to go into that file to modify it everytime i clone something12:05
dav1d momomo, omg12:05
momomo dav1d i don't put git repos in ~12:05
dav1d jesus christ12:05
momomo lol12:05
dav1d do you just want something to copy paste?12:05
then I'll need your company domain, username and ssh private key :p12:06
momomo ai want something that works ... like ssh config12:06
jesus12:06
cbreak momomo: why cd?12:06
dav1d read the docs then12:06
gxt joined12:06
cbreak momomo: just use paths12:06
momomo so i can git config --local after12:06
cbreak momomo: no need12:06
momomo: use --git-dir12:06
paths ftw.12:06
pulse joined12:07
momomo cbreak git clone --git-dir [email@hidden.address] >12:07
?12:07
cbreak ... no...12:07
momomo: man git12:08
gitinfo momomo: the git manpage is available at https://gitirc.eu/git.html12:08
cbreak it lists how --git-dir is used12:08
it also has --work-tree12:08
momomo: there's also -C, which is probably most useful for you12:08
momomo if i could suuply that ... then i could also cd .. so how is that going to help me?12:08
cbreak because you don't have to cd12:08
momomo either way that is not the issue12:09
the issue is knowing what was just cloned12:09
cbreak you just cloned it...12:09
momomo we are talking about automating this shit in a scirpt12:09
cbreak yes, so it's even easier to remember12:09
store it in a shell var or something12:09
with git clone, you either tell it where to clone the repo12:10
momomo so... i would have a function.... my.git.clone "big-url" .... that function will git clone ;;; then cd ... then git config --local ...12:10
cbreak or it clones it into the current working dir12:10
momomo it could also fail12:10
cbreak yes... so sad... much crying.12:10
if it fails, you don't have to do anything afterwards other than to complain about it12:10
momomo cbreak you obviously do not know how to write safe code12:11
cbreak check the exit status of git clone12:11
honestly, this is shell scripting basics12:11
momomo cbreak exactly this is so much more hard work now ... because if the fucking git command could just be a bit smarter it could cd in to whatever i just did or give me the directory that was just created12:11
instead I have to figure it out and parse it12:11
cbreak no need to parse anything12:12
you know where it clones stuff12:12
either because you tell it, or because it uses the default12:12
momomo Here is a thread for your interest:12:12
https://stackoverflow.com/questions/59392153/git-clone-and-cd-into-it12:12
None of those answers look reliable enough to me12:12
cbreak if you tell it: remember it12:12
otherwise: just get the basename. done.12:13
momomo unless there is a supplied argument12:13
cbreak ... do you enve read?12:13
if you tell it: remember it <<- this is the supplied argument12:13
you tell it.. via a supplied argument12:13
momomo I can try ... wait12:14
cbreak and otherwise: use basename12:14
momomo I don't want to force the argument all the time12:14
DaNeenjah joined12:14
cbreak then don't force it...12:14
gxt left12:15
FinnElija left12:15
cbreak you know how to use basename?12:15
REPO_NAME=$(basename "${REPO_URL}" .git)12:15
momomo Have not tried this yet, but wil now:12:16
https://www.toptal.com/developers/hastebin/nocobupoxa.bash12:16
cbreak REPO_DIR=${1:-${REPO_NAME}}12:16
all trivial shell scripting12:16
FinnElija joined12:16
momomo it worked12:16
FinnElija left12:16
FinnElija joined12:17
momomo the issue is that i believe git should apply an argument that is called --follow ... now i have to have some weird bash interface to get to git stuff12:17
cbreak also, the if $? isn't proper12:17
momomo also copy and paste from github page will likely continue to be an issue12:17
tirnanog that loses the exit status of git. git clone ... && cd ... would make more sense.12:17
gxt joined12:17
cbreak you'd do something like git clone ... && git -C config ... && ....12:17
chaining with &&12:18
if you want to use if, then you'd do if git clone ... ; then12:18
k1773__ left12:18
furrymcgee you can not cd the parent process12:18
cbreak tirnanog: no need12:18
tirnanog: cd isn't required12:18
do you people even read? :/12:19
momomo the $? is the status code12:19
I can try it12:19
bookworm cbreak: why are you bothering... it doesn't stick12:19
cbreak $? is the status code, yes12:19
momomo: but you're making an integer to string conversion and then comparing exit codes as string. This bothers my type safety senses.12:20
momomo works12:20
everythiiing is a string in bash12:20
I was able to get both error and success states:12:20
https://www.toptal.com/developers/hastebin/zozalumiwu.bash12:20
G30RD13 left12:21
cbreak exit codes are numbers, not arbitrary strings12:21
tirnanog there is no type-safety concern there. that's just nonsense.12:21
pretty_dumm_guy joined12:22
tirnanog the most meaningful criticism that can be levelled at it is that it throws away the exit status value of git itself.12:22
momomo I can store it aside and return it .. but i mean .. i don't really care ... but so would the && cd .. approach as well12:23
cbreak the correct way to compare numbers if you want to use $? would be via if (( $? == 0 )), an actual numeric comparison12:23
furrymcgee git can not follow12:23
tirnanog it makes absolutely no difference for comparing $?12:23
momomo cbreak so in my mind rather than learn to ( ( and then when to do what .. i treat eveyrthing the same .. .i am a much happier coder12:24
i don't have to bother with nuances and special cases12:24
cbreak a sledge-hammer programmer12:24
sure, it works... but... :P12:24
furrymcgee you need cd $(git clone -v ... |& grep ... )12:25
cbreak the output of git clone isn't supposed to be script-usable12:25
it can't be relied uppon12:26
also, you don't need cd.12:26
furrymcgee please done make this warning in output12:26
tirnanog momomo: fine. obviously, it's your call. that's not correct, though. foo && bar would not lose the exit status of foo in the event that it fails.12:27
dionysus69 joined12:30
lpapp joined12:33
lpapp hi, when my topic branch is based on a branch, e.g. "dev", and dev changes rapidly12:33
and I pull into dev, rebuild dev12:33
momomo I changed it to : https://www.toptal.com/developers/hastebin/riwegiqate.bash12:33
lpapp then I would want to rebase my topic branch based on the latest dev12:33
but is it better to recreate the topic branch and apply the changes on top instead of rebase?12:34
The reason why I am asking this is because I am wondering if that resulted in fewer rebuilds?12:34
momomo https://www.toptal.com/developers/hastebin/qixuqabizo.php12:34
lpapp it seems that git rebase generates a lot of rebuilds12:34
Murr left12:34
lpapp even though I rebuilt dev12:34
Murr joined12:35
lpapp and my change is only some example, so would not expect many rebuilds.12:35
bookworm what's a rebuild for you? CI?12:35
lpapp so, I guess git rebase dev would update timestamps or so, otherwise so many jobs (5000+) is not sensible.12:35
no, it is all local12:35
bookworm git doesn't build, rebasing will only touch files which it has to12:35
so if you modified those, sure. If it's just an example your doing something funny12:36
you're*12:36
coot left12:36
lpapp I am not doing anything funny, really.12:37
it is a simple git rebase dev regenerating 5000 jobs12:37
which I would not expect at all12:37
bookworm what is a "job" ?12:37
lpapp given that my change is an example at the very top of the stack everything is built12:37
yes, when you build software, it is measured in jobs...12:37
especially c/c++ with ninja.12:38
kevr left12:38
bookworm a build can be anything from make to meson to some crazy script you build yourself, the word has no meaning ... ah, there we go12:38
cbreak lpapp: rebase works by rebasing your history on top of other history12:42
lpapp: so you're switching to the new base, and change all files that have changed in your history since then12:42
then every single commit gets replayed, changing all files12:42
(obviously only all files the commit touched)12:43
so if your branch history changed lots of files, lots of files will be changed while replaying your branch history12:43
lpapp: if you don't want that, merge.12:43
kevr joined12:44
cbreak lpapp: but really, you should create git history for readability, not some nonsense like "less files to rebuild"12:44
if you care about that, use ccache or so12:44
lpapp As I already said, I only changed examples.12:45
Yet, I am getting 5000+ jobs from the framework itself.12:45
which I would really not expect on rebase.12:45
I would expect my example to be rebuilt12:45
momomo furrymcgee what do you mean you do not have to CD ?12:46
lpapp since I already rebuilt the framework in dev12:46
it has nothing to do with git history though12:46
vicecea joined12:52
Sulky_ left12:58
fossdd left12:58
furrymcgee cd only changes the current process, if you do this in git it wont cd the shell12:59
cbreak lpapp: I'd expect everything to be rebuilt that changed since the branch branched off12:59
lpapp: since the whole branch you rebase will be rebased by replaying all its commits' changes on top of the new base12:59
and obviously, everything that changed in the new base compared to the old base will ALSO change13:00
fossdd joined13:01
lpapp right, so this is the sorry state.13:03
cbreak it's expected :)13:04
lpapp will it be quicker to do git switch -C new13:04
and then just apply the example change there without rewriting previous history?13:04
hopefully, that will not regenerate 5000 jobs for me.13:04
cbreak that's what happens when you rebase13:04
lpapp are you sure?13:04
I mean in worst case, I could always do git apply instead of git am if that helps13:04
cbreak git checks out the new base, then effectively git cherry-picks all the commits of the branch you want to rebase13:04
lpapp but I thought that would not really touch any of the previous history at all13:05
cbreak it will touch all history of the branch you rebase13:05
lpapp the problem is that it generates 5000 jobs really13:05
cbreak otherwise it couldn't shove in new history before it13:05
lpapp rebuilding the example should be 313:05
not 500013:05
cbreak lpapp: not a git problem13:05
lpapp since I already build the framework in dev13:05
it is13:05
it very much is13:05
cbreak your build system obviously thinks files that changed change time have to be rebuilt13:05
lpapp if I apply the changes manually in dev, there is not really 5000 jobs13:05
cbreak even if the content ended up being the same after changing it around a few times13:05
lpapp and that *is* the issue git generates with git rebase13:06
cbreak no13:06
lpapp which is what I want to avoid13:06
cbreak it happens if you change the file the same way git does without git too13:06
lpapp hence my original question13:06
cbreak you can avoid it by using a smarter rebuild logic13:06
like ccache does13:06
using content instead of just time13:06
lpapp why would I ever change the files the same way without git - does not make any sense13:06
Again, my question is still on and adept13:07
cbreak lpapp: git only touches files it has to change because the content in them changed13:07
lpapp: can you give me an example command you would run for rebasing?13:07
lpapp I already did13:08
there is not really anything magical about it, it is just plain git rebase dev13:08
I think I will avoid git rebase in this way, it sounds wasteful to me.13:08
cbreak so, you should at least expect all the files in git log --name-only dev.. to change, and additionally all in git log --name-only ..dev13:10
lpapp they will change timestamps13:10
that is the problem13:10
cbreak no13:10
it's required13:10
because they also change content13:10
lpapp yes, so the solution seems to be what I suggested13:10
git switch -C13:10
cbreak if you add a -p, you see which content changes13:11
lpapp git apply/am13:11
cbreak lpapp: no...13:11
lpapp as opposed git switch topic;git rebase dev13:11
yes13:11
...13:11
cbreak because that's exactly what git does...13:11
lpapp no....13:11
git switch topic;git rebase dev rewrites the content and history13:11
git switch -C;git apply/am does not....13:11
-5000 jobs13:11
for me, for my laptop, for the heating of my room, and for the planet.13:11
it does not sound like git rebase is useful for base branches changing rapidly.13:12
it is more sustainable to recreate the topic branches after the base branch is rebuilt13:12
elkalamar left13:12
lpapp or update both branches build the build13:13
git pull --rebase in dev, then git switch topic; git rebase origin/dev13:13
and then rebuild in one of the branches13:13
that way, perhaps the double rebuild can be avoided13:13
cbreak lpapp: have you ever tried it even?13:13
lpapp tried what?13:14
cbreak git rebase topic --onto dev13:14
lpapp what are you trying to achieve?13:14
cbreak it will rebase topic onto dev13:14
lpapp how is that different from git rebase dev?13:14
cbreak git rebase dev will rebase the current branch13:15
lpapp ah, git switch -C would not change the file contents back13:15
before doing the git rebase dev13:15
yes, I guess if that is the case, you could run that command after the build in dev and before git switch -C to avoid the rebuilds13:15
that is another approach, I guess13:15
cbreak lpapp: if you really want to avoid changing to the topic branch13:15
lpapp This is my workflow:13:15
cbreak lpapp: also take a look at git cherry-pick, it can cherry-pick ranges of commits13:15
lpapp 1) I rarely contribute to Qt13:16
2) I git pull --rebase dev13:16
cbreak for example, git cherry-pick ..topic13:16
lpapp 3) dev is a rapidly changing branch by all Qt devs13:16
cbreak that should give you all commits in that branch13:16
lpapp 4) I create a topic branch after dev build13:16
cvmn joined13:16
lpapp 5) Make the changes13:16
6) Build13:16
7) Submit13:16
8) They give reviews13:16
9) In a week or so when I get free time again, I finish the change13:16
10) I git pull --rebase dev again13:16
11) I rebuild dev13:17
12) I want to rebuild the topic as well and update my change based on the reviews13:17
13) Test13:17
14) Submit13:17
the problem happens at the moment between 11-1213:17
in a week, 5000+ ninja jobs are guaranteed13:17
I guess there are a few solutions to a sustainable green solution:13:17
MatthewAllan93 joined13:18
lpapp 1) Recreate topic after 11)13:18
2) git rebase topic --onto dev13:18
13) git pull --rebase and git rebase dev before building dev13:18
3) git pull --rebase and git rebase dev before building dev13:18
cbreak lpapp: why bother rebasing dev? or rebuilding dev?13:19
lpapp in 12), I only want to rebuild the absolutely necessary rather than everything that has changed.13:19
bookworm your problem starts at 10), why are you rebasing on dev? Just add more work on the topic branch13:19
cbreak is it not enough to only worry about your own stuff?13:19
lpapp cbreak: because my change has to be functional and not break anything?13:19
of course not...13:19
cbreak lpapp: yeah, so?13:19
lpapp any recenet change could break my change...13:20
cbreak git fetch13:20
lpapp I could even introduce a build break...13:20
api changes in dev13:20
cbreak lpapp: so?13:20
lpapp and my change does not account for that...13:20
cbreak that's not your problem13:20
that's theirs13:20
lpapp "so?" ???13:20
cbreak you don't need to build dev in isolation13:20
just your changes13:20
so you can fetch the new dev13:20
then rebase onto it13:20
without ever checking out your local dev branch13:20
and without ever building your local dev branch13:20
you'd always stay on your own branch, and never change any files because of the switching around13:21
(so you wouldn't rebase onto your own dev branch, but origin/dev, or what ever your remote is called)13:21
lpapp Again, I have to always provide a change against the latest dev13:21
cbreak so?13:21
this will do that13:21
lpapp Moreover, I am branching off other topic branches, too13:22
so, dev must be always up to date13:22
I have 5-6 topics going on at the moment13:22
cbreak why? you can use origin/dev13:22
lpapp I do not think dev or origin/dev makes any difference here.13:23
cbreak checking out dev, updating it, then checking out something based on old dev is the problem13:23
lpapp and git pull --rebase is certainly nicer and more mainstream, and less error-prone therefore, than git fetch13:24
yes, but I already gathered 3 solutions above13:24
cbreak git fetch is... very mainstream13:24
everyone uses it, whether they know it or not :)13:24
bindu left13:24
lpapp it is plumber13:24
bookworm no?13:24
I use fetch frequently13:25
chexum left13:25
bookworm I just want to fetch the new state, not do anything to it13:25
cbreak lpapp: you can use git remote update if you want. It basically does the same13:25
coot joined13:25
bindu joined13:25
chexum joined13:25
lpapp what exactly is wrong with git rebase topic --onto dev though?13:26
cbreak it's not wrong.13:26
lpapp then why bother with fetch13:26
cbreak but it will maybe check out things more than what you want13:26
lpapp why?13:26
then, it is wrong :)13:26
cbreak you seem to be very alergic to checking things out, because the checking-out will touch all the files that changed13:26
and files changed13:26
lpapp: have you ever used ccache?13:27
lpapp well, I thought you suggested git rebase topic --onto dev because if I do that before git switch -C, surely, files will not change other than my examples13:27
git switch*13:27
cbreak it'd be done instead of the checkout13:27
(but it might do the checkout itself... maybe...)13:27
lpapp: for sure, git cherry-pick of a range of commits (like your whole branch) will NOT check out anything13:28
lpapp so, your suggestion is git fetch, git switch topic, git rebase origin/dev?13:28
it is one commit13:28
there is not really a range of commits13:28
elkalamar joined13:28
mackerman You aren't appreciating that rebase is re-appling new commits from a common ancestor13:28
lpapp this is what I started the whole thing with: git switch -C new-topic; git am/apply the existing topi change13:29
or just git cherry-pick old-topic13:29
MajorBiscuit joined13:29
cbreak lpapp: I have several suggestions, you'll have to try which one suits you.13:29
lpapp this original alternative I suggested works13:29
I tried this out13:30
cbreak for git cherry-pick, don't forget the two dots13:30
lpapp but I am open to learn how git fetch improves anything here13:30
cbreak git cherry-pick ..topic13:30
the two dots mean "all commits from the current branch to topic"13:30
mackerman fetch allows you to diff to the remote tracking branch, without unconditionally rebasing to it13:32
maryo I have migrated my SVN Repo to GIT and while pushing I am getting this error "remote: error: GH001: Large files detected. You may want to try Git Large File Storage"... Is there a way to remove that single file and push it back?13:32
ikke !filter-repo13:32
gitinfo A new git add-on that greatly improves on git-filter-branch: https://github.com/newren/git-filter-repo13:32
cbreak maryo: do you know git lfs?13:32
instead of removing the file, you could use it. (that's what the error suggests)13:33
lpapp cbreak: is it just plain git fetch or do I need some options13:33
cbreak lpapp: git fetch alone will update stuff already. You can pass options if you want to restrict it.13:33
maryo cbreak, I could see it is a log file someone had committed to SVN Earlier by mistake and now when I migrated my SVN Repo to GIT the same got included. Instead of including it, I am checking whether that can safely removed from the repo13:34
ikke git fetch just updated remote tracking branches13:34
cbreak maryo: ok, then it's probably better to just kick it out.13:35
in addition to the link ikke gave you, there's git filter-branch, an old-school way to try to deal with this, or git rebase -i13:35
lpapp so git fetch; git rebase origin/dev will be enough13:36
cbreak the latter will only really work well if it's a more recent commit, and you don't have complicated history13:36
lpapp: yes, as long as ou don't switch branches13:36
lpapp: but if you ever switch to an other feature branch, which has the old dev as basis...13:36
or even if you ever go to the old dev directly...13:36
FinnElija left13:37
gxt left13:37
ikke If you want to do git fetch; git rebase, then you can also do git pull --rebase13:37
Sulky joined13:37
ikke the advantage of fetch is that you can inspect what the remote has before you intergrate it13:37
cbreak ikke: that won't rebase onto other branches though13:37
ikke correct13:37
cbreak I would try git rebase --onto origin/dev thefeaturebranch13:38
FinnElija joined13:38
ikke (I missed the context :P)13:38
coot left13:38
lucas_ta joined13:38
cbreak I really would recommend ccache though :) it solves the problem in a much more sustainable and reliable way13:38
if you can get it to work13:39
gxt joined13:40
maryo cbreak, I am trying this but I am not completely sure of what it is doing --> "git filter-branch -f --index-filter 'git rm --cached --ignore-unmatch log/jd-messenger-application.log' --prune-empty --tag-name-filter cat -- --all".. Do you see any issues with this command?13:42
ikke No, should be fine13:43
cbreak looks fine, yes13:43
well, if you want to remove the file log/jd-messenger-application.log13:43
fossdd left13:43
ikke and13:43
using --tree-filter is faster than --index-filter13:43
cbreak no13:43
ikke ?13:43
cbreak --index-filter is faster13:43
--tree-filter has to check out all the files13:44
ikke ooh13:44
cbreak --index-filter just updates the index13:44
ikke yeah13:44
fossdd joined13:44
ikke working tree13:44
chexum left13:45
gxt left13:45
bindu left13:45
cvmn left13:45
chexum joined13:46
bindu joined13:47
FinnElija left13:47
cvmn joined13:48
lgc joined13:49
lgc left13:52
lucas_ta left13:53
lucas_ta joined13:54
lucas_ta left13:56
lucas_ta joined13:56
coot joined13:57
atrigent_ joined14:00
DF32 left14:03
lpapp I really do not know how ccache is more sustainable which required extra installation, but also caches, but there is no need for caches in the first place14:07
ikke It means you have to care less about things changing stat info of files14:08
adanwan left14:08
lpapp yes, but if I care, it is more sustainable because I do not need extra software and caches14:08
hoochmonger left14:08
adanwan joined14:08
lpapp so, I personally prefer to care about what I am doing.14:09
GNUmoon left14:10
GNUmoon joined14:11
gxt joined14:13
FinnElija joined14:13
ajfriesen joined14:14
rickay joined14:15
rickay left14:16
rickay joined14:16
atrigent_ left14:16
rickay left14:16
rickay joined14:17
keypusher joined14:17
rickay left14:17
rickay joined14:18
rickay left14:18
adanwan left14:18
adanwan joined14:18
rickay joined14:19
rickay left14:19
hoochmonger joined14:20
atrigent_ joined14:21
dionysus69 left14:23
loulou_ joined14:23
loulou_ left14:23
loulou_ joined14:23
cvmn left14:24
lolok left14:25
bindu left14:27
elkalamar left14:27
squirrel joined14:28
bindu joined14:28
atrigent_ left14:28
maryo cbreak, I have deleted the file and pushed the repo to Git. When I compare the total commits `git rev-list --all --count` it shows 15278..Whereas total revisions in SVN is 37500.. So does that mean, I am missing some commits ?14:33
coot left14:36
cbreak maryo: possibly.14:37
I don't know how svn revisions work.14:37
maybe some got skipped?14:37
loulou_ left14:37
cbreak --prune-empty above will remove empty commits too14:37
and maybe you didn't import branches from subversion either14:37
svn is kind of dumb, all repos on a server share revision numbers14:38
and all branches are just subdirectories in weird places14:38
thiago joined14:39
off^ left14:39
maryo cbreak, is there a way to see the total count of empty commits in a repo?14:42
sakitami left14:44
cbreak maybe by searching for them...14:46
there should be none14:46
skapata joined14:47
skapata left14:47
skapata joined14:47
dflick__ left14:48
adanwan left14:49
adanwan joined14:50
gast0n joined14:53
dflick__ joined14:56
G30RD13 joined14:58
G30RD13 left14:58
mon_aaraj left14:59
alfredb left15:00
mon_aaraj joined15:01
MiguelX413 left15:02
MiguelX413 joined15:03
vitali64 joined15:05
chexum left15:09
chexum joined15:09
madewokherd joined15:18
madewokherd` left15:20
lxsameer joined15:22
coot joined15:27
zebrag joined15:27
hamburgler joined15:28
nate4 joined15:28
bloody joined15:31
nate4 left15:33
alfredb joined15:34
rkta left15:35
dionysus69 joined15:39
thebombzen left15:39
zachel joined15:44
maryo left15:45
pulse left15:49
loulou_ joined15:50
loulou_ left15:50
loulou_ joined15:50
ferdna joined15:52
structoha joined15:55
kevr left15:58
kevr joined16:00
sudoforge joined16:01
rgrinberg joined16:02
node1 joined16:04
___nick___ left16:05
vysn joined16:10
fflam joined16:10
coot left16:12
m0viefreak left16:12
loulou_ left16:14
___nick___ joined16:16
mon_aaraj left16:19
mon_aaraj joined16:21
node1 left16:22
jazzy joined16:23
node1 joined16:23
ferdna left16:23
node1 left16:23
atrigent joined16:30
structoha left16:32
dav1d joined16:33
atrigent left16:35
thiago left16:35
elkalamar joined16:40
elastic_dog left16:53
lpapp left16:54
elastic_dog joined16:58
fflam left16:58
dflick__ left17:00
fflam joined17:01
rkta joined17:01
dnh joined17:04
dav1d left17:04
dav1d joined17:05
dnh left17:06
mon_aaraj left17:07
rgrinberg left17:08
elkalamar left17:08
mon_aaraj joined17:09
dav1d left17:12
adanwan left17:13
dav1d joined17:14
adanwan joined17:15
bindu_ joined17:16
gxt_ joined17:16
bindu left17:16
FinnElija left17:16
FinnElija joined17:16
chexum_ joined17:17
chexum left17:17
gxt left17:17
wakeup joined17:25
loulou_ joined17:26
loulou_ left17:26
loulou_ joined17:26
atrigent joined17:26
squirrel left17:29
erarnitox joined17:30
atrigent left17:37
coot joined17:38
tsraoien joined17:41
loulou_ left17:42
bindu_ left17:44
konrados left17:45
bindu_ joined17:46
rgrinberg joined17:46
Jong joined17:48
wakeup left17:51
otisolsen70 joined17:59
jonosterman left18:04
rgrinberg left18:06
tirnanog left18:06
structoha joined18:07
structoha left18:07
coot left18:08
thebombzen joined18:10
Ragnor joined18:11
dionysus69 left18:14
sp0ck joined18:15
vdamewood left18:19
atrigent joined18:21
junebug joined18:22
Ragnor left18:23
atrigent left18:25
iomari891 left18:28
pulse joined18:34
Murr left18:34
Murr joined18:34
crabbedhaloablut left18:35
adanwan left18:35
GNUmoon left18:35
bindu_ left18:35
gxt_ left18:35
bindu_ joined18:36
adanwan joined18:36
crabbedhaloablut joined18:36
gxt_ joined18:36
GNUmoon joined18:37
junebug left18:39
sp0ck left18:39
adanwan left18:40
adanwan joined18:41
tyson2 left18:41
crabbedhaloablut left18:43
crabbedhaloablut joined18:43
igemnace left18:47
rickybob joined18:49
rickybob left18:50
YuGiOhJCJ joined18:50
rickybob joined18:51
Sazhen86 joined19:01
w4 joined19:09
rhe joined19:14
___nick___ left19:17
___nick___ joined19:19
___nick___ left19:19
hoochmonger left19:20
___nick___ joined19:21
hoochmonger joined19:21
crabbedhaloablut left19:22
crabbedhaloablut joined19:22
lucasta3 joined19:28
lucas_ta left19:29
nate4 joined19:30
off^ joined19:31
nate4 left19:34
forgotmynick joined19:38
lucas_ta joined19:40
lucasta3 left19:41
ackyshake joined19:45
m1dnight left19:50
ackyshake left19:50
elkalamar joined19:51
snac73 joined19:51
m1dnight joined19:51
off^ left19:51
snac73 left19:56
snac73 joined19:58
rickybob left20:01
snac73 left20:03
___nick___ left20:04
vitali64 left20:05
Betal joined20:07
rickybob joined20:08
vysn left20:14
karabaja4 joined20:15
khan joined20:15
dsrt^ joined20:16
khan left20:19
coot joined20:20
khan joined20:20
khanjenkiskhan20:21
jenkiskhankhan20:24
khanjenkis20:25
jenkisjenkiskhan20:25
vysn joined20:26
jenkiskhan left20:27
jenkiskhan joined20:27
elkalamar left20:34
YuGiOhJCJ left20:36
coot left20:42
dionysus69 joined20:49
Linkandzelda joined20:53
YuGiOhJCJ joined20:53
Coop joined20:55
Coop left20:55
Coop joined20:56
dionysus69 left20:56
Coop left20:57
Coop joined20:57
Sazhen86 left21:07
vysn left21:19
kyshoc left21:20
kyshoc joined21:20
kyshoc left21:20
kyshoc joined21:20
elkalamar joined21:20
dnh joined21:20
dionysus69 joined21:22
rawtaz am i missing something, or is git not smart enough to be able to split a bunch of lines which are just additions, on those of them that are just empty lines (separating paragraphs of code) when you're in `git add -p` mode and press "s" for split?21:23
it seems like the simplest thing, split on empty lines21:24
ikke rawtaz: it can only split entire hunks21:26
rawtaz yeah :<21:26
dodo there's e when you need it21:26
rawtaz i will have to go to war with the edit mode21:26
dflick__ joined21:26
rawtaz dodo: yes, i get that :) but it would be splendid it git split on empty lines too, because that would make a lot of sense in a lot of code editing situations21:27
thanks for verifying!21:27
ikke rawtaz: I use emacs, where you can just stage single lines21:30
tig supports that as well21:30
as many other git interfaces21:30
rawtaz hm how does emacs and tig do that? does it run some git command that specifies to just stage a specific line of a file?21:30
FinnElija left21:30
rawtaz either way, it would still be great it git supported this super simple thing with the regular split option21:31
using a third party tool isnt the same thing really21:31
FinnElija joined21:31
EvilDMP left21:31
ikke rawtaz: git interactive add just works with patches21:34
other tools could just construct a virtual file with the expected contents to be staged and add that to the index21:34
zer0bitz left21:36
hamburgler left21:40
dionysus69 left21:40
squirrel joined21:42
coot joined21:44
poprostumieciek joined21:44
poprostumieciek left21:44
gco joined21:45
dnh left21:48
tyson2 joined21:50
dionysus69 joined21:52
dsrt^ left21:59
otisolsen70 left22:00
vitali64 joined22:11
feriman left22:13
zeenk joined22:14
maroloccio joined22:16
dsrt^ joined22:16
forgotmynick left22:18
DaNeenjah left22:20
ghost43 left22:22
ghost43 joined22:23
karabaja4 left22:24
karabaja4 joined22:25
coot left22:27
poprostumieciek joined22:30
poprostumieciek left22:31
coot joined22:31
justmattjustmatt_22:32
justmatt_justmatt22:32
karabaja4 left22:33
karabaja4 joined22:34
bambanxx joined22:42
vitali64 left22:43
lantech19446 joined22:48
dflick joined22:52
kenanmarasli left22:52
rawtaz ikke: ah so thats how they do it22:52
The_Blode left22:52
w4 left22:53
w4 joined22:54
dflick__ left22:55
loulou_ joined23:00
loulou_ left23:00
loulou_ joined23:00
tyson2 left23:03
vdamewood joined23:05
loulou_ left23:11
dionysus69 left23:14
RAMIII left23:15
lantech19446_ joined23:18
gast0n left23:25
typicat left23:28
dflick left23:31
nate4 joined23:31
justmatt left23:32
nate4 left23:36
rickybob left23:41
coot left23:41
zeenk left23:43
Lord_of_Life left23:43
Lord_of_Life joined23:44
lantech19446_ left23:46
lucas_ta left23:47
lucas_ta joined23:47
rickybob joined23:47
eqw joined23:50

Logs Search ←Prev date Next date→ Channels Documentation