IRCloggy #git 2020-05-29

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.

2020-05-29

doug16k left00:00
sudomake left00:02
sudomake joined00:03
rafasc Intelo: that should not discard uncommitted changes.00:03
hexnewbie left00:04
Intelo rafasc, thats why I am surprised00:06
sudomake left00:08
doug16k joined00:10
ghost43 left00:11
ghost43 joined00:12
fission6 left00:13
orbyt_v7 left00:14
g4570n left00:19
tiin57 left00:19
xerox_ joined00:19
g4570n joined00:20
tiin57 joined00:22
xerox_ left00:24
zalt joined00:33
jstein left00:34
zalt this probably sounds weird, but can you push to a local branch?00:34
i mean a shortcut for checkout target_branch then merge source_branch00:34
fairuz left00:34
petaflot left00:36
xcm left00:37
robink left00:38
xcm joined00:38
robink joined00:39
rafasc zalt: you can use . as remote00:40
zalt so git push . master?00:40
ar1el left00:47
petaflot joined00:48
rafasc zalt: but for most cases where a merge is actually needed, git needs files in the worktree.00:49
tiin57 left00:49
rafasc if you dont need a merge, you can just reset the branch manually with git branch -f branch1 branch200:49
zalt hmm, my use case is a branch that is never checked out, only used for pushing and pulling from other machines00:50
ohmyfromage left00:50
rafasc or just create a new worktree, and merge there.00:50
zalt i should probably use a --bare repo for that, but i'm lazy00:50
rafasc you can do $git push . src:dest00:51
zalt Ha!, that works, thanks00:52
ohmyfromage joined00:52
tiin57 joined00:53
caffeinatedcode left00:55
Cabanossi left00:56
Cabanossi joined01:01
forrestv left01:03
maryo_s joined01:04
maryo left01:07
przemoc joined01:08
shush left01:13
shush joined01:14
ferdna joined01:18
tiin57 left01:19
causasui joined01:19
shush left01:20
tiin57 joined01:23
jaziz joined01:28
forrestv joined01:31
albel727 joined01:37
crose left01:39
royal_screwup21 left01:41
shush joined01:41
royal_screwup21 joined01:41
Muimi joined01:45
tiin57 left01:49
caffeinatedcode joined01:49
opal left01:50
tiin57 joined01:52
kjartan left01:56
rafasc left01:57
clime left01:58
kjartan joined01:58
royal_screwup21 left01:59
royal_screwup21 joined02:00
Decobus left02:01
Decobus joined02:04
royal_screwup21 left02:04
opal joined02:05
g4570n left02:06
shush left02:07
fairuz joined02:09
Decobus left02:14
bitnoize left02:16
Decobus joined02:17
Sasazuka left02:17
cdown left02:18
tiin57 left02:19
lagothrixGuest6108002:21
Guest61080 left02:21
lagothrix joined02:21
tiin57 joined02:22
Cabanossi left02:24
SunRaycer left02:25
Cabanossi joined02:28
xerox_ joined02:33
opal left02:35
opal joined02:36
SunRaycer joined02:37
xerox_ left02:37
Benjamin_S joined02:38
fairuz left02:39
opal left02:41
shush joined02:42
opal joined02:43
causasui left02:48
tiin57 left02:49
Benjamin_S left02:51
tiin57 joined02:53
opal left02:54
bilb_ono joined02:55
bilb_ono ok so I have a bunch of code in this project I made. Someone else on my team made a git repo and commited a README. I would like to clone this repo. git add all of the files in my projects, commit, and push back to github. Whats the order of operations for this?02:56
do I git clone his existing repository in my directory?02:56
or git init in my directory first?02:57
mackerman clone will download a repo, needs to be a new directory02:59
In this clone, make yourself a new branch, add and commit your stuff. Suggest they pull from you.03:01
bilb_ono mackerman: so Ill basically have to move my stuff locally first, clone their repo, move my stuff back, git add it, commit, push03:03
?03:03
shush left03:04
mackerman More than one way to do it.03:04
mekhami left03:05
mackerman git init in your project directory, branch, commit, add the remote.03:05
shush joined03:06
mackerman clone has some very minor advantages like setting up the remote for you03:06
oojacoboo left03:07
shush left03:07
bilb_ono ok and then pull request on github once my branch is up there?03:08
shentino_Shentino03:10
mackerman Sure. Whatever process you want.03:12
Push your branch to this presumably shared repo, pull request, merge.03:13
bilb_ono mackerman: so I did git init, git checkout -b new-branch, git commit stuff, git push03:13
but it says: error: src refspec master does not match any03:13
ohh I have to push to the branch03:14
opal joined03:18
tiin57 left03:19
bilb_ono what does it mean when Im trying to create the pull request and it says” There isn’t anything to compare. master and alex-branch are entirely different commit histories.”03:20
it shows all my changes in the files changed below03:20
nabil joined03:21
Goplat joined03:22
NODE left03:22
forrestv left03:22
tiin57 joined03:22
nabil left03:23
bilb_ono it is true that they don’t share any of the same commit histories03:23
jimi_ left03:23
bilb_ono but thats the whole point03:23
nabil joined03:23
cgi left03:23
NODE joined03:24
oojacoboo joined03:25
mackerman Do you care about any history in the master branch?03:26
durham joined03:28
bilb_ono no03:29
mackerman Might as well merge into your master and push origin master03:30
robertparkerx Why when I add a file to gitignore it is still in the repository03:30
mackerman Although, without any history yet might be simpler to go back to the clone the remote as a new repo, branch, and add. Then they have the same history.03:31
bilb_ono mackerman: Im lost. So I should go, clone the remote as a new repo in my project directory? Rather than git init’ing?03:35
I also dont understand the point of the branch03:35
forrestv joined03:35
bilb_ono can’t I just git clone, and that creates the history, then add my files to a new git commit, and then push that to github?03:36
so hopefully in the end there is a history of 2 commits - one that the original repo had and mine03:36
chiastre left03:37
mackerman bilb_ono: cloning ensures they start from the same history.03:37
jimi_ joined03:37
mackerman I neglected that as there really isn't history in the remote to preserve, but it makes things messier.03:38
The branch is just the habit of doing everything as branches and PRs.03:38
Push directly into the one branch if you wish.03:38
jimi_ left03:39
bilb_ono mackerman: ok I don’t care about preserving the remote’s history. So the simplest way to do it is to clone from the remote in my projecty dir as the first step?03:39
mackerman robertparkerx: Ignore is not remove. You can rm or clean ignored files.03:39
robertparkerx how do I remove just one file?03:41
chiastre joined03:41
mackerman bilb_ono: Yes, simplest is to clone03:41
robertparkerx It is trying to remove a lot03:41
git rm -r --cached some-directory03:41
omar_trisquel left03:41
bilb_ono mackerman: when I try and git clone in my existing project dir (after doing rm -rf .git), it says: fatal: destination path 'tap-distru' (my repo name) already exists and is not an empty directory.03:45
robertparkerx I got it03:45
bilb_ono how does it know about this if I rm -rf’d .git ?03:45
shush joined03:46
tiin57 left03:49
mackerman bilb_ono: Clone creates a new directory. Simply not being a git repo is not enough.03:50
bilb_ono left03:50
bilb_ono joined03:50
bilb_ono oh it has to be a new one03:50
idk. ill try again later03:50
bilb_ono left03:51
bilb_ono joined03:51
tiin57 joined03:53
shush left03:54
bilb_ono left03:56
kjartan left04:02
kjartan joined04:02
robertparkerx git rm -r --cached some-directory ( why did it delete so many files when I ran this )04:06
ferdna left04:07
mackerman Because you asked it to? git rm delets every pathspec you give it.04:11
robertparkerx oh I thought it would delete all that the gitignore said to04:11
mackerman git clean -X --dry-run04:12
vdamewood joined04:13
robertparkerx what does that do04:13
I'm trying to learn more sorry04:13
mackerman man git clean04:13
gitinfo the git-clean manpage is available at https://gitirc.eu/git-clean.html04:13
robertparkerx ty04:15
tiin57 left04:19
supernovah joined04:20
fattredd left04:20
Guest20 joined04:21
tiin57 joined04:23
xcm left04:27
xcm joined04:28
fstd_ joined04:28
fairuz joined04:28
robertparkerx mackerman will I have to add + commit ?04:31
fstd left04:32
fstd_fstd04:32
mackerman Yes, you'll need to add deletes you want to commit.04:34
If the files are gone from the working tree but still in the index, consider git add -u04:34
orbyt_ left04:35
orbyt_ joined04:37
dedowsdi left04:42
supernovah if I've got a server with a receive.denycurrentbranch ignore enabled, and I commit to it, it stays checked out wherever I had it, and my pushes stack on top of it right, so what command do I run in that working-tree to move it to the latest commit04:43
because whenn I looked at it, it said HEAD -> master, (the latest commit) but I ran my deployment scripts in it and they were clearly building the older software04:43
and no matter what I ran, it seemed to stay that way, I ended up having to clean -f -d -x and reset --hard which meaning reinstalling a lot of software04:44
causasui joined04:47
Hello71 left04:48
xcm left04:48
xcm joined04:48
Hello71 joined04:48
tiin57 left04:49
tiin57 joined04:52
durham left04:54
Phylock joined04:55
benyoo joined05:03
benyoo Can I deactivate the warning: LF will be replaced by CRLF.. without getting a problem?05:04
is_null left05:11
hbautista left05:12
bettencb joined05:13
opal left05:19
tiin57 left05:19
bettencb left05:21
tiin57 joined05:23
cliluw left05:24
calcul0n joined05:27
k3yp left05:29
sauvin joined05:31
k3yp joined05:31
opal joined05:33
dedowsdi joined05:34
Newami joined05:36
Newami left05:40
gordonfish left05:49
tiin57 left05:49
z8z joined05:51
Codaraxis left05:52
bilb_ono joined05:52
tiin57 joined05:53
Codaraxis joined05:54
Betal left05:56
bilb_ono left05:57
hurfdurf left06:06
hurfdurf joined06:06
Rick8024 joined06:08
KnoP left06:09
Rick8024KnoP06:09
theorangeone left06:10
g00s left06:11
theorangeone joined06:11
tiin57 left06:19
gxt left06:23
tiin57 joined06:23
Ignacy left06:24
causasui left06:24
thiago left06:24
Ignacy joined06:24
shush joined06:26
gxt joined06:27
akem_ joined06:27
hqdruxn08_ joined06:28
Goplat left06:29
CCR5-D32 left06:29
akem left06:30
shush left06:31
hqdruxn08 left06:32
xerox_ joined06:39
z8z left06:41
Trieste left06:43
xcmGuest1320006:43
Guest13200 left06:43
xcm joined06:43
xerox_ left06:44
g00s joined06:44
maryo_s left06:44
maryo_s joined06:44
Trieste joined06:45
tiin57 left06:49
mightyjens joined06:50
tiin57 joined06:53
Guest20 i did a git add06:53
and it added few files06:53
now i want to remove a particular file06:53
how do i do that06:53
GreateSMB1 git rm --cached filename.ext06:56
hexnewbie joined06:58
waveclaw left06:58
waveclaw joined06:58
jaziz left06:59
chele joined07:00
quetz joined07:01
random_yanek left07:02
thansen left07:04
jaziz joined07:04
DarthRadar left07:07
mns_ joined07:08
rfuentess joined07:08
DarthRadar joined07:08
mns left07:08
random_yanek joined07:09
mr_shaman joined07:14
linuxdogXdog joined07:15
linuxdogXdog hello to All here,07:16
I am a new comer here07:16
ikke welcome07:16
linuxdogXdog Because this channel need a registerd account07:16
bill@b450:~/ALL_GTSDK/rk3326/rk3326-android8.1.pub/kernel$ git show 180ac2759bc8d94de46aa868c03e94110e8cbde2 --name-status07:17
commit 180ac2759bc8d94de46aa868c03e94110e8cbde207:17
Author: Bill Zhao [email@hidden.address]07:17
Date: Tue Dec 3 14:31:49 2019 +080007:17
rotate logo 90 degree07:17
07:17
Change-Id: Id17199c2da9301cde9b6de6177ee71b778fe7aea07:17
T logo.bmp07:17
A logo.bmp.ori07:17
T logo_kernel.bmp07:17
A logo_kernel.bmp.ori07:17
ikke linuxdogXdog: please use a paste service07:17
linuxdogXdog A logo_kernel_r90.bmp07:17
A logo_r90.bmp07:17
Can somebody here can tell me what does it mean by "T"07:17
@ikke are you refering to the pastebin07:18
?07:18
thansen joined07:18
ikke some kind of pastebin07:19
!paste07:19
gitinfo Please use a pastebin for snippets longer than one line. Persistent and can be used with a GitHub account: https://gist.github.com/ - one hour auto-delete: https://upaste.de/07:19
tiin57 left07:19
ikke I don't think that git uses T for status07:20
linuxdogXdog @gitinfo good!07:20
ikke Cannot find a reference to it07:20
!botsnack07:20
gitinfo Om nom nom07:20
ikke !bot07:20
gitinfo [!gitinfo] I am an IRC bot which responds to certain keywords to provide helpful(?) information to humans. Please see https://gitirc.eu/bot for more information about how to (ab)use me.07:20
ikke linuxdogXdog: is this comming from gerrit?07:21
waveclaw left07:21
linuxdogXdog @ikke The documentation of git status didn't mention it, but I have just see it in my kernel project07:22
ikke Is it using gerrit?07:22
Change-Id is something gerrit uses07:22
tiin57 joined07:23
linuxdogXdog the project belong to a repo projects group (Android )07:23
sunri5e left07:23
ikke ok, then look at the specific documentation07:24
linuxdogXdog no gerrit info in my projects repo07:25
sunri5e joined07:25
ikke yeah, I don't think android is using gerrit07:25
fabs joined07:26
muhaha joined07:29
muhaha guys? i need help, any idea how can i git diff changes if they are from specific folders ( there will be json with defined projects with dest dir) ? I need to get which project is impacted by diff. its monorepo with multiple projects :X07:31
oxymoron93 joined07:33
Rav3n left07:37
muhaha something like https://github.com/simplesurance/baur -> define projects and locations a be able to get which project has changed07:41
then i want to trigger command, instead of build07:41
linuxdogXdog @ikke In the google aosp, .repo/manifest.xml does have a line of "review="https://android-review.googlesource.com/" />"07:42
the "android-review" should be gerrit , I am not sure!07:43
@likke but the android project I am using is customized by hip vendor, it don't have the line of review= ...07:44
green- left07:45
orbyt_ left07:45
clara97 joined07:46
g00s left07:46
green- joined07:46
ncdulo left07:47
tiin57 left07:49
tiin57 joined07:52
mat001_ left07:57
varesa left07:59
varesa joined08:01
cebor left08:04
cebor joined08:05
Eryn_1983_FL left08:09
linuxdogXdog left08:10
Eryn_1983_FL joined08:11
xerox_ joined08:16
rsrx joined08:17
tiin57 left08:19
xerox_ left08:20
jellium joined08:21
fairuz left08:21
jellium_ joined08:21
jellium_ left08:21
jellium_ joined08:22
ShapeShifter499 joined08:22
jellium_ left08:22
jellium_ joined08:22
tiin57 joined08:23
jellium hi08:24
gitinfo jellium: hi! I'd like to automatically welcome you to #git, a place full of helpful gits. Got a question? Just ask it — chances are someone will answer fairly soon. The topic has links with more information about git and this channel. NB. it can't hurt to do a backup (type !backup for help) before trying things out, especially if they involve dangerous keywords such as --hard, clean, --force/-f, rm and so on.08:24
jellium_ left08:24
jellium_ joined08:24
jellium_ left08:25
ncdulo joined08:26
jellium left08:27
shush joined08:27
xerox_ joined08:28
shush left08:31
realloc joined08:37
realloc hi, in our repository we have some files which look like textfiles but which actually can not be merged manually in case of conflict because they are too complex. There is a special merging tool for them. Hence, I configured a [merge "toolname"] entry in my .gitconfig for them and set merge=toolname in the gitattributes file for the affected filetype. This works well with "git merge", however, "git08:40
rebase" seems to ignore the merge=... setting of the gitattributes file. Do you know how I can fix this? Thank you very much08:40
dedowsdi left08:41
dedowsdi joined08:42
Ploppz joined08:44
T_UNIX joined08:44
is_null joined08:46
tiin57 left08:49
tiin57 joined08:52
syr left08:55
syr joined08:56
rsrx left08:58
dedowsdi left08:59
dedowsdi joined08:59
linuxdogXdog joined09:01
cebor left09:03
cebor joined09:04
Muimi left09:10
Ploppz left09:16
dedowsdi left09:17
GreateSMB1 left09:19
tiin57 left09:19
rsrx joined09:19
tiin57 joined09:23
zalt left09:35
Muimi joined09:36
zalt joined09:39
ChrisLane left09:41
Ploppz joined09:42
ChrisLane joined09:43
planetcall|work joined09:44
R2robot left09:46
cdown joined09:46
Guest20 left09:48
bitnoize joined09:48
BPL joined09:49
tiin57 left09:49
tiin57 joined09:52
clara97 left09:55
lesshaste joined09:57
lesshaste sorry my nick broke.. I was asking about image licenses09:58
maryo_s left10:01
vals_tango_10:02
maryo joined10:02
zalt left10:03
maryo left10:03
maryo joined10:03
zalt joined10:03
cadmio joined10:04
cadmio does anyone know how can I create a deb package from sources download with git ?10:04
ikke Something like https://github.com/goreleaser/nfpm10:06
cim209 left10:07
garrettw joined10:10
cim209 joined10:10
cadmio when I do apt-get --build source package_name, what should I put in the place of "source" ?10:13
opal left10:13
cadmio my repository?10:13
ikke cadmio: no10:13
cdown_ joined10:13
ikke afaik, that's for building source packages10:13
ie, prepared packages that have build instructions inside10:14
cdown left10:14
ikke https://blog.serverdensity.com/how-to-create-a-debian-deb-package/10:14
crose joined10:15
ikke https://www.man7.org/linux/man-pages/man1/dpkg-deb.1.html10:15
You need to do a little bit more preparation10:15
cdown joined10:15
ajbura left10:16
ikke If you don't use something like (n)fpm, then you need to create a control file with metadata10:16
you also need to create the directory structure as it should end up on the target system10:17
zalt left10:18
cadmio so I need : 1) The upstream tarball with .tar.gz ending and 2) A description file with .dsc ending.10:18
cdown_ left10:19
tiin57 left10:19
cadmio left10:21
tiin57 joined10:22
rafasc joined10:27
opal joined10:27
cadmio joined10:28
michele is there any git GUI for linux or macOS that shows the diff between branches?10:28
shush joined10:28
moldy i'd be surprised if there is one that does not do that10:30
rafasc !guis10:30
gitinfo Popular GUIs for Git are listed on the website: http://git-scm.com/downloads/guis10:30
benyoo left10:31
zalt joined10:31
shush left10:32
ChrisLane left10:40
ChrisLane joined10:44
bdeshi left10:49
tiin57 left10:49
bdeshi joined10:49
zalt left10:51
vicfred_ joined10:51
tiin57 joined10:53
akem_ left10:53
zalt joined10:53
vicfred left10:54
muhaha left10:54
zalt left10:56
zalt joined10:58
akem joined11:00
akem_ joined11:00
akem_ left11:00
lesshaste left11:09
geowiesnot joined11:10
vdamewood left11:11
foul_owl_ left11:15
mac_ified joined11:15
zalt left11:16
foul_owl_ joined11:16
tiin57 left11:19
zalt joined11:20
Kaivo left11:21
Kaivo joined11:21
SunRaycer left11:21
tiin57 joined11:23
BPL left11:23
akem_ joined11:24
akem left11:27
ChrisLane left11:30
ChrisLane joined11:31
zalt left11:35
dumb_moth left11:47
_Warl0ck left11:47
zalt joined11:47
perrier-jouet joined11:48
_Warl0ck joined11:49
tiin57 left11:49
dumb_moth joined11:50
tiin57 joined11:52
mr_shaman left11:53
cadmio left11:54
dumb_moth left11:55
dionysus69 joined11:57
n000g left11:57
dumb_moth joined11:57
n000g joined11:59
muhaha joined12:04
gp5st_ joined12:09
Tahvok left12:10
Muimi left12:11
perrier-jouet left12:12
tchan joined12:13
jaziz left12:13
gp5st_ left12:13
ezakimak left12:15
yonder left12:16
ezakimak joined12:17
tiin57 left12:19
yonder joined12:21
tiin57 joined12:23
shush joined12:29
Tahvok joined12:29
cgi joined12:32
shush left12:33
gavlee left12:35
mr_shaman joined12:37
fission6 joined12:40
fission6 left12:41
Aattas joined12:41
Jck_true left12:41
Maxattax joined12:42
Jck_true joined12:42
fission6 joined12:43
CodeSlingerPaul joined12:43
axisys left12:43
tiin57 left12:49
tiin57 joined12:53
planetcall|work left12:53
oprypin left12:55
Betal joined12:55
oprypin joined12:55
gitoso joined12:56
gitoso left12:58
cdown_ joined13:02
cdown left13:03
cdown_cdown13:03
Intelo left13:05
maryo_s joined13:05
bettencb joined13:05
bettencb left13:05
gxt left13:07
gxt joined13:07
feriman joined13:07
maryo left13:08
xcm left13:09
xcm joined13:10
mat001 joined13:11
troulouliou_div2 joined13:12
troulouliou_div2 left13:17
gavlee joined13:17
tiin57 left13:19
Betal left13:20
lmurar1 joined13:22
tiin57 joined13:22
is_null left13:24
is_null joined13:25
lmurar1 left13:25
durham joined13:25
lmurar178 joined13:28
lmurar178 left13:28
lmurar1 joined13:29
durham left13:30
is_null left13:30
mightyjens left13:31
is_null joined13:33
CCR5-D32 joined13:35
is_null left13:37
is_null joined13:40
Betal joined13:42
feriman left13:43
aliss joined13:45
dedowsdi joined13:46
tiin57 left13:49
tiin57 joined13:52
KnoP left13:54
diogenese left13:56
diogenese joined13:56
Newami joined13:57
Newami left13:57
axisys joined13:58
axisys left14:02
hbautista joined14:02
oojacoboo left14:03
santosh26 joined14:05
oojacoboo joined14:08
santosh26 left14:08
cd joined14:09
Nickeeh I'm trying to find the introduction of a line, so I used 'git log --all -G FooLine', but the first result is a removal of that line. I don't get it.14:13
ikke Nickeeh: try to add --full-history14:14
shush joined14:14
zalt_ joined14:15
floatingman left14:15
Nickeeh ikke: ah.. thanks but it turned out to be the order I think? The git log order is different from the 'git log --graph' order.14:16
zalt left14:16
Nickeeh eh.. no that's still a removal14:16
'git log --all --graph --full-history -p -G mRotationPointFunc'14:17
that's the actual executed command.. no weird things in there right?14:17
NeoCron joined14:18
Xiti left14:18
tiin57 left14:19
shush left14:19
ikke Doesn't look like it14:19
dedowsdi left14:20
netz_ joined14:20
netz left14:21
netz_netz14:21
lucasb joined14:21
dedowsdi joined14:22
tiin57 joined14:22
Xiti joined14:24
geowiesnot left14:24
gpanders left14:25
realloc hi, in our repository we have some files which look like textfiles but which actually can not be merged manually in case of conflict because they are too complex. There is a special merging tool for them. Hence, I configured a [merge "toolname"] entry in my .gitconfig for them and set merge=toolname in the gitattributes file for the affected filetype. This works well with "git merge", however, "git14:26
rebase" seems to ignore the merge=... setting of the gitattributes file. Do you know how I can fix this? Thank you very much14:26
oxymoron93 left14:26
Xiti left14:26
gpanders joined14:28
z3t0 joined14:31
z3t0 hi all, I am learning about git rebase and trying to clean up a branch by rewriting the history but having some weird issue with commits disappearing14:31
I am doing an interactive rebase say I have commit A B C D.14:32
Xiti joined14:32
muhaha left14:33
z3t0 What I am trying to do is re order it to A (squash B) C D.14:33
For some reason commit C gets deleted and doesn't show up in the rebase. Now C has files related to D. So then D complains that a file was deleted by us... I'm new to rebase so am really confused whats happening14:33
I would appreciate any help, and can provide more info!14:33
gordonfish joined14:34
z3t0 Hmm, the problem seems to have disappeared. Odd14:36
thiago_ joined14:37
netz left14:38
netz joined14:40
netz left14:40
netz joined14:41
netz left14:43
Xiti left14:44
is_null left14:45
netz joined14:46
SpeakerToMeat left14:48
Lucas_Gray joined14:48
tiin57 left14:49
SpeakerToMeat joined14:50
dedowsdi left14:52
tiin57 joined14:53
dedowsdi joined14:53
netz left14:54
geowiesnot joined14:54
dfee joined14:55
Nickeeh ikke: ah, -m14:56
fitzgerald1337 joined14:57
gpanders left14:58
netz joined14:59
gpanders joined14:59
tanuki left15:00
dedowsdi left15:01
dionysus69 left15:01
tanuki joined15:01
Xiti joined15:03
dedowsdi joined15:05
fattredd joined15:05
dedowsdi left15:09
g4570n joined15:12
R2robot joined15:12
fflam left15:18
ChrisLane left15:18
tiin57 left15:19
fflam joined15:20
ChrisLane joined15:20
tiin57 joined15:23
jor joined15:24
gpanders left15:24
durham joined15:26
durham left15:31
faceface joined15:32
faceface hi15:32
I'm in a pickle...15:32
I did git init / git remote add backup gitrepo/config.git/ / git fetch backup15:32
I saw * [new branch] master -> backup/master15:32
but git branch shows me nothing15:32
git branch -a shows me remotes/backup/master (in red)15:33
I thought init would create master...15:33
davve hey, im in a pear. I thought I had made a commit but it was failed due to a pre-commit hook without noticing, then i made some more work and --amended it, but it got amended to somoene elses commit. how do i get back to before doing that and restoring my work? :o15:33
faceface What I want to do is compare a version of a file in that remote to the version currently in my cwd15:33
davve: ensuring you have a backup first... git reset15:34
davve: ensuring you have a backup first... git reset commit-before15:34
Ownix joined15:35
davve thanks, making a backup to try :+1+15:35
nikivi left15:35
nikivi joined15:35
Ownix I am migrating to a new remote git repo, will it hurt anything if I just change the URL for origin and push?15:36
davve ambiguous argument 'commit-before'15:37
Muimi__ joined15:37
gpanders joined15:38
Bombe faceface, without a commit you don’t have a branch, that’s why there’s no master after git-init.15:38
faceface, git-status should tell you you’re on master.15:39
Trieste left15:44
Trieste joined15:46
tiin57 left15:49
tonyj joined15:50
deathwishdave joined15:50
tiin57 joined15:53
davve i worked it out15:54
z3t0 left15:54
aliss left15:55
bolovanos joined15:55
Brainium joined15:58
bolovanos_ joined16:02
bolovanos left16:06
Guest20 joined16:06
Lucas_Gray left16:08
onizu joined16:09
deathwishdave left16:11
shush joined16:15
tiin57 left16:19
netcrash left16:22
tiin57 joined16:23
justanotheruser left16:24
vicfred_ left16:26
vicfred joined16:27
aliss joined16:28
deathwishdave joined16:33
shush left16:34
shush joined16:35
rfuentess left16:38
justanotheruser joined16:39
thomasross_ joined16:43
thomasross left16:43
thomasross_thomasross16:43
zen_coder joined16:48
zen_coder how can I get the print the current branch name?16:49
-the16:49
tiin57 left16:49
ikke git symbolic-ref HEAD16:49
zen_coder in front of it, I get a `refs/heads/`16:49
what is this? how can I remove it?16:50
ChrisLane left16:50
ikke git git rev-parse --abbrev-ref HEAD16:50
zen_coder: that's the full branch name16:50
zen_coder will this solution works in all cases?16:51
ChrisLane joined16:51
ikke yes, unless HEAD is detached16:51
zen_coder is there a solution, when head is detached?16:52
ikke no16:52
because there is no branch checked out then16:52
tiin57 joined16:53
gxt left16:54
opal left16:54
rewrited joined16:55
orbyt_v7 joined16:56
gxt joined16:56
opal joined16:56
clara97 joined17:08
perrier-jouet joined17:09
T_UNIX left17:13
deathwishdave left17:14
tiin57 left17:19
fission6 left17:19
clime joined17:19
Metalsutton joined17:20
fission6 joined17:22
tiin57 joined17:23
causasui joined17:24
kashike left17:24
rsrx left17:28
CCR5-D32 left17:37
theorangeone left17:39
Muimi__ left17:39
theorangeone joined17:40
bolovanos_ left17:46
bubble01_ joined17:48
bubble01_bubble0217:48
tiin57 left17:49
chele left17:50
tiin57 joined17:52
tangerinelaborat joined17:53
iffraff joined17:57
bilb_ono joined17:59
ChrisLane left18:04
ChrisLane joined18:06
bitnoize left18:08
mehwork joined18:09
troulouliou_div2 joined18:14
ttoocs left18:14
mehwork when i do 'git co origin foo' does that mean it tries to fetch and checkout from the remote server?18:15
reason i ask is when i create a ticket from Stash/bitbucket's website, i can't 'git co origin foo'. Instead i have to 'git fetch && git co foo'18:16
not sure what the distinction is18:16
cdown_ joined18:18
iffraff left18:19
tiin57 left18:19
g4570n left18:19
cdown left18:21
cdown_cdown18:21
tiin57 joined18:22
bitnoize joined18:26
sauvin left18:29
g00s joined18:29
foul_owl_ left18:31
Guest20 left18:32
justanotheruser left18:35
maryo_s left18:37
omar_trisquel joined18:39
justanotheruser joined18:42
Lucas_Gray joined18:43
foul_owl_ joined18:45
wootehfoot left18:46
cliluw joined18:47
tiin57 left18:49
tiin57 joined18:53
Xiti` joined18:54
maryo_s joined18:56
Xiti left18:57
orbyt_v7 left19:05
dob1 what is a similar client to git extension on linux?19:07
Aattas left19:10
davispuh joined19:13
tiin57 left19:19
rafasc mehwork: to fully understand, you need to be aware of the concept of remote tracking branches: !rtp19:22
!rtb19:23
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>'19:23
tiin57 joined19:23
mehwork thanks19:23
rafasc mehwork: that is, origin/master isn't the 'branch master from the remote, it is a copy of the branch master from the remote at the time you last contacted the server (either directly via fetch, or indirectly via pull which does a fetch internally)19:24
The second part is that checkout has some builtin magic that tries to guess what you mean.19:24
muhaha joined19:25
xcm left19:25
rafasc mehwork: for example. if you try: git checkout mybranch; and mybranch doesn't exist, but origin/mybranch does.. git creates a local branch 'mybranch', makes it track 'origin/mybranch', and checks it out.19:25
wootehfoot joined19:26
xcm joined19:26
rafasc but checkout itself never talks to the sever. It uses the local "mirrors".19:26
It can be confusing because a "remote tracking branch" is a *local* branch.19:27
rewrited left19:27
rafasc [local]master (tracks)-> [local]origin/master (mirrors)-> [server]master19:29
Trieste left19:29
Trieste joined19:32
mehwork ok19:33
BPL joined19:35
wgrant left19:35
benyoo joined19:37
cdown_ joined19:40
orbyt_v7 joined19:41
cdown left19:42
cdown_cdown19:42
Lucas_Gray left19:44
xcm left19:44
xcm joined19:45
NewToThisV21 joined19:46
NewToThisV21 I accidentally deleted a file in file changes section on my pull request in GitHub. Is there a way I can undo this file deletion?19:46
mr_shaman left19:47
tiin57 left19:49
rafasc NewToThisV21: you need to add it again.19:49
Something like git checkout origin/master -- filename;19:50
NewToThisV21 I was trying to pull from the remote branch which is where the file was deleted, but it gave me "tip is ahead of branch" message, so since I knew the file still existed on my local branch I just did a git push origin head --force, hopefully I didn't destroy anything19:50
git still perplexes me at times19:51
chele joined19:52
tiin57 joined19:52
linuxdogXdog left19:53
zen_coder left19:53
chele left19:54
omar_trisquel left19:55
rafasc push head --force did destroy something.19:55
it destroyed whatever was making the remote ahead of you.19:55
NewToThisV21 I am pretty sure it was just the file I deleted on the remote which I needed back, I guess time will tell, lol19:56
rafasc NewToThisV21: In other words, the remote had a commit you didn't have. And with that force push you said: forget about that, I have the real history, just take it. I don't care what happens to others.19:56
NewToThisV21 Okay nice, nice, that is what I wanted19:57
My local was correct19:57
rafasc Is someone else using this repo as well?19:57
NewToThisV21 No, it's my own feature branch I was working on19:57
rafasc you'll need to warn them. Because they might still have the old history.19:58
than good19:58
NewToThisV21 I hastily do stuff in git and I really need to stop and think before running commands19:58
clara97 left20:08
ShapeShifter499 left20:08
ShapeShifter499 joined20:09
systemparadox joined20:09
troulouliou_div2 left20:11
geowiesnot left20:11
systemparadox Hi. Can anyone point me in the direction for some tips about how to set git up for use with github? I'm a pro mercurial user, but I'm having trouble figuring out how I'm supposed to set up remotes/branches20:11
One of my main issues is what to call everything. Currently I've added a remote for my fork on github as "origin", and a remote for the official repo as "upstream"20:13
So branch master is pointing as origin/master and that all works ok20:14
ikke sounds good so far20:14
lmurar1 left20:15
systemparadox ok that's good, although I must say it's a bit frustrating that no tutorial mentions this anywhere, even github specific ones only deal with your own fork20:15
it's literally taken me months to figure out that I should call the other one "upstream"20:16
If I checkout upstream/master it goes into detached head mode20:17
ikke Yes, these are so called remote tracking branches20:17
maryo_s left20:17
ikke their only purpose is to keep track of what you fetched from the remote20:17
systemparadox right I'm mostly understanding this, but I now have collaboration access to the primary repository20:17
so I feel like I need to add a local branch that tracks upstream/master?20:18
tiin57 left20:19
systemparadox so that it won't go into detached head mode and I can work on it directly?20:19
I tried adding an "upstream" branch, but I got into a right mess because of the naming conflict with the "upstream" remote20:20
Xiti` left20:20
ikke I think it makes sense for your local master to track upstream master20:20
in most cases, your forks master does not really mastter20:20
nikivi left20:20
systemparadox ah that might help20:20
zalt_ left20:21
systemparadox am I right in thinking then that I can't have a branch with the same name as a remote?20:21
HumanGeek joined20:21
ikke practically no20:21
like you said, it's confusing20:22
zalt_ joined20:22
tiin57 joined20:23
systemparadox It would be useful to see what others are doing whenever they have more than just "origin". Are there any conventions for this described anywhere?20:23
nikivi joined20:24
mowcat joined20:25
nikivi left20:25
Human_G33k left20:25
smitop joined20:26
ikke Not aware of any articles or so20:27
nikivi joined20:28
Xiti joined20:29
nikivi left20:29
systemparadox is it possible to work in detached head mode? If I checkout upstream/master and then change a file, git status says "nothing to commit, working tree clean". I don't understand that. I know I'm in detached head mode, but I have changed something, so why does git say it's clean?20:30
duderonomy left20:30
ikke if you actually changed something, git should show it20:31
xcm left20:31
ikke Commits created in a detached HEAD will not belong to any branch20:31
Trieste left20:31
xcm joined20:31
ikke So, in practice, you should always be on a branch if you plan to commit20:32
nikivi joined20:32
ikke (git does not work with anonymous heads like mercurial does)20:32
Trieste joined20:33
ikke in git, it's quite common to work with feature branches20:33
systemparadox Am I right in thinking that branches are just bookmarks that point to a specific revision, and normally if you are "on" a branch and add a new commit, it automatically advances the branch pointer to the revision you just added?20:34
ikke yes, exactly20:34
systemparadox ok, so if I checkout a specific revision and go into detached head mode and then change something and commit, it should work and add the commit with a parent of the revision I checked out, but just won't update the branch pointer?20:36
ikke Yes, that precisely how it works20:36
systemparadox ok now I just need to figure out why it says "nothing to commit, working tree clean" even after changing some files20:37
Sasazuka joined20:40
doug16k systemparadox, .gitignore?20:44
CCR5-D32 joined20:46
deathwishdave joined20:47
tiin57 left20:49
vicfred left20:50
tiin57 joined20:52
systemparadox aha that's hilarious, I used "npm version" and didn't realise it does a git commit automatically!20:53
vicfred joined20:55
systemparadox ok so next question is why "git log" doesn't show this? Do I have to do something to get a full log?20:56
Enphuego joined20:56
benyoo left20:56
vicfred left20:56
jstein joined20:56
vicfred joined20:56
vicfred left20:57
vicfred joined20:58
systemparadox ok it's shown in "git log --all". Does this mean that "git log" only shows ancestors of HEAD by default?20:58
onizu left21:00
geowiesnot joined21:00
systemparadox ah found it in the docs, that appears to be a yes21:01
nly joined21:02
systemparadox ikke, thanks very much for your help, I feel like I have a much clearer understanding now21:02
mns_mns21:03
HourGate left21:04
duderonomy joined21:04
deathwishdave left21:05
HourGate joined21:05
Elodin left21:06
m0viefreak joined21:07
Ploppz left21:07
HourGate left21:12
HourGate joined21:13
ikke systemparadox: np21:14
BPL left21:16
tiin57 left21:19
muhaha left21:22
tiin57 joined21:23
g4570n joined21:23
Maxattax left21:26
tangerinelaborat left21:26
aliss left21:29
flex14 joined21:29
aliss joined21:29
flex14 left21:33
Trieste left21:35
Trieste joined21:36
Brainium left21:40
Shentino left21:41
shentino joined21:43
chiastre left21:46
tiin57 left21:49
chiastre joined21:49
Metalsutton left21:49
quetz left21:50
tiin57 joined21:53
CodeSlingerPaul left21:53
jaziz joined21:59
wildlander joined22:01
nly left22:02
wgrant joined22:04
bubble02 left22:05
Phylock left22:11
jstein left22:12
ethernether joined22:15
Zialus left22:17
split_horizon left22:18
tiin57 left22:19
tiin57 joined22:22
wootehfoot left22:28
systemparadox left22:32
sphalerite left22:34
calcul0n left22:38
fission6 left22:38
sphalerite joined22:43
thiago_thiago22:45
SmashingX joined22:48
SmashingX left22:48
voidSurfr joined22:48
voidSurfr left22:49
tiin57 left22:49
orbyt_v7 left22:50
aliss left22:50
duderonomy left22:51
tiin57 joined22:52
NeoCron left23:01
CCR5-D32 left23:01
bakadesusenpai left23:03
tonyj is there anyway (git log -S etc) to find what commit deleted a blank line23:04
nedbat tonyj: an interesting challenge23:06
troulouliou_dev joined23:09
duderonomy joined23:09
perrier-jouet left23:14
jwest left23:14
jwest joined23:14
perrier-jouet joined23:14
bakadesusenpai joined23:15
ethernether left23:15
smitop left23:15
justanotheruser left23:16
xcmGuest9796523:17
Guest97965 left23:17
xcm joined23:17
duderonomy left23:18
tiin57 left23:19
tiin57 joined23:22
oojacoboo left23:23
Marmotte tonyj: you search for a precise blank line, or any blank line in a file ?23:27
tonyj former23:27
Marmotte if you have line numbers, you can try git log -L first,last:file23:27
with current line numbers, git will follow the "block" if it moves23:28
tonyj Marmotte: thanks I'll give it a try23:28
I basically have a patch that fails to apply as the patched file has two blank lines and the context in the patch only expects 1. Somewhere between the two commits (later is cherry picked) the line was removed23:29
justanotheruser joined23:32
flex14 joined23:35
Marmotte tonyj: it seems that the best answer is git llog --pickaxe-regex -S '^$'23:36
(oops, llog is an alias to log in my own config :D)23:36
duderonomy joined23:40
flex14 left23:41
flex14 joined23:42
irrgit left23:45
tiin57 left23:49
mowcat left23:50
thansen left23:51
tiin57 joined23:53
thansen joined23:58

Logs Search ←Prev date Next date→ Channels Documentation