IRCloggy #git 2019-05-22

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.

2019-05-22

mat001 left00:00
rustyshackleford joined00:00
fphilipe joined00:00
butterthebuddha joined00:00
butterthebuddha left00:00
rustyshackleford I have a weird problem - do you see any good solutions?00:02
so we have these versioned files00:02
content_0.1.0.json, content_0.2.0.json, content_0.3.0.json00:03
ygivenx_ joined00:03
rustyshackleford but if a changes is made to 0.1.0, it should also be made in 0.2.0 and 0.3.000:03
think this could be scripted?00:04
xcm left00:06
xcm joined00:06
ygivenx left00:07
vishal rustyshackleford: scripted how? as part of some git operation? You can write a script, something like sync_configs, and call it from a hook if needed00:08
rustyshackleford well a script that uses/calls git00:08
vishal but it really depends on how a 'cahnge' is defined, how the 2/3 versions differ from 1 and each other..00:08
rustyshackleford okay lets add another complicated detail00:08
there is a release branch for each00:09
so when we created 0.4.0, we will begin by copying content_0.3.0.json and naming it content_0.4.0.json00:09
further changes to content_0.1.0.json should be merged upstream00:10
but also, should be committed somehow to content_0.(x>1).0.json00:10
vishal sure you can commit to the 0.1 branch and try cherry-picking to the others..00:10
there may be merge conflicts, and you just resolve them00:11
rustyshackleford filename is different unfortunately. I can merge 0.1.0 into 0.2.0. content_0.1.0 will be identical on both branches00:11
but 0.2.0 is now out of date00:11
vishal ah hmm00:11
ygivenx_ left00:11
rustyshackleford so i'm thinking a script that can generate a diff00:11
and somehow add that to the next files00:12
...or is time to reconsider this complicated as fuck approach00:12
vishal I don't think there would be a git native way to do all of it in one fell swoop (commit)00:12
rustyshackleford yeah I don't expect that. But a way to script it would greatly help00:12
vishal just script it externally I'd say (and then commit the updates to each branch as needed)00:12
if the files just contain json, should be doable using bash and jq00:13
rustyshackleford never heard of jq. neat00:14
I was thinking git and bash00:14
vishal yeah it is super useful00:14
rustyshackleford use git to generate a diff or a patch or something00:14
vishal 3jq will even help you learn it00:14
rustyshackleford vishal: do you know any nice tutorials or examples?00:14
vishal hmm parsing jq with bash is a bad idea00:14
err parsing json00:14
diff could work if the changes are always consistent, but they can often fail to apply00:15
if say 4.0 changed independently of older versions00:15
with jq you should be able to so some smarter key/value based checking00:15
rustyshackleford I don't necessarily need to parse it00:16
mattcen left00:16
vishal but it entirely depends on the contents of these files, and the rules that apply w.r.t. what changes and in what manner00:16
rustyshackleford think of it this way: content_0.1.0.json should be mostly a subset of content_.0.2.0.json00:16
I was hoping to merge the files. I might be able to do this without parsing the content of the files00:17
vishal so what happens if you cp 1.0 -> 2.0. then make a new change in 2.0 that isn't in 1.0. then make a fixup in 1.0 that needs to go to 2.0. Your diff can potentially fail to apply in this case00:17
so you need to be smarter based on how you will merge them00:17
and git can't 'figure it out' for you00:17
rustyshackleford yeah idk how the heck this is going to work00:18
vishal and that's where I think parsing and making decisions comes in. But - I could be wrong, and maybe in your use case, a diff will work just fine00:19
in which case, great!00:19
its definitely the simpler option00:19
rustyshackleford so we have a somewhat retarded merging scheme00:19
that I think is the root cause of all this00:19
0.3.0 branches off of 0.2.0 which branches off 0.1.000:19
leb joined00:19
rustyshackleford and we merge everything upstream daily00:19
we tend to have 3 releases in progress at any time00:20
mattcen joined00:20
vishal usually release process is that all development and fixes happens of the main 'master' and fixes get backported (cherry-picked) into older release branches as needed00:20
there are many ways of doing this sort of thing of course00:21
but generally if the process is getting in the way, and if you can change it to not, then by all means you should :)00:21
rustyshackleford this is driven by our business so I don't know a good way around it00:22
moldybits left00:22
butterthebuddha joined00:22
rustyshackleford we want this in the july release, and this other feature in august00:22
so we have july and august releases on separate branches, being worked on simulataneously00:22
cdown joined00:23
mattcen left00:24
vishal developing features on release branches that are intended to also eventually make it to other release branches sounds nightmarish..00:24
CodeHex joined00:25
vishal it is much easier to develop on a 'has all the things' master, make your commits well formed and contained, and then cherry-pick into these release branches as needed00:25
with good commit practices, there may still be conflicts here and there, but they /should/ be manageable00:26
victorqueiroz joined00:26
libertyprime left00:27
ghoti_ joined00:28
fphilipe left00:34
rustyshackleford vishal: I think a backwards approach is better00:37
well... maybe not. sometimes your depedent on other things00:37
but suppose you kept your feature outside of master00:37
until it is done and ready to be released00:37
merge that release branch and then release from master00:37
mattcen joined00:37
dysfigured left00:38
rustyshackleford our release branch is somewhat nightmarish, but fits with how the business works00:38
dysfigured joined00:40
moldybits joined00:40
ghoti_ghoti00:40
butterthebuddha left00:46
butterthebuddha joined00:46
Kaisyu7 joined00:53
yonder joined00:53
vnr left00:55
shawn_dones left00:57
thiago joined00:58
magic_ninja left00:59
cdown left00:59
magic_ninja joined01:00
cdown joined01:00
Sasazuka left01:02
kent\n left01:03
fphilipe joined01:03
kent\n joined01:04
Fusl left01:13
Fusl joined01:14
rjsalts_ joined01:17
rjsalts left01:17
azwieg103 joined01:22
Xeago_ joined01:24
Xeago left01:24
Xeago_Xeago01:25
motoko-chan left01:27
bambanx joined01:28
nic-hartley left01:29
CodeHex left01:36
fphilipe left01:37
durham left01:42
F0rTex left01:44
F0rTex joined01:45
boombatower left01:46
j9_ joined01:48
wildermind left01:51
Xeago left01:52
Xeago joined01:52
watabou_ joined01:53
Goplat joined02:04
lagothrix left02:04
cdown left02:04
lagothrix joined02:04
duderonomy joined02:05
libertyprime joined02:06
cdown joined02:06
jcbitter left02:07
jcbitter joined02:09
magic_ninja left02:11
rjsalts_rjsalts02:11
azwieg103 left02:12
jcbitter left02:14
jcbitter joined02:15
magic_ninja joined02:22
watabou_ left02:26
mattcen left02:30
mattcen joined02:32
j9_ left02:33
kjartan left02:33
zulutango left02:33
fphilipe joined02:33
zulutango joined02:35
Cabanossi left02:36
hugh-adolph left02:36
kjartan joined02:37
Cabanossi joined02:40
spacesuitdiver left02:43
mat001 joined02:51
mattcen left02:56
Enphuego left02:58
victorqueiroz left02:58
butterthebuddha left03:01
fatalhalt joined03:04
butterthebuddha joined03:04
mattcen joined03:05
fphilipe left03:07
wgrant left03:16
wgrant joined03:17
mosh left03:18
Cabanossi left03:24
Cabanossi joined03:24
libertyprime left03:24
milkt joined03:28
alyptik left03:32
sboyd left03:35
kermit left03:39
kermit joined03:44
MACscr left03:46
veegee joined03:49
libertyprime joined03:51
R2robot left03:53
cd left03:53
leprechau left03:56
libertyprime left03:57
leprechau joined03:58
fphilipe joined04:03
Lucas_Gray joined04:11
royal_screwup21 left04:12
scientes left04:19
alyptik joined04:22
watabou_ joined04:23
netj left04:24
regedit_ joined04:24
netj joined04:24
milkt left04:27
butterthebuddha left04:28
regedit_regedit04:30
podlech joined04:35
cdown left04:36
kapilp joined04:41
Mighty_Mel joined04:42
tsdh joined04:44
blackmesa1 joined04:48
blackmesa1 left04:53
ferdna joined04:54
g00s joined04:55
cfoch left05:09
huatou joined05:10
fatalhalt left05:17
fphilipe left05:18
Lucas_Gray left05:18
podlech left05:20
sauvin joined05:21
macrover joined05:23
fphilipe joined05:25
dhendrix left05:26
jimender2 left05:26
cxc99 left05:27
mat001 left05:27
bashfulshell left05:27
blackmesa1 joined05:27
Nizumzen left05:27
rodarmor left05:28
d1rewolf left05:28
rustyshackleford left05:28
rougeth left05:28
PavelB left05:28
ggherdov left05:28
nuck left05:29
egp left05:29
Fenhl left05:29
fury left05:29
SkarmoutsosV joined05:30
Ownix left05:30
jguddas-tr joined05:30
jsatk left05:30
bhelgaas left05:30
Mindi joined05:32
d1rewolf joined05:33
egp joined05:33
jsatk joined05:33
Fenhl joined05:33
bhelgaas joined05:33
rodarmor joined05:33
dhendrix joined05:33
jimender2 joined05:33
rougeth joined05:33
rustyshackleford joined05:33
nuck joined05:33
ggherdov joined05:33
bashfulshell joined05:33
smitop left05:33
PavelB joined05:34
Ivo joined05:34
Ownix joined05:34
Nizumzen joined05:34
fury joined05:34
jguddas-tr left05:34
BeerLover joined05:35
ferdna left05:36
qgTG left05:37
jcbitter left05:39
nowhere_man joined05:42
justanotheruser left05:42
mattcen left05:43
nowhereman left05:45
xelxebar left05:46
xelxebar joined05:46
leeN joined05:47
sozuba joined05:49
mattcen joined05:50
moldybits left05:52
thiago left05:55
mattcen left05:55
thefatma joined05:57
thefatma left05:59
justanotheruser joined06:02
leb left06:02
MACscr joined06:04
Repox joined06:05
macrover left06:12
mattcen joined06:14
z|bandito joined06:15
dartmouthed joined06:16
SkarmoutsosV left06:24
cxc99 joined06:24
Repox left06:24
Noti joined06:25
chele joined06:27
R2robot joined06:28
dege joined06:29
leeN left06:32
durham joined06:33
durham left06:33
mowcat joined06:33
libertyprime joined06:34
bachler joined06:39
nowhere_man left06:40
TomyWork joined06:40
Serus left06:40
freeman42x left06:42
sQVe joined06:42
Puffball left06:45
kjartan left06:45
Serus joined06:48
kapilp left06:49
kjartan joined06:50
Anthaas joined06:56
Anthaas_ left06:56
g00s left06:57
n3wborn joined06:57
nowhere_man joined06:57
g00s joined06:57
Mighty_Mel left06:58
enoq joined06:58
BeerLover left06:59
blackmesa1 left07:00
BeerLover joined07:03
nowhere_man left07:04
BeerLover left07:05
fphilipe left07:13
blackmesa1 joined07:13
Repox joined07:13
libertyprime left07:15
xcm left07:15
libertyprime joined07:16
xcm joined07:17
libertyprime left07:19
yonder left07:20
thefatma joined07:20
interrobangd_ joined07:21
libertyprime joined07:21
sgnls joined07:22
qgTG joined07:25
mathu joined07:27
BeerLover joined07:27
mathu i put out a PR on github, but then decided to take another approach for essentially the same problem. a github FAQ says that force push would corrupt the PR so that's right out - what's the idiomatic git way to correct the PR/branch that i took the wrong approach on? or is it just to close the PR and create another one?07:30
cluelessperson left07:31
dege left07:32
fphilipe joined07:32
Fusl left07:33
Fusl joined07:34
DuckyDev joined07:35
netj left07:37
netj joined07:37
dege joined07:39
mikecmpbll joined07:40
fairuz joined07:41
Anthaas left07:42
SkarmoutsosV joined07:42
Anthaas joined07:42
mathu reading more, sounds like some people on stackoverflow successfully force pushed to a branch with an open PR07:42
yolo let's try it, i don't know that the reviewer has been online since the first update 0:)07:43
gxt left07:45
benharri left07:46
osse mathu: force pushing is correct07:48
from the github FAQ perspective I thin kyou want to "corrupt" the PR in this case07:48
kapilp joined07:49
duderonomy left07:50
mathu yeah, further reading just said the old commits would be unreachable via the web ui. but like, yeah, of course07:50
thanks for confirming osse!07:50
jguddas-tr joined07:50
T_UNIX joined07:54
ghoti left07:55
thefatma left07:57
bolovanos joined07:57
jguddas-tr left08:05
floppydh joined08:05
sozuba left08:06
hiroprotagonist joined08:07
weird_error joined08:12
j7k6 left08:13
ahmed89 joined08:13
thefatma joined08:14
j7k6 joined08:14
jguddas-tr joined08:15
j7k6 left08:15
j7k6 joined08:16
j7k6 left08:16
j7k6 joined08:17
sozuba joined08:17
j7k6 left08:18
j7k6 joined08:18
g00s left08:21
elichai2 joined08:23
Lucas_Gray joined08:24
TJ- joined08:25
dege left08:33
OtakuSenpai joined08:40
Tobbi_1 joined08:40
Tobbi_ left08:40
Tobbi_1Tobbi_08:40
rsrx joined08:42
drbean_ joined08:47
drbean left08:49
MIsAn left08:53
yuljk joined08:53
lacrymology joined08:54
sz0 left08:59
sz0 joined09:00
Murr left09:00
Murr joined09:01
fairuz left09:03
dhollinger left09:03
Lucas_Gray left09:04
gloomy joined09:05
fairuz joined09:05
strudla left09:07
strudla joined09:07
dr_lepper left09:07
nopf left09:07
sybariten left09:07
i9c joined09:08
neunon left09:08
i7c left09:08
nioncode left09:08
Soliton left09:08
dr_lepper joined09:09
hofmann3900 left09:09
i9ci7c09:09
Soliton joined09:10
Lucas_Gray joined09:10
Jackneill left09:10
n3wborn left09:10
Jackneill joined09:11
nioncode joined09:11
blackmesa1 left09:13
hiroprotagonist I was hoping that someone could help me clarify what should happen in a specific sitution?09:17
I inherited a git flow from my predecessor which is based on github flow09:17
https://guides.github.com/introduction/flow/09:17
dhollinger joined09:17
hiroprotagonist There is a scenario where we create a feature branch and work on that. Before this is merged in work continues, branches created, merged in to master and deployed.09:18
when it comes to merging the original branch we do a git pull origin master --rebase on the branch, then on master and then merge.09:19
this seems to be working well and makes sense and creates a nice graph.09:19
weird_error left09:19
hiroprotagonist The scenario I am asking about it when the feature branch has remote tracking. When we do the rebase the tracking gets out of sync. Is it reasonable to do a force push for the feature branch with tracking ?09:20
bambanx left09:20
hiroprotagonist Does this even make sense?09:20
fairuz left09:23
catsup left09:24
catsup joined09:24
catsup left09:25
catsup joined09:25
Goplat left09:29
DuckyDev left09:31
hellauer joined09:31
zamba left09:33
zamba joined09:35
BeerLover left09:42
arecaceae left09:43
arecaceae joined09:43
hyperair joined09:46
SilentGhost hiroprotagonist: it depends how your ci/cd is setup, I'd say. purely from git perspective, if you're going to delete the branch upon merging you don't need to push, you'd have to use -D when deleting though, but that's a small difference. Naturally, if you want to verify your code in the new state, or perhaps you're in the middle of code review, then pushing is a must.09:48
mowcat left09:48
yuljk left09:50
yuljk joined09:51
mms_ joined09:51
mms_ I am doing git clone for same repo and on cygwin I get all folders but on git bash I am getting just one folder09:51
can one help troubleshoot/fix this09:51
DuckyDev joined09:52
jacobat joined09:53
mms_ I did fetch and pull still nothing happened09:54
jacobat Is it possible to edit files in a remote git repository without cloning it locally first??09:54
osse mms_: what do you mean by "get all folders" ?09:54
hiroprotagonist SilentGhost: we have no ci/cd setup presently. It is normally an issue when in the middle of a PR. I suppose just communicate to the team that a force push will happen.09:54
osse jacobat: not via git itself. github has this feature09:54
jacobat osse: I was expecting as much. Thanks.09:55
SilentGhost hiroprotagonist: you could wait till the end. it's not clear why you need to do rebase before code review is over09:55
mms_ osse: when I clone on cygwin I see many folders which are there in repo09:56
osse mms_: is that a way of saying you cd into the repo and run ls ?09:56
mms_ osse: yes09:56
blackmesa1 joined09:56
hiroprotagonist SilentGhost: Waiting until the end will be fine in most scenarios, however if there are a lot of changes on master then the rebase could get a hairy.09:57
osse mms_: !repro09:57
gitinfo mms_: [!transcript] Please paste (using https://gist.github.com/ or similar) a transcript ( https://git.io/viMGr ) of your terminal session so we can see exactly what you see09:57
hiroprotagonist SilentGhost: Keeping the feature branch up to date as we go along feels better apart from the force push09:57
milkt joined09:58
SilentGhost hiroprotagonist: if you're working alone it's not a problem at all, the possible conflicts would have to be resolved sooner or later. I don't think doing multiple rebases simplifies things09:58
mms_ osse: https://gist.github.com/imiten/d6d7407a751e60c8dc3549fca4d10b1509:59
BeerLover joined10:00
mms_ osse: different user on different laptop trying git clone and gets just one folder10:00
ikonia_ikonia10:00
jacobat left10:00
lankanmon left10:01
hiroprotagonist SilentGhost: What I have been worried about is that there is a better(tm) way of doing this or not doing this at all. I don't know anyone else who uses git really :) but it sounds like I am not missing anything10:01
osse mms_: if you don't have the equivalent output from the other computer I cannot compare10:01
mms_ ok wait10:01
osse also, are you cloning a repo then switching to a different folder?10:03
or are ~/tmp and /cygdrive/d/work/tmp the same?10:04
mms_ osse: check now10:04
osse: updated the git10:04
osse: gist I mean with other user data10:06
osse why cd d: ?10:07
veegee left10:08
mms_ its cygwin10:11
osse: its same as /cygdrive/d10:11
osse: cygwin thing of file system10:12
osse ok, so you're cloning the repo then cd'ing somewhere else?10:12
mms_ osse: no....its same place10:12
osse when did you not just cd Release like you did on the laptop?10:12
mms_ osse: there are two outputs in that gist. one from my laptop with cygwin and other is from colleage laptop with git bash10:13
osse: d: etc. is from my laptop and c: is from colleage laptop10:13
osse: Sagar is colleage and I am Miten10:13
osse Yes I realize that10:14
watabou_ left10:16
osse I just don't understand why you cd back and forth10:20
Basically I don't trust the gist10:20
yyy- joined10:21
mikecmpb_ joined10:21
mms_ osse: if know some troubleshooting command share10:22
osse: not sure about your comments.....its 2 outputs shared in that gist...10:22
osse in both repos, run: git rev-parse HEAD; git ls-tree HEAD10:22
mms_: My comments (and questions you didn't answer) is why you cd d: then cd here and there back and forth when you could have just done cd Release after cloning like your colleague did10:23
mms_: Because it looks to me like you run ls in a different folder10:23
mikecmpbll left10:23
Newami left10:24
mms_ osse: I clonded in d:/work/tmp10:27
osse why does the prompt say ~/tmp then?10:28
mms_ osse: its just file system thing way cygwin shows it....its has its own /home/....10:29
osse So /home/Miten.Mehta/tmp and /cygdrive/d/work/tmp are the same folder?10:31
mms_ osse: they are different10:31
osse: I wanted to clone in /cygdrive/d/work/tmp so I went there and did clone10:31
osse no you didn't10:32
not according to the gist10:32
you cloned first, then changed folders10:32
regedit left10:33
mms_ osse: which line is confusing you ?10:34
WhiskerBiscuit joined10:35
jguddas-tr left10:35
settermjd joined10:35
mms_ osse: let me come back with one more try10:36
mms_ left10:36
mikecmpb_ left10:36
mikecmpbll joined10:38
dartmouthed left10:39
mms_ joined10:44
mms_ osse: updated gist10:44
osse: noticed that on Sagar laptop the git clone is doing checkout step but on mine it does10:44
gloomy left10:46
mms_ hi git clone command is not doing the checking out files phase10:46
gloomy joined10:47
gloomy left10:47
BeerLover left10:48
watabou_ joined10:48
gloomy joined10:49
gloomy left10:49
gloomy joined10:52
planetcall|work joined10:52
gloomy left10:52
lankanmon joined10:54
fairuz joined10:54
fairuz left10:55
osse mms_: now it makes sense10:58
can you run git rev-parse HEAD; git ls-tree HEAD in both?10:58
mms_ left10:59
igemnace left11:01
jguddas-tr joined11:02
settermjd left11:04
TJ- left11:09
elichai2 left11:12
mms_ joined11:12
mms_ hi on some laptops the repo is not cloning full11:12
madprops left11:13
mms_ how to troubleshoot why its not downloading all folders11:13
osse can you run git rev-parse HEAD; git ls-tree HEAD in both?11:14
blackmesa1 left11:17
ahmed89 left11:17
osse and git status11:20
watabou_ left11:22
blackmesa1 joined11:23
devish joined11:26
devish Is there a way to delete a branch (remote) such that it cannot be recovered?11:26
ricekrispie2 joined11:27
_ikke_ no, not without having direct access to the remote repository11:27
devish I have complete access11:28
mms_ left11:28
ricekrispie left11:29
grawity first just delete the branch as normal, then run `git reflog expire --expire=now --all` and `git gc --prune=now` on the server-side repo11:29
pR0Ps_ joined11:29
blackmesa1 left11:29
grawity (commands copied from github's "oops sensitive data" article)11:29
pR0Ps left11:29
pR0Ps_pR0Ps11:29
devish cool...thanks11:30
gxt joined11:32
blackmesa1 joined11:38
Jackneilll joined11:43
Jackneill left11:47
shawn_dones joined11:49
Murr left11:53
Murr joined11:54
delboy1978uk joined11:55
delboy1978uk hi guys o/11:55
is there a way of undoing a commit, and leaving the actual changes in place as uncommitted changes?11:55
BtbN git reset11:55
delboy1978uk doesnt that roll back the changes though?11:56
BtbN Only if you do a hard reset.11:56
delboy1978uk ah!11:56
i always do hard resets11:56
cool, let me try, and thanks BtbN11:56
awesome11:57
nowhere_man joined12:00
subopt joined12:04
blackmesa1 left12:10
milkt left12:11
WhiskerBiscuit left12:18
no_gravity joined12:20
no_gravity Hello! I am looking at a commit with "git log -p --word-diff --word-diff-regex=." but it shows me lines with added tabs as completely deleted and added.12:20
I never saw that happen. What is going on?12:21
quackgyver joined12:24
Nawab joined12:25
Nawab left12:27
OtakuSenpai left12:28
OtakuSenpai joined12:28
Repox left12:33
netj left12:34
netj joined12:34
no_gravity Figured it out.12:36
--word-diff --word-diff-regex=. seems to not work for whitespace.12:36
queip left12:37
fendor joined12:41
fendor not entirely git, but how can I reopen a pr that has been merged and reverted afterwards?12:41
Habbie what service?12:42
no_gravity left12:43
_ikke_ fendor: In most cases, you probably have to create a new PR12:43
fendor github12:43
_ikke_ If the branch has been deleted, you cannot open it anyway12:44
jguddas-tr left12:44
fendor _ikke_, but github pr shows that there is no diff12:44
satoriprints left12:44
Habbie then it was not reverted12:44
can you show us?12:44
fendor Habbie, what is the best way to show?12:44
github link?12:44
Habbie works for me12:45
fendor https://github.com/haskell/haskell-ide-engine/commits/master12:45
revert is Revert "Merge pull request #1237 from fendor/add-package-tests"12:45
queip joined12:45
Habbie ok12:45
fendor original pr: https://github.com/haskell/haskell-ide-engine/pull/123712:45
queip left12:46
Habbie ok12:46
and the new pr?12:47
azwieg103 joined12:47
fendor I didnt open one, couldnt since github says there are no differences12:47
Habbie show us that12:48
fendor here is the brnach that got merged: https://github.com/fendor/haskell-ide-engine/tree/add-package-tests/test/unit12:49
mowcat joined12:49
fendor https://github.com/fendor/haskell-ide-engine/tree/add-package-test12:49
https://github.com/fendor/haskell-ide-engine/tree/add-package-tests12:49
benharri joined12:49
fendor https://github.com/haskell/haskell-ide-engine/compare/master...fendor:add-package-tests12:49
Habbie There isn’t anything to compare.12:49
haskell:master is up to date with all commits from fendor:add-package-tests.12:49
y12:49
-y12:49
did you rebase, as was requested?12:49
well12:50
"@fendor Please update this branch to work with current master, and we can merge it again."12:50
it's best to also rebase12:50
fendor Habbie, this request has been reverted in irc.12:51
but yeah, will try it12:51
i fail to correctly rebase it...12:52
queip joined12:53
queip left12:53
dege joined12:55
fendor git rebase master, right?12:56
Kobaz how come i can do git diff origin/1.9:AEL/CoreCallRouter.ael AEL/CoreCallRouter.ael12:56
but not git diff AEL/CoreCallRouter.ael origin/1.9:AEL/CoreCallRouter.ael12:57
oh12:57
prefix with --12:57
git diff -- origin/1.9:AEL/CoreCallRouter.ael AEL/CoreCallRouter.ae12:57
CodeSlingerPaul joined12:59
dege left13:00
kjartan left13:02
xelxebar left13:02
xelxebar joined13:02
courrier joined13:02
rafasc joined13:03
gloomy joined13:04
mowcat left13:04
nowhere_man left13:06
kjartan joined13:07
kenlee joined13:08
devish left13:17
nowhere_man joined13:17
stfn left13:18
jguddas-tr joined13:19
stfn joined13:19
blackswan joined13:19
watabou_ joined13:20
blackswan i am trying to debug a problem with gitlab and setting GIT_CURL_VERBOSE=1 in the environment doesn't seem to do anything.13:20
osse maybe you're using ssh ?13:20
blackswan oh13:21
ok13:21
maybe i don't know what i'm doing is the problem13:21
thx13:21
Silenced joined13:21
osse git remote -v13:21
sQVe left13:21
osse if it's ssh you can use GIT_SSH_COMMAND='ssh -vv' or something like that13:21
blackswan my problem is that i am getting "remote: GitLab: You are not allowed to force push code to a protected branch on this project."13:22
queip joined13:22
pandem use a different branch or unprotect the branch?13:23
blackswan and i do not understand what that means.13:23
howell joined13:23
rafasc blackswan: that's a gitlab setting that pretty much means what it says.13:23
blackswan i didn't protect a branch. not on purpose. i don't know anything about protecting branches.13:23
pandem you can set protected branches on gitlab that you can only merge request to13:23
rafasc you are not allowed to force push into that branch.13:23
blackswan hence my confusion13:23
ghoti joined13:23
blackswan oh13:23
wait. hmm.13:23
jguddas-tr left13:24
rafasc blackswan: probably some setting protects master by default.13:24
blackswan ok, i am an idiot who has not had enough caffeine.13:24
pllong joined13:26
clime joined13:27
yyy- left13:27
clime i just encontered something quite weird13:27
i tried git pull <repo url> master, and expected it will pull new commits as well as annotated tags attached to those commits.13:28
Yet, it did not pull tags13:28
Then i ran git pull <repo url> master --tags and it fetched the tags13:28
yet --tags option for git pull is undocumented and should not even be needed according to --no-tags description13:28
anyone knows what's up with this?13:29
osse are you sure those tags points to commits in master?13:29
clime osse: i would need to check it but i suppose so13:29
osse if they aren't then there is no mystery13:30
yyy- joined13:30
Murr left13:30
clime well, there is still the --tags options, which is not documented...at least in my man pages13:30
rafasc wrt documentation, I guess that could be explained better. The main cause is that pull is fetch+merge and --tags only applies to the fetch part.13:30
clime that's a mystery i think13:31
ok13:31
rafasc if you check git pull -h; you'll see they separate.13:31
clime ok, i can see --tags there13:32
but it is missing in my man pages under 'Options related to fetching'13:32
rafasc has to do with pull forwarding options to fetch. You can send a patch to the mailing list improving the documentation. It's a great first contribution13:32
clime for man git pull13:32
gitinfo the git-pull manpage is available at https://gitirc.eu/git-pull.html13:32
clime ok, cool!13:32
Murr joined13:33
cd joined13:34
clime thanks, i am cloning the repo upstream repo to see to which branch the tag relate13:34
scientes joined13:35
clime but it's probably unnecessary cause i can see it already in my fork...13:35
well, it is attached to a commit, which is in master and that i downloaded before13:36
osse git branch --contains v1.2.3.13:36
does that print master?13:37
clime yes13:37
in the fork it prints * master13:37
osse Which is the same repo you ran "git pull <repo url> master" in ?13:38
rafasc but that means you have the tag in the first place, otherwise it would not resolve v.1.2.3 ...13:38
clime rafasc: i did already git pull <repo url> master --tags, which downloaded the tag13:38
osse: yes13:39
osse then there are signs of mystery13:39
rafasc I think it may be related to the fact you are specifying 'master'13:41
which is resolved to refs/heads/master:refs/remote/remotename/mater;13:41
and the tag following only applies when you do a bare $git pull (?);13:42
clime rafasc: ah, that's probably true13:42
rafasc did not confirm.13:42
clime right, i will try13:42
jguddas-tr joined13:43
clime idk, i need to reclone the repo, which will take a while, i'll confirm later13:43
rafasc clime: make use of --reference: git clone --reference /path/to/old/repo url newclone13:45
so you don't need to transfer objects that already live in your machine.13:45
clime huh, cool13:45
barteks2x joined13:46
rafasc just be aware that it will actually use the objects from the referenced repo if it needs. So don't move it or erase it.13:47
or add --dissociate, which will undo the dependency after cloning.13:48
sgnls left13:49
chymera left13:49
clime ye, with --reference that's much faster13:50
chymera joined13:51
jguddas-tr left13:51
clime so i did only git pull <upstream_url>, ommitting the 'master' but it still did not pull the tag13:52
watabou_ left13:52
clime git pull <upstream_url> --tags did fetch the tag13:53
maybe i need to have the remote for upstream url added13:54
subopt left13:54
rafasc clime: have you checked if you configured git to not pull tags?13:56
clime i tried git config -l, if i see any remote.<name>.tagOpt but didn't see anything like that, will check again13:57
rafasc: it works as expected if i first do git remote add upstream <repo url> and then git pull upstream13:58
Jackneilll left13:58
rafasc interesting.13:58
hit the mailing list. This is either worthy documenting, or a bug.13:59
Jackneilll joined14:01
clime okay, i will try to make a patch for the --tags thing in git pull man pages, i will mention this as well14:02
bluezone joined14:03
watabou_ joined14:11
boombatower joined14:11
barteks2x left14:14
jguddas-tr joined14:17
greggerz joined14:18
liaolijun joined14:19
jguddas-tr left14:24
dege joined14:24
Elon_Satoshi joined14:26
oatmealraisin joined14:26
Copenhagen_Bram left14:28
AtumT joined14:28
kapilp left14:28
spacesuitdiver joined14:30
aweb joined14:31
delboy1978uk left14:33
barteks2x joined14:34
jguddas-tr joined14:35
haasn left14:39
haasn joined14:41
savolla joined14:41
thiago joined14:43
watabou_ left14:44
spacesuitdiver left14:46
cliluw left14:47
cliluw joined14:48
spacesuitdiver joined14:48
spacesuitdiver left14:52
aweb left14:52
cdown joined14:52
floppydh left14:56
Noti left15:01
courrier left15:02
courrier joined15:07
cdown left15:10
thiago left15:11
enoq left15:14
savolla left15:14
sbeyer joined15:15
oatmealraisin left15:16
Murr left15:17
Murr joined15:18
Rh0ndaRhonda15:20
silverballz left15:20
silverballz joined15:21
liaolijun left15:21
raffo left15:22
oatmealraisin joined15:23
libertyprime left15:24
fahadash joined15:25
Phylock joined15:28
dskull left15:28
chele left15:28
dskull joined15:29
aweb joined15:30
gtbuchanan_ joined15:32
nowhereman joined15:32
nowhere_man left15:32
tang^ joined15:35
gtbuchanan left15:35
blackmesa1 joined15:38
watabou_ joined15:40
r1ch joined15:42
hellauer left15:45
jcbitter joined15:45
jguddas-tr left15:46
hiroprotagonist left15:48
interrobangd_ left15:49
nowhereman left15:51
cdown joined15:51
courrier left15:55
bashfulshell left15:55
Lucas_Gray left15:55
BrianBlaze left15:58
BrianBlaze joined15:59
nowhereman joined15:59
BlessJah1Blessjah16:01
blackmesa1 left16:03
thiago joined16:04
thefatma left16:06
Murr left16:06
savolla joined16:06
Murr joined16:07
nowhere_man joined16:09
nowhereman left16:09
APKAKPWD16:11
impermanence joined16:12
torontoyes joined16:12
chymera vishal: so `gpg --sign somefile` works fine16:13
torontoyes I was attempting to git revert to a previous commit16:13
I attempted that 3 times.16:13
rafasc torontoyes: "revert to a previous commit". git revert reverts particular commits, it is not a "go back to this state".16:14
torontoyes When I try to revert, it says Branch is up todate with origin/master16:14
seaef-tnw joined16:14
thefatma joined16:15
vishal chymera: run with GIT_TRACE to try and better track what might be happening16:15
torontoyes rafasc: ohh..ic16:15
how do I revert to a paticular commit?16:15
_ikke_ how far back is that commit?16:15
torontoyes 8 commits16:15
back in time?16:16
rafasc depends if you are willing to rewrite history or not.16:16
edwardly left16:16
_ikke_ So you want those 7 following commits to be gone?16:16
rafasc you can revert all those 8 commits, or reset back.16:16
Repox joined16:16
Lordveda joined16:16
torontoyes I want to reset to a paticular commit and let it build of the state of the files of that commit16:16
achen_ joined16:16
_ikke_ So you want those 7 following commits to be gone?16:16
torontoyes yes16:17
_ikke_ git reset --hard <commit>16:17
where <commit> is the hash of the commit you want to go back to16:17
rafasc ^ will nuke all uncommited changes.16:17
nowhere_man left16:17
hellauer joined16:18
Lordveda If someone wants to step back from one commit to its parent removing the commit but keeping the changed files which git reset options to use?16:18
watabou_ left16:18
thefatma left16:19
rafasc Lordveda: --soft or --mixed, depending if you want the staging area modified or not.16:20
Lordveda explain the staging area plz16:20
rafasc --soft will leave everything untouched, --mixed (the default) will change the staging area.16:20
!book16:20
gitinfo There are several good books available about git; 'Pro Git' is probably the best: http://git-scm.com/book but also look at !bottomup !cs !gcs !designers !gitt !vcbe and !parable16:20
_noblegas joined16:21
Lordveda reading an entire book won't do a fast solution for a problem :)16:21
sgen joined16:21
rafasc Lordveda: staging area, index, cache, are all names to a structure that represents the snapshot of your project.16:21
when you use git add; you are adding changes to the staging area.16:21
Lordveda I want the commit to be reset so that I can re-add the changed files one by one16:22
igemnace joined16:22
Lordveda to the staging area of course16:23
rafasc Lordveda: the staging area is one of the fundamental blocks for day-to-day git. If you are using git, you need to be aware of the existance of this.16:23
chymera vishal: super weird, it seems to have been a temporary fluke, now everything works :-/16:23
at any rate, thank you :)16:23
vishal cheers16:23
rafasc Lordveda: then you want --mixed; or just $git reset;16:23
Newami joined16:24
torontoyes rafasc: Thanks16:24
Repox left16:24
Lordveda rafasc: after I do a git reset without option and do a git status I don't see that my files are changed but I a clean tree16:24
achen_ left16:25
mat001 joined16:25
rafasc Lordveda: then it means your files match that commit.16:26
Lordveda explaining my problem: I have made a commit that includes 2 files, I want to revert back to the previous commit and then add the changes for each file as an entity16:27
So I want the files to be as if they were removed from the staging area as well but keeping the changes to those files, which git reset option would achieve that?16:28
rafasc Lordveda: did you 'add' this files for the first time in these commits?16:29
thefatma joined16:29
Lordveda rafasc: yes16:29
rafasc you may want to use: $git reset -N commit, then.16:29
watabou_ joined16:29
rafasc or do the reset, and use $git rm --cached <file>;16:30
Lordveda what will this git reset -N do?16:30
rafasc I think the latter is better.16:30
Lordveda I know that git reset -N commit will do a mixed reset16:31
I don't get what the -N option do16:31
rafasc the -N, is "intent-to-add", basically it would reset it an empty file.16:31
thus, my suggestion of removing it from the staging area, so you can add it again.16:32
be sure to use --cached, otherwise it will also remove from your directory.16:33
Lordveda so if I want to reset the latest commit, I would issue $git reset -N <-- without any other options?16:33
rafasc if it's the last commit, you can just $git rm --cached <file>; git commit --ammend;16:34
amend*16:34
watabou_ left16:34
Lordveda actually I want the commit which includes the two files to be reset16:34
and then add each file in its own commit16:35
rafasc with reset, you would need to specify "the last commit", git reset HEAD;16:35
Lordveda: git rm --cached file1 file2; git commit --amend; git add file1; git commit; git add file2; git commit;16:35
strk joined16:36
strk what's a quick command to get lits of files changed in a commit ?16:36
rafasc strk: for scripting or for inspecting?16:37
strk scripting16:37
Lordveda rafasc: should I do git co to the parent commit first?16:37
surfist left16:37
tang^ git show --name-only will work16:37
for scripting maybe add --porcelain16:38
UrsoBranco joined16:38
rafasc git diff-tree HEAD~10 --name-status16:38
surfist joined16:39
rafasc tang^: show doesn't have a --porcelain, that's status.16:39
tang^ oh, sorry16:39
Murr left16:40
Murr joined16:41
Kronuz left16:41
rafasc Lordveda: git co; is an alias. I don't know if that's just an alias for commit or checkout, try to avoid referencing aliases when asking for support.16:42
gxt left16:44
thefatma left16:46
theoceaniscool joined16:47
sboyd joined16:48
Lucas_Gray joined16:48
mikecmpbll left16:50
fphilipe left16:51
duderonomy joined16:52
nowhere_man joined16:53
courrier joined16:55
leb joined16:55
aweb left16:56
netj left16:59
igemnace_ joined16:59
igemnace left16:59
TomyWork left16:59
netj joined16:59
sgen left16:59
Fusl left17:00
boombatower left17:00
boombatower joined17:01
nelsnelson joined17:01
Fusl joined17:01
thiago left17:02
wildermind joined17:03
blackmesa joined17:06
seaef-tnw left17:06
seaef-tnw joined17:08
thiago joined17:09
yyy- left17:09
tang^ sounds like an alias for somebody coming from svn17:11
savolla left17:12
Lucas_Gray left17:12
strk the --name-only didn't give me full path, some of them started with .../17:13
git show --name-only, that is17:13
the diff-tree only showed me changed directories17:14
blackmesa left17:14
tang^ heh... I was just trying that myself17:14
kjartan left17:15
osse strk: git diff --name-only commit~ commit17:15
sboyd left17:15
strk thanks, whorks17:16
fendor left17:16
tang^ I need that for building a list of files to copy from my repo to another directory17:17
czart joined17:17
tang^ except for certain exceptions17:17
rafasc for scripting I would avoid using diff.17:18
git diff-tree -r c9cef0a85402768c3b6fc0282dcc7d45a095fcd3 --name-only --no-commit-id17:18
tang^ diff-tree only shows the root directory's changes?17:19
rafasc just look into diff-tree and its options.17:19
Mr__Anderson joined17:19
rafasc tang^: yes, but you can ask it to recurse with -r.17:19
Mr__Anderson left17:19
kjartan joined17:19
rafasc tang^: it's similar how $ls works.17:19
tang^ oh, there it is17:20
I didn't go far enough down the documentation17:20
thanks17:21
rafasc also, -z worth to look at for robust scripts.17:22
for filenames with spaces/newlines17:23
fphilipe joined17:24
seaef-tnw left17:25
tang^ oh geez. I hope no filename has a newline in it17:25
courrier left17:26
seaef-tnw joined17:29
quackgyver left17:29
R2robot left17:33
Lordveda rafasc: actually I am not on an actual project, I am doing a git training from a website https://gitexercices.fracz.com/17:37
https://gitexercises.fracz.com/17:38
I am doing the 14th exercise17:39
yyy joined17:40
rafasc what is the name of the 14th?17:41
leeN joined17:41
energizer left17:42
Lordveda split-commit17:42
energizer_ joined17:42
gxt joined17:42
blackmesa joined17:43
Lordveda My progression is at https://gitexercises.fracz.com/committer/49185e38fa67a83a36e0e5d65944605e2d32e77117:43
Ivo left17:43
Lordveda when I undergo the exercise I start by doing git status17:44
then do git log --oneline --color --decorate17:44
rafasc I already typed the solution here.17:45
Lordveda when I did git reset -N I have got a clean working tree17:45
rafasc although I used a different approach than the one they are hinting.17:45
Lordveda: you need to specify the commit you want to reset.17:46
like: git reset HEAD~1;17:46
Lordveda the branches in this tree are master and split-commit17:46
I did git reset -N split-commit17:46
g00s joined17:47
nelsnelson left17:47
Lordveda or should I do git reset -N HEAD@{0}?17:47
rafasc (No need for N)17:47
blackmesa left17:48
Lordveda fine no need for the N17:48
rafasc since this is the most recent commit, you can do HEAD~117:48
ChanServ set mode: +o17:48
nelsnelson joined17:48
Eugene changed the topic to: #git Welcome to #git, the place for git* related discussion | First visit? Read: https://gitirc.eu | Current stable version: 2.21.0 | Getting "cannot send to channel"? /msg gitinfo .voice | This channel is logged: https://gitirc.eu/log | git-hg: Don't you know that's poison?17:48
Eugene set mode: -o17:48
Lordveda so I should reset to make the tree revert back to HEAD@{1}?17:49
and that is issued while I am on the latest commit? right?17:49
rafasc: you mentioned git rm --cached file, would this still apply to this case and this exercise?17:50
rafasc Lordveda: HEAD@{1} and HEAD~1 mean different things.17:50
Lordveda when I do reflog I find HEAD@{1}17:51
and HEAD@{0}17:51
etc17:51
savolla joined17:51
Lordveda so what is the difference between HEAD@{1} and HEAD~117:51
rafasc man gitrevisions17:52
gitinfo the gitrevisions manpage is available at https://gitirc.eu/gitrevisions.html17:52
rafasc HEAD~1 means: the first ancestor following first-parent.17:53
Lordveda i.e from 0 to 117:53
rafasc where HEAD@{1} is the first entry in the reflog.17:53
Lordveda ??17:53
rafasc HEAD~1 is a way to say parent, HEAD~2 grand-parent, etc.17:54
Lordveda so I need to do git reset HEAD~1 and not HEAD@{1}17:54
rafasc correct.17:54
Lordveda so when I am on the HEAD@{0} and I need to reset to the parent I need to type git reset HEAD~117:55
osse HEAD@{0} and HEAD~0 are both just equal to HEAD17:56
rafasc I suggest you stop using reflog notation until you understand what the reflog is. The something@{n}17:57
Lordveda so the entries in the reflog aren't Zero-based?17:57
osse yes they are17:58
rafasc the reflog is important for recovering things. But it's more important you understand the other concepts first.17:58
lungaro joined17:58
mikecmpbll joined17:58
lungaro I have a really annoying issue with github and key management, hoping someone can help me organize it. I thought i'd be smart enough to manage ssh keys in my ssh-agent, but the problem is I use ssh mux connections17:58
rafasc Lordveda: for example, the reflog has no "order" you don't know if commit HEAD@{1} comes before or after commit HEAD@{2}.17:59
Lordveda so I should use HEAD@{1} or HEAD~1 to reset to the parent?17:59
lungaro so mux connections dont die after you change the keys so they are never updated. Is there a smarter way to update the mux'd connections?17:59
rafasc the latter.17:59
Lordveda got you rafasc17:59
Sasazuka joined17:59
Lordveda the order in reflog doesn't need to be the same order of commits17:59
it refers more to everything that occured to the working tree as a whole18:00
and thus it can't be used in reset except with caution, am I right?18:00
rafasc Lordveda: not even that. If tracks how refs (branches) change over time.18:00
Lordveda bottom line reflog is more general18:01
??18:01
osse no, the reflog is something else completely18:01
rafasc Lordveda: for example, if you checkout A; checkout B; checkout C; (just switching branches). HEAD@{0}=C, HEAD@{1}=B, HEAD@{2}=C18:01
thiago left18:02
rafasc Lordveda: it tracks how your references change over time.18:02
and HEAD is just a reference that defines what you have currently checked out.18:02
Lordveda i.e the commands I issue through git are logged within the reflog18:02
in the order I am entering them18:02
rafasc Lordveda: the ones that change references, yes.18:02
Murr left18:03
Lordveda thus HEAD@{x} doesn't necessarily == HEAD~x18:03
osse correct18:03
rafasc that's rarely true.18:03
osse and your HEAD@{x} is probably not equal to my HEAD@{x}18:04
Lordveda rafasc: thanks for clarifying things18:04
Murr joined18:04
rafasc also, HEAD@{x} == HEAD@{x+n} may be true for some n.18:05
freeman42x joined18:05
nowhere_man left18:06
rafasc for example: try doing a bunch of $git checkout <the branch you are at>;18:06
kgrandly left18:07
rafasc if you look at the reflog, you'll see a bunch of entries referring to the same commit.18:07
pks_ joined18:15
pks left18:16
pks_pks18:16
jubal joined18:17
barteks2x left18:20
barteks2x_ joined18:20
sgnls joined18:24
fattredd joined18:24
jcbitter left18:25
jcbitter joined18:26
plexigras joined18:28
sauvin left18:32
sz0 left18:33
plexigras left18:40
linux_dr joined18:41
hexa- left18:41
dartmouthed joined18:41
plexigras joined18:42
hexa- joined18:47
kneeki joined18:50
elricsfate joined18:53
elricsfate Hey folks. When using the env branching model and rebasing, should the rebasing be creating NEW commits to the branch?18:54
hellauer left18:54
elricsfate https://www.wearefine.com/mingle/env-branching-with-git/18:54
Repox joined18:55
tang^ rebasing creates new hashes for existing commits, yes18:55
elricsfate Hmmm. OK18:55
I'm a bit confused by how this model works or perhaps I'm just holding it wrong18:56
lets say I rebase off staging before merging or creating a pull request for that branch, I'd expect the only additional commits I see to be the two commits I originally added to the feature branch18:56
R2robot joined18:56
elricsfate Instead I see like 8-9 commits18:56
Ignacy joined18:59
Newami left18:59
elricsfate So I have the feature/addcats branch based off master. I then need to merge that feature into develop so I rebase off develop and open a pull request to merge. I'd expect to only see the new changes on the top of that pull request. Instead I see a few. Is that normal with this way tang^?19:00
*a few extra based on the rebase19:00
tang^ if those commits on master aren't in dev, then they'll show up as additional on dev19:01
though, given the model you shared, that shouldn't happen19:01
bn_work joined19:01
_noblegas left19:03
T_UNIX left19:04
leprechau left19:05
ComradeCrocodillCrocodillian19:06
hellauer joined19:06
satifant left19:07
Vonor joined19:08
Vonor hi. I'm fiddling around for a bit now with git show, git log and git rev-parse. I want only the pretty format i specify from a certain file and only from the latest commit that file had. any idea?19:10
osse Vonor: git log --pretty=blabla -1 -- file19:10
elricsfate I see the issue now tang^19:10
I'm pushing the remote branch19:11
That's expecting that I won't do that19:11
Not sure how you'd handle that if you're also pushing the branch up to remote19:11
It only pushes up to remote when it's time to push into master branch19:11
Narrat joined19:12
wildermind left19:13
rnsanchez left19:14
Inline left19:14
raffo joined19:15
synx joined19:17
synx Is there a way to get the commit at HEAD for a given remote repo without actually cloning the whole repo?19:18
pandem do you use github or something similar19:19
Inline joined19:19
clime left19:19
pandem what do you mean by getting the commit?19:19
synx I want the hash.19:19
No, just some arbitrary remote, not necessarily github19:19
elricsfate Is it ever really suggested that multiple developers are working on the same branch or is that generally bad juju?19:19
(For example a feature or bug branch)19:20
Vonor osse, thanks. that is exactly what i was looking for19:20
pandem well, if you cant get it from the remote, then maybe shallow clone?19:20
satifant joined19:21
watabou_ joined19:21
synx oh, yea, shallow clone might work -- ill give that shot, thanks19:22
rsrx left19:22
leprechau joined19:26
g00s left19:28
planetcall|work left19:28
watabou_ left19:32
clime joined19:33
czart left19:35
emsjessec left19:35
nedbat elricsfate: we sometimes have devs working together on a branch.19:40
elricsfate: you have to be careful about things like force-pushing though.19:40
leb left19:41
sgnls left19:41
fphilipe left19:41
frikinz joined19:43
vnr joined19:43
savolla left19:43
sgnls joined19:43
savolla joined19:43
kgrandly joined19:46
torontoyescorrect19:46
savolla left19:47
wyre_ left19:47
courrier joined19:53
g00s joined19:53
gloomy left19:54
rnsanchez joined19:55
OtakuSenpai left19:55
kgrandly left19:55
gxt left19:56
kgrandly joined19:58
jamiejackson joined19:59
strk left19:59
freeman42y joined20:00
freeman42x left20:00
varesa_varesa20:01
n3wborn joined20:01
nikivi joined20:01
elricsfate nedbat: Yep, the only way I could think of handling that would just be a force push20:01
Which would definitely require some care20:01
nedbat elricsfate: sorry, handling what?20:02
gloomy joined20:04
Repox left20:07
fphilipe joined20:08
boombatower left20:11
Mr__Anderson joined20:11
fphilipe left20:14
guest3456 joined20:14
guest3456 is it possible to delete multiple branches with a wildcard char20:15
like20:15
git branch -D release-v2*20:15
* or . neither worked20:15
theoceaniscool left20:16
elricsfate nedbat: Using that particular model and collaborating on a branch20:17
fattredd left20:18
j416 guest3456: doubt20:19
theoceaniscool joined20:19
leprechau left20:20
canton7 guest3456, you can use git for-each-ref, and pipe that into git branch -d20:20
Enphuego joined20:23
guest3456 too advanced for me20:24
j416 guest3456: then copypaste the branchnames20:25
leprechau joined20:25
gxt joined20:26
j416 or.. just delete the one by one20:26
them*20:26
guest3456: learning how pipes work isn't rocket science though; you should be able to learn it through a quick google.20:27
guest3456: you'll probably need xargs as well so look that up too.20:27
yyy left20:27
oatmealraisin left20:29
strk joined20:32
strk are notes not meant to be pushed to a shared repo ?20:32
or why does `git push` not push them ?20:32
_ikke_ strk: You need to be explicit that you want to push them by adding a refspec that pushes the notes ref20:33
fahadash left20:34
strk fetch = +refs/notes/commits/*:refs/remotes/origin/notes/commits/*20:35
like the above ?20:35
but there's already:20:36
fetch = +refs/heads/*:refs/remotes/origin/*20:36
so would that conflict if an head ends up being called "notes" ?20:36
fphilipe joined20:36
strk sorry if I'm being lame20:36
theoceaniscool left20:36
Ignacy left20:37
_ikke_ strk: all 'normal' branches are always prefixed with refs/heads20:38
so refs/notes will never conflict with normal branches20:38
ah20:39
Yes, I would not create them as local tracking branches, that is bound to create issues20:39
strk sorry, I don't really undestand all these terms :(20:41
do the fetch line create local tracking branches ?20:42
shabius left20:42
_ikke_ refs/remotes/* is the namespace for remote tracking branches20:42
leb joined20:44
strk alright, I refrained from adding the fetch line20:44
blackandblue joined20:44
strk and just did a manual push of refs/notes/*20:44
doing so, resulted in pushing unexpected refs I found under there20:45
refs/notes/osgeo/devtools/discuss20:45
refs/notes/osgeo/devtools/reviews20:45
do those names ring any bell ?20:45
could it be some git-appraise thing ?20:45
_ikke_ no20:45
might be20:45
greatgatsby joined20:45
strk git log shows me devtools/discuss contains 2 commits, both reported to be added via 'git notes append'20:46
(reported by commit log)20:46
jstein_ joined20:47
strk seems to be git-appraise though, as if I show those commits, they look like comments on changed lines20:47
jstein_jstein20:47
wootehfoot joined20:48
mattcen left20:48
Newami joined20:49
wootehfoot left20:49
mattcen joined20:50
sgnls left20:53
gadget joined20:55
smitop joined20:57
sozuba left20:59
dege left21:00
dege joined21:01
nikivi left21:02
shabius joined21:03
strk why do people not like git notes ?21:04
satifant left21:04
correct left21:06
_ikke_ Not sure if that's the case, it's probably more that not many people have a usecase for them21:06
oatmealraisin joined21:07
seaef-tnw left21:08
azwieg103 left21:09
nikivi joined21:09
scientes left21:12
scientes joined21:12
scientes left21:13
r1ch left21:13
gadget left21:13
nedbat strk: do you like them?21:14
fphilipe left21:15
mattcen left21:16
bolovanos left21:17
mattcen joined21:19
fphilipe joined21:19
satifant joined21:19
strk I like them, so far, but didn't use them much yet21:21
I did like the idea of adding a note to an object21:21
but didn't try adding _more_ notes to it21:21
I've read somewhere you can only have one per object ?21:22
sbeyer left21:22
m0viefreak joined21:24
howell left21:25
jubal left21:26
R2robot left21:32
circuitbone 1 per hash?21:34
bashfulshell joined21:35
Mr__Anderson left21:36
Cabanossi left21:36
kgrandly left21:37
kgrandly joined21:37
jamiejackson left21:38
Timvde What's the use case for git notes?21:38
Additions to a commit message for a published commit?21:38
_ikke_ Yes, any kind of note21:39
strk yes, that's my understanding21:39
like: "hey, my commit log was partial, here's an addendum"21:39
but "addendum" implies you can add them, a single note is indeed weird21:39
gloomy left21:44
pllong left21:46
CarlFK joined21:47
greggerz left21:48
Cabanossi joined21:48
leeN left21:53
CarlFK "error: you need to resolve your current index first" The changes in that branch have been accepted upstream, so I have 0 interest in it21:55
how do I resolve/stash/throw out whatever21:55
blackandblue left21:56
CryptoDavid joined21:57
blackandblue joined21:57
Fernando-Basso joined21:58
vnr left22:01
moldybits joined22:02
fphilipe left22:03
boombatower joined22:05
fphilipe joined22:09
dodobrain left22:10
fphilipe_ joined22:14
fphilipe left22:15
justan0theruser joined22:18
moldybits left22:19
justanotheruser left22:20
dege left22:20
vishal CarlFK: what command is producing that error?22:21
linux_dr left22:21
jguddas-tr joined22:21
jstein left22:22
CarlFK vishal: git checkout master22:22
Narrat left22:22
vishal and do you have uncommitted changes either in index or the working tree?22:23
CarlFK but I just now gave up and added/commited22:23
vishal if you just want to throw away uncommitted changes you can go git reset --hard HEAD22:23
arecaceae left22:23
fphilipe_ left22:23
vishal and they will be irrecoverably gone22:24
CarlFK that s what I want - thanks22:24
arecaceae joined22:24
jguddas-tr left22:26
g00s left22:26
Atlenohen joined22:26
oatmealraisin left22:27
ygivenx joined22:32
Case_Of left22:34
justan0theruserjustanotheruser22:35
CarlFK grumble. git pull origin master -> error: Pull is not possible because you have unmerged files.22:35
rafasc CarlFK: after a reset --hard?22:36
Case_Of joined22:36
moldybits joined22:37
CarlFK rafasc: yes http://paste.ubuntu.com/p/qPPX5zn8tc/22:37
shawn_dones left22:37
rafasc !eek22:37
gitinfo [!eekaconflict] Merge conflicts are a natural part of collaboration. When facing one, *don't panic*. Read "How to resolve conflicts" in man git-merge and http://git-scm.com/book/ch3-2.html#Basic-Merge-Conflicts then carefully go through the conflicts. Picking one side verbatim is not always the right choice! A nice video explaining merge conflicts: https://www.youtube.com/watch?v=zz7NuSCH6II22:37
CarlFK "picking one side verbatim is not always the right choice! " but in this case it is :p22:39
plexigras left22:39
vishal CarlFK: do you have local commits that you want to keep? or do you just want to sync it up to be exactly the same as origin/master ?22:39
CarlFK just sync22:39
rafasc you can try passing -Xours or -Xtheirs22:41
CarlFK wut?22:41
rafasc to tell git to resolve conflicts using our side, or their side.22:42
vishal I don't think any resolution is needed if he just wants to throw away his changes22:42
just do git fetch origin; git reset --hard origin/master22:43
also beware of !pull422:43
gitinfo [!fetchfour] Before 1.8.4, 'git fetch/pull' with a remote AND branch argument tended to be confusing because they didn't update the remote-tracking branch (the thing shown by 'git branch -r'). If you're stuck with an old version, it's usually better to pass no arguments, or at least only a remote. Workaround example to fetch only the 'foo' branch: git fetch origin refs/heads/foo:refs/remotes/origin/foo22:43
rafasc true, but if there are changes committed, usually there's a reason for it, and discarding them with reset --hard may not be intended.22:43
vishal true - that's why I asked that to make sure. always good to make a backup in any case :)22:44
rafasc it's unclear what "just sync" means.22:44
n3wborn left22:45
CarlFK rm -rf; delete the repo; forkl clone would be acceptable22:45
but looks like that fetch reset did the trick22:45
libertyprime joined22:45
rafasc then reset --hard as vishal recommended.22:45
vishal !xkcd22:46
aww22:46
https://xkcd.com/1597/ should totally be a trigger :)22:46
SkarmoutsosV left22:47
rafasc vishal: I'll put you in my git.txt ;)22:48
Lordveda Please what does this command mean: git rebase -i HEAD^^22:48
?22:49
rafasc basically means recommit the last two commits.22:49
vishal Lordveda: what are you trying to do? it is an interactive rebase22:49
Lordveda I am asking about the HEAD^^ part in particular22:49
rafasc man gitrevisions22:49
gitinfo the gitrevisions manpage is available at https://gitirc.eu/gitrevisions.html22:49
vishal ah parent of parent of HEAD, also equivalent to HEAD~222:49
Lordveda ok rafasc22:49
vishal rafasc: hah, we can be git.txt buddies22:50
rafasc ^ is a parent selector. HEAD^1 means first parent of HEAD.22:50
if the number is missing, it defaults to 1.22:50
so HEAD^^ is equivalent of (HEAD^1)^122:51
leb left22:51
rafasc (parenthesis just to demonstrate the idea better.)22:51
Lordveda does HEAD^^ == HEAD^2?22:52
CarlFK crys. I just want to add a few chars and send off a MR.. http://paste.debian.net/1082725/22:52
vishal nope22:52
Lordveda vishal: why not?22:52
vishal Lordveda: HEAD^2 is second parent of head. HEAD^^ or HEAD~2 means _grand_parent of HEAD22:53
rafasc because ^ is a parent selector. ^2 would be the second parent. (only relevant on merge commits)22:53
vishal HEAD^2 only applies when talking about a merge commit22:53
Xiti left22:54
Lordveda I solved the problem 15 on the website I provided the url earlier today by a different way22:54
rafasc the 14 can be solved without reset as well. ;)22:55
Lordveda The problem told about having 2 consecutive commits for a single file22:55
vishal CarlFK: you must have changes to the carlfk-sals remote that you resetted22:55
CarlFK ah right.22:56
rafasc like I mentioned: git rm --cached file 2; git commit --amend; git add file 2; git commit;22:56
mikecmpbll left22:56
vishal if you don't care about rewriting the history on that remote/branch, you can use push --force22:56
fphilipe_ joined22:56
Lordveda rafasc: I am not very affluent with git, I am practicing22:56
rafasc Lordveda: you're already on the right path.22:57
Lordveda: most of the time here are multiple ways to accomplish the same thing.22:57
Lordveda problem 15 on the web site which requested reverting two consecutive to one commit22:58
I solved it by reverting the most recent commit and amended the change to its parent22:59
rafasc Lordveda: wasn't this you: https://gitexercises.fracz.com/committer/49185e38fa67a83a36e0e5d65944605e2d32e77122:59
Xiti joined22:59
Lordveda on the site they used rebase --interactive22:59
rafasc: Yes this is me23:00
check problem 15 solution23:00
they used rebase -i HEAD^^23:01
thiago_ joined23:01
Lordveda I did reset HEAD~1 then did git add file.txt and then git commit --amend23:01
I am just wondering why my solution yielded the same result as the author of the exercise, can anyone explain plz?23:02
vishal Lordveda: rebase -i means "go back in time X commits, and redo them, while also potentially making some changes". You also did the same thing, except going back in time manually, using reset, and then making changes using your commit --amend23:04
rebase -i is the generalized way to solve that sort of a problem23:05
dartmouthed left23:05
vishal rebase -i will also remember and replay the commits that come afterwards - in your reset case, you'd have to add and commit those files again by hand23:06
Lordveda So my solution was a beginner's solution :)23:06
vishal if you were going back in time by only 1-2 commits, reset is acceptable. But try doing more than that and reset quickly becomes unmanageable23:06
sort of, yeah23:07
accomplished the same goal, but may not scale in more real-world scenarios23:07
Lordveda Is the -i option equivalent to the --interactive option?23:08
cdown left23:08
vishal yes -i is just the short version23:08
(of the option that is - they are exactly the same)23:09
fstd_ joined23:10
weird_error joined23:11
rafasc Lordveda: git <cmd> --help; should open manual pages where all options are described.23:11
with a bit of regex, you can find options very quickly.23:13
example: /^\s+-i23:13
fstd left23:14
fstd_fstd23:14
RoriconKnight joined23:14
weird_error left23:17
weird_error joined23:21
weird_error left23:21
hofmann3900 joined23:22
mat001 left23:24
Phylock left23:25
mat001 joined23:26
mat001 left23:26
courrier left23:28
tang^ left23:29
ferdna joined23:29
fphilipe_ left23:31
justanotheruser left23:32
freeman42y left23:34
Lordveda regexes are like immense puzzles to me rafasc23:35
rafasc in less: / starts a search; ^ means start of line; \s+ means one or more spaces.23:36
khisanth_ left23:36
duderonomy left23:36
rafasc if you did /-i or /--interactive you would get there as well.23:37
but you would need to press p or n (previous/next) a bunch of times to get to the relevant part.23:37
mat001 joined23:37
fphilipe_ joined23:37
mat001 left23:37
jubal joined23:38
rafasc learning how to browse the documentation effectively is a good portion of becoming good at git.23:38
Lordveda actually I do searches into man pages very frequently23:38
courrier joined23:38
oatmealraisin joined23:39
rafasc ctrl+f on a browser also works. https://git-scm.com/docs/git-rebase23:39
Lordveda in man pages?23:40
rafasc Lordveda: git help rebase -w;23:40
(depends if your distro bundles html documentation)23:40
Lordveda I view the help in terminal rafasc23:41
plus I didn't find the docs available23:42
rafasc then the regex methods I mentioned should work if your pager is less.23:42
mat001 joined23:42
fphilipe_ left23:42
watabou_ joined23:44
rafasc also: man -Hgoogle-chrome git rebase;23:44
the result of git help --web is prettied though.23:44
But I never use that, I just browse the man pages themselves.23:45
Lordveda rafasc: D'accord23:45
edwardly joined23:46
khisanth_ joined23:50
greatgatsby left23:52
bluezone left23:52
alyptik left23:53
magic_ninja left23:56
CodeSlingerPaul left23:59
Bobdude joined23:59
eckon left23:59
Newami left23:59

Logs Search ←Prev date Next date→ Channels Documentation