IRCloggy #git 2019-04-21

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-04-21

rafasc git diff --staged; git diff; covers the first two.00:00
de-facto left00:01
de-facto joined00:01
rafasc -1 --base, -2 --ours, -3 --theirs cover the last ones.00:01
enigmus rafasc: ah! Thanks. I can't write "git diff -1 refs/heads/xxx" though, right?00:05
rafasc So the tools are there, and you can place your own wrapper with that logic on your path.00:06
fphilipe joined00:12
jottr joined00:12
kadoban_ left00:12
fphilipe left00:17
z|bandito joined00:18
jottr left00:18
rafasc enigmus: well, 2 will be HEAD, 3 will be MERGE_HEAD, and 1 will be merge-base HEAD MERGE_HEAD;00:19
also, the nature of merges and how they can mismerge things is something that is hard to automate.00:20
https://youtu.be/8ET_gl1qAZ0?t=249500:22
plongshot joined00:24
rafasc enigmus: I don't think you can, but you can specify the stage in diff commands for specific files.00:27
git diff :1:README HEAD~5000:README00:28
plongshot I'm not quite sure how to phrase my question.. I'm assuming a bitbucket wiki repository is it's own separate repo from the repositry the code is in (even thought it's the same project)? If that is true then my question here is - ways to manage that? I heard about something called "grafting". Could that help in my case?00:29
I mean. I guess my ultimate, first decision is whether to manage two separate repos under the same project or to try to combine them?00:30
rafasc plongshot: grafting is something else.00:32
plongshot oh00:32
learningc joined00:32
osse plongshot: One git repository can contain two branches that don't share a common root.00:32
rafasc it's something that allows you to "lie" about history00:32
osse In that sense you can manage two different repositories in one00:33
plongshot osse: So you are also saying 'more than one root in a single repository' ?00:33
Like two repos in one?00:33
osse Essentially yes00:34
rafasc seems like bitbucket wiki are actually their own repos, in contrast to things like gh-pages which are just a branch.00:34
osse Branches with no common root can be merged, but they don't have to00:34
plongshot I still have not verified for certain but it seems as thought they are separate repos00:35
mven joined00:35
rafasc plongshot: https://confluence.atlassian.com/bitbucket/clone-and-edit-pages-317195798.html00:35
plongshot osse: Oh fuck! I just thought of something glorious!!00:36
ohmygod!00:36
rafasc you can clone them directly, so they are their own standalone repo.00:36
plongshot I think.. I think I can just add the additional remot to the wiki repo on my code repo (locally) and that will...00:36
well be the start of something I don't know how to finish00:36
rafasc plongshot: that's the approach osse was mentioning.00:37
osse plongshot: Not sure about the details but it sounds like you're on the right track.00:37
plongshot that popped into my head but not certain on the details how to handle that00:37
R2robot joined00:37
savolla left00:37
osse At least you've "grokked" something fundamental about how git works00:37
rafasc but the advantages of doing that are limited... Especially since it can be a pain to switch branches.00:37
because the files are completely unrelated.00:38
plongshot rafasc: i think thats one of the questions I didn't know to ask (nor the answer to)00:38
osse plongshot: The git repo of git itself has seven roots00:38
plongshot oh wow00:39
rafasc the simpler solution is to use worktrees in that case, but then you just better off having as separate repo directories.00:39
nedbat osse: why does it have seven roots?00:40
plongshot Idk what good it does me to add a remote to the repo going to the wiki. Unless its to pull or clone or sync or fetch right into the existing code repo locally. But idk what the result would be after doing it?00:40
rafasc nedbat: some projects were started separated and were merged in, like git gui.00:40
plongshot If I'm on the right track?00:40
a worktree00:41
rafasc osse: I have 13 roots! 0.000:41
osse rafasc: Replace --all with origin/master :P00:42
mven left00:43
osse plongshot: Fetching just updates stuff. You can add the Linux repo as a remote to your dotfiles repo and fetch.00:44
rafasc the kernel also has a couple.. At least one of them was introduced accidentally, and Linus was a bit upset about not catching it sooner.00:44
osse plongshot: !fetch00:44
gitinfo plongshot: When you work with remote repositories, Git stores copies of the remote's branches in !tracking_branches (basically mirrors). You can use 'git fetch' to update those. If you want to actually apply changes from the remote to your checked out branch, a second step is needed, usually 'git merge' or 'git rebase'. There's also 'git pull' which combines both steps.00:44
osse !remote_tr00:44
gitinfo [!remote_tracking_branch] Remote-tracking branches (branches which start with e.g. 'origin/', listed by 'git branch -r') are read-only mirrors of the branches in another repository. They're updated by 'git fetch'. You can't edit them directly (trying to check them out results in a !detached HEAD), but you can create a local branch based on a remote-tracking branch using e.g. 'git checkout -b <branch> <remote>/<branch>'00:44
enigmus rafasc: by the way, thanks a lot for all the details00:46
kadoban_ joined00:47
mven joined00:48
rafasc accidental root: http://lkml.iu.edu/hypermail/linux/kernel/1603.2/01926.html00:49
donofrio_ joined00:49
donofrio left00:50
rafasc plongshot: it will be a lot easier on you to manage it as separate repos. Especially because when you're writting documentation, it is usually useful to reference the code. But if you keep it on the same repo as different branches, you won't be able to do that.00:52
fphilipe joined00:52
causa_sui joined00:53
Phylock left00:53
mooasaurus left00:54
mooasaurus joined00:55
causa_sui left00:58
Trieste left00:58
kadoban_ left00:59
freeman42y left01:00
Trieste joined01:08
hussam left01:13
pupsikov joined01:15
Ignacy left01:15
rafasc left01:17
F0rTex left01:19
F0rTex joined01:20
finalbeta joined01:21
mven left01:25
fphilipe left01:25
zonixo left01:27
m0viefreak left01:28
Ignacy joined01:29
kadoban_ joined01:29
kadoban_ left01:32
YuGiOhJCJ joined01:34
donofrio_ left01:35
royal_screwup21 left01:37
jottr joined01:38
donofrio joined01:40
MACscr left01:41
boombatower joined01:42
jottr left01:43
Ignacy left01:45
Beam_Inn__ joined01:48
plongshot left01:48
Beam_Inn_ left01:50
Beam_Inn__Beam_Inn_01:50
ferdna left01:56
igemnace left01:57
mowcat joined02:07
causa_sui joined02:08
causa_sui left02:13
lagothrixGuest1469502:17
Guest14695 left02:17
lagothrix joined02:17
pupsikov left02:18
ferdna joined02:20
boombatower left02:29
mven joined02:32
kadoban_ joined02:33
Anthaas left02:37
Anthaas joined02:37
mven left02:37
mven joined02:40
kadoban_ left02:43
duderonomy joined02:49
RustyShackleford left02:52
rsrx left02:55
HotBeefDip left02:57
axsuul joined03:00
duderonomy left03:01
HotBeefDip joined03:01
HotBeefDip left03:01
jottr joined03:04
kerframil joined03:08
jottr left03:09
omnireq left03:16
rkta left03:17
rkta joined03:17
omnireq joined03:18
omnireq left03:19
omnireq joined03:20
fphilipe joined03:22
causa_sui joined03:23
rosco_y left03:25
causa_sui left03:27
jstimm left03:28
moldybits left03:30
jnewt_ left03:30
enigmus left03:37
mven left03:40
th_ left03:41
nurdie joined03:41
jottr joined03:42
mudmatmud03:42
mud left03:43
mud joined03:43
mud left03:43
mud joined03:43
arecacea1 left03:44
arecacea1 joined03:45
moldybits joined03:45
zulutango left03:46
molusc left03:47
molusc joined03:47
jottr left03:48
Beam_Inn_ left03:52
n3wborn joined03:52
mowcat left03:53
fphilipe left03:56
mven joined04:00
duderonomy joined04:02
Shentino left04:04
Shentino_ joined04:04
netj joined04:08
duderonomy left04:12
kadobanana joined04:13
craftyguy left04:15
nabil joined04:17
craftyguy joined04:17
mven left04:21
kadobanana left04:21
bambanx joined04:22
kadobanana joined04:22
fphilipe joined04:29
APic left04:30
kadobanana left04:31
mven joined04:33
veegee joined04:36
causa_sui joined04:38
mven left04:39
jottr joined04:39
APic joined04:40
causa_sui left04:43
jottr left04:44
zulutango joined04:45
Xeyame left04:47
dpyro joined04:57
pks_ joined05:03
fphilipe left05:04
pks left05:05
pks_pks05:05
g00s left05:13
jottr joined05:20
jottr left05:25
tigos2 joined05:28
RustyShackleford joined05:29
tya99 left05:29
gmh left05:30
kadoban left05:37
g00s joined05:47
xcm left05:52
xcm joined05:52
causa_sui joined05:53
veegee left05:55
causa_sui left05:58
rohit[m] joined06:00
jottr joined06:00
victorqueiroz left06:00
jottr left06:05
thiago left06:05
rohit[m] left06:06
rohit[m] joined06:06
Goplat left06:06
xcm left06:08
rohit[m] left06:09
xcm joined06:09
rohit[m] joined06:09
fstd_ joined06:12
rohit[m] left06:13
rohit[m] joined06:13
fstd left06:16
fstd_fstd06:16
Envil joined06:20
yonder left06:20
cgi joined06:21
cgi I have a few people in a project who checked in with different email addresses. I want to rewrite those email addresses to a common email address. Is there an easy way of doing that? For example [email@hidden.address] and [email@hidden.address] -> rewrite them to the same email06:21
flavius joined06:24
cdown left06:30
cd joined06:31
Tawonga joined06:31
cdown joined06:33
plexigras joined06:37
_ikke_ man git mailmap06:41
gitinfo the git manpage is available at https://gitirc.eu/git.html06:41
_ikke_ hmm06:41
man git check-mailmap06:42
gitinfo the git-check-mailmap manpage is available at https://gitirc.eu/git-check-mailmap.html06:42
noobJS joined06:48
noobJS left06:52
czart joined06:54
thefatma joined06:59
fphilipe joined06:59
bambanx left07:04
kapil____ joined07:06
causa_sui joined07:08
achen_ joined07:12
causa_sui left07:13
Mattiaslndstrm joined07:15
thefatma left07:16
duderonomy joined07:16
Mattiaslndstrm left07:19
zonixo joined07:22
lomex joined07:25
kjartan left07:29
tigos2 left07:30
kjartan joined07:34
ggSo joined07:38
zonixo left07:40
f00lest joined07:41
f00lest will the owner of a private gitlab repository know if I have cloned it using ssh, will my ssh information be recorded?07:41
ferdna left07:43
tm007 joined07:48
Noti joined07:51
ggSo left07:55
lomex left08:03
Noti left08:03
j416 they probably have logs08:03
nic-hartley left08:03
Regon joined08:03
Noti joined08:07
royal_screwup21 joined08:10
leeN joined08:12
Noti left08:16
Mattiaslndstrm joined08:19
f00lest j416: If I clone using http instead of ssh will it be the same?08:24
causa_sui joined08:24
xcm f00lest: if they are in control of the server, they can log anything the server does, including http requests08:26
f00lest xcm: repository is on gitlab as a private repo08:27
xcm gitlab is a piece of software, but now i'm starting to think you're talking about gitlab.com08:28
f00lest xcm: pardon me for not being clear, aye gitlab.com08:28
veegee joined08:29
xcm afraid i'll have to redirect you to gilab.com's support :(08:29
causa_sui left08:29
xcm since it's a private repo, i imagine you still need to auth to fetch things. but whether they make these logs available to the repo owner has even less to do with #git08:30
f00lest xcm: thanks anyways, :p08:30
f00lest left08:30
goron joined08:32
plexigras left08:33
dpyro left08:33
lomex joined08:33
fphilipe left08:36
R2robot left08:37
goron left08:39
R2robot joined08:40
veremitz{{veremitz}}08:58
fphilipe joined09:00
dhollinger left09:00
{{veremitz}}veremitz09:00
dhollinger joined09:01
cybrNaut joined09:01
g00s left09:01
azwieg103 left09:05
HotBeefDip joined09:06
yyy joined09:16
nabil left09:18
catsup left09:19
catsup joined09:19
nowhere_man joined09:20
catsup left09:20
catsup joined09:20
rohit[m] left09:26
rohit[m] joined09:26
jcbitter left09:30
mowcat joined09:34
chinhoye joined09:38
chinhoye left09:39
causa_sui joined09:39
KnoP joined09:40
causa_sui left09:43
jcbitter joined09:46
achen_ left09:46
Noti joined09:46
savolla joined09:47
jcbitter left09:54
Puffball joined09:54
achen_ joined09:56
lankanmon left10:01
basiclaser joined10:03
tmm88 joined10:05
HotBeefDip left10:06
finalbeta left10:07
finalbeta joined10:07
tmm8876 joined10:08
tmm8876 left10:08
tmm88 left10:09
tmm88 joined10:09
jas4711 joined10:13
Noti left10:14
jottr joined10:15
Noti joined10:19
Phylock joined10:20
Anthaas left10:20
Anthaas joined10:21
m0viefreak joined10:25
lomex left10:26
LogicAsideThatOtherGuy10:30
nuc left10:33
fakhraee left10:34
fphilipe left10:34
yyy left10:34
fphilipe joined10:34
nuc joined10:35
fakhraee joined10:37
rsrx joined10:41
zulutango left10:48
lankanmon joined10:51
m0viefreak left10:53
causa_sui joined10:54
llinguini left10:56
causa_sui left10:58
yyy joined11:07
jottr left11:07
savolla left11:08
Lucas_Gray joined11:09
kerframil left11:11
anubani left11:12
SkarmoutsosV joined11:14
zulutango joined11:18
bashfulshell left11:18
royal_screwup21 left11:18
zulutango left11:19
zulutango joined11:22
SkarmoutsosV left11:26
kjartan left11:41
ricekrispie2 joined11:44
tmm88 left11:46
kjartan joined11:46
ricekrispie left11:46
Wryhder joined11:47
Lucas_Gray left11:48
WryhderLucas_Gray11:48
plantroon joined11:50
mooasaurus left11:50
mooasaurus joined11:51
DropItLikeItsHot left11:51
downer06 left11:52
ave_milia joined11:52
downer06 joined11:53
plantroon I have the so called bare repositories like project3.git created on my server and I am using them over ssh. Now what's the best practice on adding such remote repository via `git remote add ssh://git.example.com/srv/git/project3.git` - do I need to include the .git when adding the remote? Because it works both ways, I don't know why. Is this .git extension something special?11:53
DropItLikeItsHot joined11:54
bremner yes11:54
_ikke_ plantroon: the best is to use the name as it's on disk11:59
but if you leave out .git, and git doesn't find it, it will try with .git appended11:59
Have-Quick left11:59
plantroon thanks :) I'll use .git everywhere to make it perfectly clear for me :)12:01
one more thing, can I change the "root" of the git repositories? So that I can do `git remote add ssh://git.example.com/project3.git` without having project3.git in my homedir?12:01
I can imagine how to do this with http but not ssh12:02
_ikke_ plantroon: gitolite does it, not sure how though12:04
it uses gitolite-shell, which probably has to do with it12:05
plantroon _ikke_: I can imagine many ways, like separate ssh chroot or symlinks to homedir but I was wondering if there's some server-side git config that does just this. I want to make this resillient to migrations in the future so that I don't have to change the remotes one by one when the time comes12:05
_ikke_ plantroon: there is no git config that can do this12:06
causa_sui joined12:09
plantroon well, I'll just pick better paths then :D thanks for the answers/advice12:11
_ikke_ it's common to have a dedicated user for it12:11
plantroon I noticed that, but I see no need for that. Especially in this case where all the hosts are only used by a single person and I already have elaborate ssh mechanisms set up revolving around just a single user running only very few well known verified apps12:13
causa_sui left12:13
Regon left12:14
Puffball left12:15
AKPWD left12:15
howdoi joined12:16
jstimm joined12:22
AKPWD joined12:22
n000g left12:27
fphilipe_ joined12:28
n000g joined12:30
fphilipe left12:30
royal_screwup21 joined12:32
fphilipe_ left12:33
victorqueiroz joined12:36
xcm left12:40
xcm joined12:41
agowa338 joined12:41
Noti left12:42
arecacea1 left12:45
arecacea1 joined12:46
de-vri-es left12:49
de-vri-es joined12:51
n3wborn left12:56
shawn_ joined12:56
shawn_scientes12:58
Emperor_Earth joined12:58
DropItLikeItsHot left12:58
lomex joined12:59
nabil joined13:00
fphilipe_ joined13:07
bashfulshell joined13:11
RoriconKnight left13:13
rohit[m] left13:13
savolla joined13:16
omnireq left13:19
hussam joined13:21
causa_sui joined13:24
AfroThundr|main joined13:25
YuGiOhJCJ left13:25
causa_sui left13:29
triad joined13:30
savolla left13:40
mven joined13:40
mven left13:40
HenryCH joined13:41
savolla joined13:41
HenryCH is there any way to retroactively tell git that a file has been renamed, such that a pull request shows the diff rather than -old +new file?13:42
fphilipe_ left13:42
HenryCH changes to history would be fine13:43
_ikke_ Git does not explicitly track renames13:45
HenryCH the commit where i renamed and made changes actually looks fine, the diff recognizes it's been renamed13:47
savolla left13:47
HenryCH but then i merged master into my branch and now the diff shows -old +new13:48
savolla joined13:49
Lucas_Gray left13:50
nurdie left13:52
beastd joined14:08
beastd left14:08
finalbeta left14:19
finalbeta joined14:19
lomex left14:19
Goplat joined14:20
HenryCH left14:25
nabil left14:38
causa_sui joined14:39
causa_sui left14:44
mowcat left14:48
nurdie joined14:52
nurdie left14:57
jstein left15:05
howdoi left15:05
kneeki joined15:05
tm007 left15:09
ferdna joined15:14
lomex joined15:18
lomex left15:19
achen_ left15:19
omnireq joined15:26
Shentino_Shentino15:27
jottr joined15:29
kneeki left15:31
cgi left15:34
cgi joined15:36
fphilipe_ joined15:38
agowa338 left15:39
dpyro joined15:42
JoeBaker joined15:42
thiago joined15:44
jottr left15:44
JoeBaker left15:45
JoeBaker joined15:45
thefatma joined15:48
JoeBaker left15:50
JoeBaker joined15:51
m0viefreak joined15:51
nurdie joined15:53
achen_ joined15:53
kjartan left15:54
causa_sui joined15:54
thefatma left15:55
xcm left15:57
xcm joined15:57
nurdie left15:58
causa_sui left15:59
kjartan joined15:59
JoeBaker left15:59
lomex joined16:02
dngray joined16:03
dngray with a rebase, can you squash it into the last commit?16:03
i guess i could change the date of the commit after squashing16:03
cdown left16:06
yyy- joined16:07
dngray https://stackoverflow.com/questions/454734/how-can-one-change-the-timestamp-of-an-old-commit-in-git16:08
ah16:08
yyy left16:10
fphilipe_ left16:11
achen_ left16:13
rohit[m] joined16:18
learningc left16:27
achen_ joined16:31
dngray left16:39
GGMethos joined16:39
fphilipe_ joined16:43
noobJS joined16:44
xcm left16:46
xcm joined16:47
noobJS left16:49
greatgatsby joined16:51
dviola joined16:54
BlessJah left16:54
SkarmoutsosV joined16:55
amosbird what are the upper and lower mean? https://la.wentropy.com/kb3Y.png16:59
czart_ joined16:59
Mr__Anderson joined17:00
czart left17:01
R2robot left17:03
analogical joined17:05
analogical hello is it possible to use rsync with git bash for windows?17:07
venmx joined17:07
_ikke_ I think so, yes17:07
Mattiaslndstrm left17:08
analogical how do I add rsync since it doesn't seem to be included by default?17:08
causa_sui joined17:10
ave_milia left17:10
causa_sui left17:15
fatalhalt joined17:15
fphilipe_ left17:17
mra90 joined17:19
mra90 so I have a repository which was forked from linux kernel mainline, how can I check the first commit they did after a fork took place?17:19
greatgatsby left17:24
neiluj joined17:25
nightshift joined17:28
agowa338 joined17:29
nightshift uggggg, I may have to scrape the best feature of my gitviewer, at least until I switch it to perl17:30
jottr joined17:30
shomon joined17:31
shomon hi, happy easter :D17:31
nightshift happy easter shomon17:31
shomon I'm trying to figured out of all thebranches in a repo, which ones have not been committed to master.. is there a command or quick way to get that?17:31
neiluj left17:31
shomon I thought it was git log --first-parent master17:32
osse mra90: Do you have the mainline Linux master branch in the same repo?17:32
shomon: git branch --no-merged master17:32
nightshift shomon: you mean the branches that haven't been merged?17:33
shomon yes17:33
nightshift ah, yeah, osse's answer.17:33
I think17:33
shomon thanks both!!17:33
theoceaniscool left17:33
shomon hmmm but I think I tried that too osse.. it gives me only one result here locally but I don't see all repos in master history17:34
neiluj joined17:34
nightshift shomon, is this a publicly available repo? I think there's a terminology issue going on.....17:35
shomon no, a private one on bitbucket17:36
nightshift would be easier to solve the issue if we can know what you're seeing versus what you're expecting to see17:36
cgi left17:39
noobJS joined17:41
achen_ left17:42
neiluj left17:42
czart_ left17:43
ravndal joined17:45
perrier-jouet left17:46
plongshot joined17:46
plongshot I thought git branch -r was supposed to list remote branches?17:47
dmc it does17:47
shomon ah so maybe git branch -r --no-merged master17:47
I'll try17:47
gotcha17:47
plongshot I have a repository using ssh connection to bitbucket but when I run git branch -r there is no output. The upstream connection is there and works fine.17:47
shomon ok that worked for me too thanks plongshot17:48
dmc try fetching first17:48
rewt that will list remote branches that have not been merged to the local master, which may not be at the same point as the remote master17:48
shomon yeah I wanted remote master17:49
rewt git branch -r --no-merged origin/master17:49
or if your remote is not named origin, replace that part with the remote you're insterested in17:49
thefatma joined17:50
plongshot dmc: np but help me understand.. The way this repos was created was git init done local then a empty repo created in bb, then git push --mirror <git@bitbucket/repo.git last was done locally. There are no changes or commits ahead on either. What does fetch do for this then?17:50
oh, i created some branches before pushing up to bb17:50
nowhere_man left17:51
nightshift are all the branches on bb?17:51
noobJS left17:52
dmc did you add the repo with `git remote`?17:52
plongshot The two repos are identical, new repo with a single (initial commit) file "LICENSE" and 4 branches created locally but nothing moire done. then mirror push rom local to upstream. I can see in my ide that there are no upstream or downstream changes. I will only have downstream since only me working.17:52
nightshift plongshot, so you never ran git remote add?17:53
dviola left17:53
plongshot oh I'm sorry also one part after creating the repo local is a had to run git remote add git@bitbucket/repo.git run locally17:53
So I really dunno why I wouldn see the remote branch when running git branch -r17:54
yes17:54
or I would not have been able to push17:54
I better take a closer look17:55
HotBeefDip joined17:55
plongshot ty17:55
nightshift well, you CAN push without the remote add, you just have to specify the url each time17:55
I just ran git branch -r on one of mine and saw the remote branches, but, It's not on bb, just a local network server17:56
might be a bb issue17:56
plongshot nightshift: Well I think that is how I formed the push command when I ran it (with the ssh address specified). So not sure now. I was having problems with bb about ssh working.17:56
mra90 so I have a repository which was forked from linux kernel mainline, how can I check the first commit they did after a fork took place?17:56
plongshot I had filed a ticket then thought it was resolved and closed it17:56
thx man peace17:56
nightshift hmmmmmm, good luck figuring it out plongshot17:56
thefatma left17:56
plongshot I know how to find out17:57
nightshift: thx17:57
jottr left17:57
dviola joined17:59
plexigras joined18:02
osse mra90: Do you have the mainline Linux master branch in the same repo?18:08
mra90 osse: no18:09
separate one18:10
how can I have it in the same repo? The second on is forked from mainline18:10
ggSo joined18:13
czart joined18:18
venmx left18:18
lomex left18:20
plongshot I want to do something specific, I have a realllly good reason why and I'm seeing the same stale information online that I don't think will lead me there. How can I mirror a local repo to the upstream repo? I am the only person (who may ever) work on this project and I am the only one now. I would like to create a situation where the operatoins done with the remote (push, pull, sync, fetch..) are --mirror by default.18:21
KnoP left18:22
plongshot I know I prolly said some things that don't fit. I have read the man page several times. I see a flag "-mirror[=(push|fetch)]" but not sure if it applies or how to use it.18:22
The changes made locally are always --mirror pushed and then go disable the ability to pull or sync on the remote end. (So changes can flow in only one direction).18:24
jottr joined18:24
nic-hartley joined18:24
causa_sui joined18:25
KnoP joined18:25
JoeBaker joined18:26
rohit[m] left18:26
rohit[m] joined18:27
Regon joined18:27
plongshot There has to be tools (sugar) to handle all this distributed connections and remotes and stuff18:28
Mattiaslndstrm joined18:29
causa_sui left18:29
jottr left18:30
R2robot joined18:33
osse mra90: You can add the original repo as a remote, fetch from it, then use git log18:35
Something like git log mainline/master..mybranch18:35
Assuming you name the remote mainline18:35
n3wborn joined18:36
mra90 osse: sounds good but how to add that mainline repo as remote?18:37
nowhere_man joined18:37
rsrx left18:38
n3wborn left18:40
greatgatsby joined18:40
n3wborn joined18:42
nightshift plongshot: it's my understanding that most mirrors are handled via hooks18:42
But, I haven't looked in to actually maintaining one, so, could be wrong18:43
manuelschneid3r joined18:45
osse mra90: git remote add mainline http://kernel.org/or/whatever.git; git fetch mainline18:46
plongshot nightshift: ok. I see information on other use cases which are similar but not my own. And, while I suspect a certain flag for the git remote command may help me, there doesn't seem to be any more friendly information on "-mirror[=(push|fetch)]" than what the man page says about it and I'm not seeing it.18:46
antimatroid joined18:46
plongshot information\information online18:46
antimatroid anyone on here make websites at all? I made my own site manager (https://nifty-site-manager.com) that works a lot like latex and git, I really like it and think others may like it as well..18:46
nightshift I understand plongshot, sorry :(18:46
plongshot just aking anyone. I appreciate ya man18:47
antimatroid I would love to know what people think, whether they just look at the site or have a play..18:47
nightshift of course, trying to help best I can!18:47
antimatroid, I do websites, but, I HATE page generators. Just personal opinion there....18:48
(I do use a couple drag and drop tools to help me play with layout, sometimes, but the idea of using a tool where I don't have full control of the code annoys me)18:49
mra90 osse: thanks, I will give it a try18:49
zonixo joined18:51
azwieg103 joined18:52
ggSo left18:52
antimatroid nightshift: what about page generators don't you like? this might not even do that..18:53
it has like @input commands similar to latex, so you can break things up in to multiple files, which can also be used for template files etc.18:53
nightshift antimatroid, I want full, absolute control of my code. Also, this is actually off topic for this channel18:54
hvxgr left18:54
plongshot Does it seem right the way I'm reading this in the man page? ($ man git remote | grep mirror). It looks like I can run something like git remote add --miirror=push run locally and run it one time to create a special kind of branch? Then every time I push from local to remote is will be done as a --mirror push even if I don't use the --mirror flag ever time I push?18:54
gitinfo the git-remote manpage is available at https://gitirc.eu/git-remote.html18:54
plongshot It sounds like that's what they are saying but it's a bit ambiguous to me.18:55
osse mra90: Do you know that the repo you have is a fork of Linux? Or have they started out with a tar ball of Linux and only have their own history?18:55
azwieg103 left18:55
osse Because if it's a separate repo started from some copy of git then my approach won't work18:55
antimatroid nightshift: you do have absolute full control of your code with this I think, I'd be curious to know if I'm right there if you do happen to take a look. My apologies for being slightly off-topic, however it's something that I think website makes who use git will really like, I'm not really sure what the best way to try and find those people is? Any suggestions would be awesome..18:56
nightshift plongshot: that's what it seems to be saying as well18:56
antimatroid, that fact that you (appear) to be using latex to generate the pages says not as much control as I'd like, because I'd still be depending on what you, and latex, think good html looks like18:58
antimatroid nah I have my own code for that, just use similar syntax18:58
it's a c++ program that 'injects' the text from one text file to another18:58
you can have a whole dag of inclusions and it'll throw errors for you if there's an input loop (tell you which file and line number too)18:59
I just like the latex syntax, less for me to learn/remember18:59
I may end up using something like this for programs that I'd like to be able to 'build' in to one single source file before compiling too, that could be an interesting use of this kind of thing19:00
Jubei joined19:00
plongshot This is what I was talking about earlier. https://imgur.com/a/cd6M8nR git remote add says the remote exists already but git branch -r yeilds no output and git branc -a shows no remotes19:00
Jubei hello :) I checked out an earlier commit, and that put me in detached head mode. I have since made a few commits but now I want to make my current state master (i.e. drop the old master)19:01
how do I do that?:)19:01
nightshift standby plongshot, I just read something that MIGHT explain your problem19:01
plongshot cool19:02
i b here19:02
nightshift plongshot "When a fetch mirror is created with --mirror=fetch, the refs will not be stored in the refs/remotes/ namespace, but rather everything in refs/ on the remote will be directly mirrored into refs/ in the local repository. This option only makes sense in bare repositories, because a fetch would overwrite any local commits."19:03
jottr joined19:03
nightshift notice the stuff about there being no refs/remotes19:03
plongshot nightshift: right. But for me it would be the other direction and I think that siad it does retain / push the refs going up19:04
nightshift In other words, depending on what you did, the mirror may not know it's a mirror19:04
Jubei sorry figured it out plx ignore me.19:05
plongshot There is a couple things going on. I'm not sure where the problem lies. In addition to wanting to set up this mirror thing, there seems to be a problem with the existing repo setup.19:05
MylesBorins left19:05
plongshot That's the second / other question that popped up first and then again a min ago19:05
MylesBorins joined19:05
plongshot nightshift: I see what you mean19:05
ok19:05
It is a almost empty repo no consequence to just do over. I'mna try learn something here. thx man19:06
nightshift of course. I'm looking at a number of pages here, trying to understand how this is done.19:07
Because, honestly, at some point I might want to have a full mirror of at least some of my repos too19:07
old article, but, might help http://blog.plataformatec.com.br/2013/05/how-to-properly-mirror-a-git-repository/19:08
MylesBorins left19:09
jottr left19:09
gloomy joined19:11
Jubei left19:12
MylesBorins joined19:13
plongshot nightshift: Yes. Not only is the use case as a backup in a private repo but also if you chose to use bitbucket or github solely to publish software (so the wiki maybe and maybe some other tools) but not a place of coordingation for a team - only to dissemiinate to the public only.19:13
fphilipe_ joined19:13
plongshot :>19:13
could be use case I mean19:13
probs joined19:15
nightshift yeah, that's what I'm thinking, the wiki, and issue tracker, but the actual dev is done locally, the "official" bare repo is on my local network, and, when I think I have an issue fixed, it gets pushed to my local server, then mirrored from there19:15
probs Hey I'm using gitbash to try and install make on windows 1019:15
I've created a makefile and tried running it with 'make' and I was getting the error "bash: make: command not found" so I googled it, downloaded minGW, installed a few packages (mostly C++ compiling ones), but mingw-get still doesn't work as a command in bash19:15
nightshift probs, that kind of stuff is why I've moved away from windows.....19:17
maybe try cygwin if you want bash on windows....19:17
(it's my understand that gitbash isn't a fully functional bash environment, but I could be wrong)19:18
steven joined19:19
probs ugh I just spent a few hours watching tutorials on how to use gitbash19:20
kapil____ left19:21
null1337 joined19:22
nightshift plongshot, further reading (this time on gitlab) shows that cron/hooks ARE involved it getting the auto-push/pull, at least in their implementation, sounds like it's the same for github19:24
plongshot Is git remote add supposed to give output if it succeeds?19:24
nightshift: thx. I will want to automate it too19:25
nightshift um, I don't think so plongshot19:25
standby....19:25
plongshot So I run git remote add --mirror=push git@bitbucket/my-repo.git and get a new command line. Then, when I do git branch -r there is no putput (new command line) and git branch -a does not show anything remote19:26
null1337 left19:26
nightshift plongshot, you haven't pushed it yet19:26
unless the = is a typo19:26
All you've done is added the remote19:27
now you need to git push19:27
plongshot nightshift: I did the git remote add locally before pushing anything up. The remote is sitting there empty at the time I issue the remote add command19:28
moritz remote add != push19:28
plongshot moritz: man git remote19:28
gitinfo moritz: the git-remote manpage is available at https://gitirc.eu/git-remote.html19:28
moritz remote add just adds the meta data, it doesn't actually do anything over the network19:28
gareppa joined19:28
plongshot there is an option there see it in the first or second line (for git remote add) that shows "--mirror=..."19:29
moritz When a push mirror is created with --mirror=push, then git push will always behave as if --mirror was19:29
passed.19:29
nightshift git remote add just tells you local .git that you have a remote. the remote doesn't get data until you git push19:29
plongshot --mirror=[fetch|push]19:29
moritz you still have to git push19:29
plongshot moritz: that's what I'm after19:29
you got it!19:29
nightshift plongshot, so, you have your git remote add --mirror=push....19:29
plongshot When I do git branch -r it is reading from upstream not local?19:29
nightshift you get a new prompt. NOW do git push......19:30
moritz plongshot: git branch -r is a local operation19:30
plongshot nightshift: I try to19:30
gareppa left19:30
plongshot moritz: Then if I did a git remote add .... blah... it shousl be listed19:30
no?19:30
gareppa joined19:30
moritz plongshot: no19:30
plongshot: becaues you haven't done anything yet that talks to the remote19:30
nightshift plongshot, not until you actually push, which you haven't done19:31
plongshot I understand. ty. I would (at some time) love love LOVE to find out about the internals (git internals) of all that :>19:31
moritz to first approximation, fetch/pull and push are the only operations that actually talk to the network19:31
plongshot this app blows me away!19:31
moritz: glad you addressed that - solid gold19:32
ty19:32
whn i come here you guys load me down w/ knowledgs. I leave w/ my head swole :p19:32
moritz (oh, and clone, and some low-level commands like ls-remote)19:32
plongshot right on19:33
I have to run for a min but I'll drop a note what happens (you already know).19:34
peace19:34
zonixo left19:35
HotBeefDip left19:39
jnewt joined19:40
causa_sui joined19:40
dege joined19:41
causa_sui left19:44
plongshot I should be able to just do git push origin then right? (origin was the name given and not anything unique).19:45
I guess it won't destroy my repo to try it19:45
nightshift won't destroy anything to try it19:46
arecacea1 left19:46
moritz having backups never hurts :D19:46
arecacea1 joined19:46
fphilipe_ left19:46
nightshift as for whether you use origin or not, it depends on what you named your remote, which, given the command you gave us for you remote add, may not actually do anything19:47
you can check the name by typing git remote while in your repo19:48
plongshot I added another screenshot showing the results of git push origin (success!). However, git branch -r and git branch -a still do not show any remote branch. https://imgur.com/7OxqSFV19:50
This seems odd to me. I have git init repo, added a file on master, added, and committed it, created 4 branches (all done locally), done git remote add --mirror=push <ssh address>, done git push origin (success) --> but git branch -r | -a list no remote branches19:51
nightshift plongshot, you never set your upstream.....19:53
you need the -u on a remote to get the branches there19:53
(I think)19:53
right now your local git doesn't know it needs to know about your remote branches19:55
thebope left19:55
plongshot nightshift: so I needed to run gtit push -u origin? I thought that might limit it to only pushing master though (and defeate the purpose of mirror option)19:55
nightshift plongshot, yes19:56
plongshot If I run with the -u flag after running the first time, will it reflect in my upstream history as 2 events?19:56
I'm nonestly feeling pretty frustrated. Somthing seems retarted and it's probably me. I don't like it19:57
why in the hell wouldn't git mirror option on a remote branch not work the way you would expect - Just do it - all of it.19:57
:p19:57
nightshift I don't think it would show as two events.19:57
plongshot lets see :>19:58
nightshift And, normally you'd mirror a bare repository, not your working one19:58
probs left19:58
gareppa left19:58
nightshift basically, you've missed a step (I get what you're trying to do, but, really, you need a setup closer to what I have, where you'd mirror your "local" bare)19:59
plongshot I added a third screenshot https://imgur.com/a/cd6M8nR showing results after running git push -u origin (after fist push). Still no remote branches listed20:04
rohit[m] left20:08
rohit[m] joined20:08
nightshift plongshot, try `git remote show origin`20:09
rohit[m] left20:10
rohit[m] joined20:11
czart left20:11
nightshift I still think this is related to the fact that you're trying to mirror a working repo and not a bare repo20:12
plongshot I don't know why but I did a git remot --verbose update. It changed nothign about the output of git branch commands. Yes.. There is pleny of relevant output with show origin. But nothgin explains why the git branch commands wojld not yeild output.20:13
cdown joined20:13
nightshift plongshot, really pretty sure it's because you're using mirror in a way that it's not supposed to be used20:14
plongshot nightshift: Earlier (I never said so here) I was looking into making a bare repo upstream to mirror to but had a question about that (assuming its even possible). Then I thought the way man git remote read indicated you didn't need to.20:15
gitinfo nightshift: the git-remote manpage is available at https://gitirc.eu/git-remote.html20:15
plongshot it on my computer too20:15
im reading it over an over20:15
nightshift plongshot, do me a favor and try `git push -u origin <branchname>` for every branch you have20:16
the manpage is a bit misleading for what you are trying to make it do.......20:16
plongshot when it speaks of the --mirror= ... optoin with git remote add, it says it only makes sense when talking about "=fetch" but when talking about "=push" they describe e different behavior.20:16
nightshift remember, when you mirror, the mirror things everything is local.20:16
plongshot oh wow20:17
what!20:17
I can picture something like that but what the hell?20:17
nightshift ?20:17
plongshot yeah - I have to find out the interals of that to really get it20:17
this is awesome!20:18
its working that what counts20:18
nightshift :)20:18
m4rsh joined20:19
nightshift you have to set each branch to track upstream, not the repo as a whole.20:19
plongshot yeah - upsteram matches but no tags. I guess I gotta do a git push --tags too :)20:19
nightshift I would really suggest though, that you give up on trying to mirror your working repo, that's not what mirror is for.20:19
yup20:20
fphilipe_ joined20:20
nightshift plongshot, have you read the git book?20:20
plongshot nightshift: I thought that's what was indicated in the output of git push -u origin (seen in the screeenshot). It maps each branch to the remote branch with the same name in that output.20:20
moldybits left20:21
plongshot nightshift: I can't convince anyone ('ve treid). ... I have to learn how it works for me - jump in deep, way deepp and flail like hell till I get to the top20:21
That's what works for me - actually doing it then the conceptual that ties it all together follows20:21
but I know of the book - ty20:21
nightshift plongshot, git forces you to set the upstream for each branch, because sometimes, in really large projects, a developer will work alone on a branch (usually a small issue or feature), and NEVER push that branch anywhere. To make sure that branch doesn't accidently get pushed, you have to explicitly tell git to push, AND track.20:22
I understand, I have to jump deep too, but, there are a few basics that would have saved the last few hours :)20:23
as an example, I barely know bash and git, but I'm trying to write a static replacement for gitweb in bash :)20:24
plongshot nightshift: Are you speaking in the context of only additional branches from this point? There were 4 branches local before the inital push upstream. That I thought was taken care of.20:24
Are you saying that branches created after this will have to explicitly be published?20:25
nightshift (and, apparently, one of the things I'm trying to do with that can't be written in pure bash, so I'm doing a massively deep dive into awk because apparently THAT can do it, and can be called from bash)20:25
plongshot ok20:25
I follow20:25
I see20:26
nightshift plongshot, the 4 branches you previously created had to have the explicit git push -u, AND all future branches will have to have a git push -u20:26
rohit[m] left20:26
plongshot I get so frustrated and bogged down like that I can't go on and I abondon my love, Then all kinds of negative feelings fester. It's not good.20:26
rohit[m] joined20:27
cybrNaut i'm looking for a freedom-respecting repo service that supports web page projects. That means github.com and gitlab.com are ruled out. notabug.org and codeberg.org seem philosophically perfect, but I'm not seeing how to deploy a website on those platforms (apparently no "github pages" equivalent)20:27
nightshift If you want them to make it to the server, and have your local repo also know that the server has them, that is20:27
plongshot cybrNaut: I use bitbucket and like it20:27
They set new repos to private by default and seem to offer a lot for free20:28
nightshift plongshot, bitbucket doesn't have his website support though20:28
cybrNaut plongshot: i heard bad things about bitbucket using nonfree software and lots of non-free j/s pushed on users.20:28
nightshift There's a reason even github removed their github pages20:28
cybrNaut ah, well no website support kills it20:28
plongshot I didn't know that Sorry to hear it :(20:28
yyy joined20:29
plongshot Is the server version any different? I don't know about github but bb has an installable version that may offer more funcitonality. I have no idea.20:29
rohit[m] left20:29
plongshot But that's a whole new ballgame - installing, config, maintianing it youself20:30
cybrNaut nightshift: really? i'm using github pages and it seems fine20:30
nightshift Yeah, but they're trying to shut it down, I heard20:30
moldybits joined20:30
plongshot there are github pages. I never used them but I know they exist20:30
Envil left20:31
justanotheruser left20:31
basiclaser left20:32
yyy- left20:32
nightshift cybrNaut, this is a fairly common question we get (minus the free part), there really aren't any other alternatives.20:33
if you don't mind self hosting, gitolite, MIGHT be able to do what you want20:34
cybrNaut thanks for the tip but i'm trying to avoid self-hosting ATM.20:35
maybe if i get desperate i'll try to put a web server on a openwrt box20:36
nightshift there are a lot of people trying to self-roll a solution, haven't heard of anyone with a successful solution20:36
cybrNaut, I've got one running on a raspberry pi (along with git and dns), but, my codebase is small. At some point I'll need more cpu and ran20:37
er, ram20:37
but, I don't use git to populate the sites I have up20:37
yonder joined20:38
plongshot left20:39
perrier-jouet joined20:40
ferdna left20:43
ferdna joined20:46
Narrat joined20:47
nightshift Think I'm gonna shut down for a while and go for a walk.20:48
nightshift left20:49
HotBeefDip joined20:51
aruns joined20:52
aruns Hi, I am building a Git submodule for common hook scripts we can use at work.20:52
What is the best way to handle Windows support?20:53
moritz ignore it20:53
HotBeefDip I have a group project in one of my university courses that uses a self-hosted GitLab instance...they decided to do maintenance on campus during Easter weekend, so my group doesn't have access to the server...if I push my local repository (that has been linked to my school's GitLab instance up until now) to a brand new repo on GitHub, so my group will have a temporary place to work, will this cause major issues for us when we20:54
switch back to the GitLab server?20:54
moritz HotBeefDip: no git-level issues20:54
osse aruns: Maybe write the scripts in python?20:54
moritz just maybe privacy issues, dunno what's in the repo20:54
Timvde Huh. Can a git merge overwrite uncommitted changes?20:55
moritz Timvde: no, it aborts rather than doing that20:55
causa_sui joined20:55
Timvde moritz: That's what I thought, but it just happened20:55
HotBeefDip moritz : nothing of importance...a very poorly designed web-app built by 3rd year undergrads ;-)20:55
Timvde File foo and bar. foo is untracked, bar is tracked. Merge in a commit that renames bar to foo. Foo is gone.20:56
Is this a bug?20:56
moritz Timvde: !repro please20:58
gitinfo Timvde: [!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 see20:58
Timvde moritz: sure20:58
moritz Timvde: I just tried a minimal example, it said: error: The following untracked working tree files would be overwritten by merge:20:58
foo20:58
is this on a case insensitive (or case-preserving) file system, with different casings for foo involved?20:59
Timvde Nope, ext420:59
seds joined20:59
wwwi joined20:59
Timvde It's actually a friend of mine who found it, so here's his repo: https://git.principis.be/Principis/zucht20:59
wwwi hello21:00
causa_sui left21:00
Timvde clone it, reset master to master~, create a file named test.txt and merge master back in21:00
wwwi if you use git to upload files in a git server, that means you no longer need to use total commander?21:00
aruns osse: That might work, thanks.21:02
moritz Timvde: holy shit, you are right. That looks like a bug to me21:02
mooasaurus left21:02
moritz I could reproduce it with that repo21:02
mooasaurus joined21:02
Timvde moritz: it's strange that you couldn't reproduce it with your repo21:02
I wonder if it has something to do with the "double extension"?21:02
but let's start with filing a bug21:03
And creating a cleaner version of that repository, because I just noticed that it has bad language (in Dutch) :P21:04
theoceaniscool joined21:06
Timvde moritz: OH21:07
I just noticed something that he failed to mention when explaining it to me21:07
I'm not sure what behaviour I expect then...21:07
moritz: In the first commit (master~), test.txt is in .gitignore; it is removed in the second commit21:07
I suppose I can understand the behaviour then... Not sure if I'd consider it to be a bug21:08
because as far as git is concerned, the file didn't exist when applying the second commit21:09
mven joined21:14
JoeBaker left21:14
sschw joined21:14
sschw left21:15
aruns osse: If I create both a shell script and say a batch script21:19
Is there a way to get the OS to determine which one to read?21:20
Or I suppose I can just call CMD from the shell script.21:21
nic-hartley This looks promising: https://stackoverflow.com/a/17623721/186356421:25
seds left21:25
Emperor_Earth left21:25
SkarmoutsosV left21:25
nic-hartley It takes advantage of : being the label marker and only allowing certain characters after it, so if you put anything ELSE it's effectively a comment. Whereas in POSIXish shells it's a valid command with no effect.21:26
BlessJah joined21:28
justanotheruser joined21:36
jcbitter joined21:37
hvxgr joined21:38
midnightmagic left21:38
AtumT joined21:39
Phylock left21:40
nightshift joined21:47
greatgatsby left21:50
theoceaniscool left21:51
DrunkZZZ joined22:07
dege left22:10
causa_sui joined22:10
kjartan left22:11
osse aruns: Git just runs the hooks directly by name like executables. You'd need to write a wrapper. Hooks don't need to be scripts either.22:12
fphilipe_ left22:12
g00s joined22:14
causa_sui left22:15
Phylock joined22:16
kjartan joined22:17
midnightmagic joined22:24
nowhere_man left22:25
gloomy left22:28
seds joined22:29
plexigras left22:33
Globe_Bloater left22:34
aruns left22:36
fphilipe_ joined22:37
DrunkZZZ left22:38
shomon left22:39
nightshift osse: is there an additional reference for hooks, the book, and man pages seem a bit light, for my ability to understand writing custom actions anyway22:42
seds left22:43
nurdie joined22:59
random_yanek left23:00
nurdie left23:04
finalbeta left23:04
igemnace joined23:05
g00s left23:06
osse nightshift: don't know of any23:07
what do you want to know?23:07
nightshift thanks, I was hoping I was just missing something23:07
acercle joined23:08
random_yanek joined23:08
random_yanek left23:08
nightshift at this point, I don't know exactly what I want to know, just that I didn't see much "help" in what I'd found....23:08
osse nightshift: What you want to use them for is entirely up to you. Maybe that's why. There's a limit to what the docs actually can say other than how to run them23:11
fphilipe_ left23:12
nightshift Primarily what I'm looking at are 2 possible options (the first is the one I care about the most). I'm writing a static repo viewer that I would, ultimately, like to have a hook execute anytime a repo is pushed to23:13
(maybe with some optimizations so that it only runs once every x minutes, in case someone goes on a push frenzy, pushing all their repos one after the other)23:13
Beam_Inn_ joined23:14
nightshift the other one is less likely to actually be put to use, but would involve pushing to a mirror23:14
justanotheruser left23:15
n3wborn left23:15
random_yanek joined23:16
random_yanek left23:16
royal_screwup21 left23:17
random_yanek joined23:18
random_yanek left23:18
Olipro joined23:24
causa_sui joined23:25
Mr__Anderson left23:26
causa_sui left23:30
duderonomy left23:31
random_yanek joined23:35
lamont left23:40
meLon joined23:40
alyptik left23:41
Narrat left23:43
leeN left23:46
Phylock left23:48
justanotheruser joined23:54
manuelschneid3r left23:59

Logs Search ←Prev date Next date→ Channels Documentation