| 2020-08-19 |
|
nvmd
| nedbat: nice | 00:00 |
| ← tarkus left | 00:00 |
| → saveNexit joined | 00:00 |
| ← vdamewood left | 00:01 |
|
nvmd
| perfect, actually. | 00:02 |
| ← sphalerite left | 00:04 |
| ← tiin57 left | 00:05 |
| → sphalerite joined | 00:08 |
| → tiin57 joined | 00:08 |
| ← tgunr left | 00:08 |
| ← fannagoganna left | 00:10 |
| ← monr0e left | 00:13 |
| → monr0e joined | 00:14 |
| ← arcatech left | 00:15 |
| ← orbyt_v7 left | 00:15 |
| ← berndj left | 00:16 |
| → berndj joined | 00:16 |
| ← ilmostro left | 00:19 |
| → shush joined | 00:20 |
| ← cdown left | 00:21 |
| ← saveNexit left | 00:21 |
| → saveNexit joined | 00:22 |
| ← rafasc left | 00:22 |
| → cdown joined | 00:22 |
| → ilmostro joined | 00:23 |
| ← nvmd left | 00:24 |
| ← mowcat left | 00:24 |
| ← saveNexit left | 00:27 |
| → arcatech joined | 00:32 |
| splud → chrnod | 00:32 |
| ← tiin57 left | 00:35 |
| → deltab joined | 00:35 |
| chrnod → splud | 00:35 |
| → saveNexit joined | 00:35 |
| ← saveNexit left | 00:36 |
| ← arcatech left | 00:36 |
| → tiin57 joined | 00:38 |
| ← qpdb left | 00:38 |
| → qpdb joined | 00:38 |
| → cdown_ joined | 00:39 |
| ← cdown left | 00:42 |
| cdown_ → cdown | 00:42 |
| → Wetmelon joined | 00:45 |
| → royal_screwup21 joined | 00:47 |
| → yitz joined | 00:48 |
| ← antranigv left | 00:51 |
| ← monr0e left | 00:53 |
| ← royal_screwup21 left | 00:57 |
| ← chiastre left | 00:57 |
| → royal_screwup21 joined | 00:57 |
| ← alexeightsix left | 00:58 |
| → chiastre joined | 00:58 |
| ← royal_screwup21 left | 01:03 |
| ← cdown left | 01:04 |
| → arcatech joined | 01:04 |
| ← tiin57 left | 01:05 |
| → cdown joined | 01:05 |
| ← arcatech left | 01:08 |
| ← mirrorbird left | 01:08 |
| → tiin57 joined | 01:08 |
| ← causasui left | 01:08 |
| → rumbler31_ joined | 01:17 |
| → mirrorbird joined | 01:17 |
| ← nivag left | 01:23 |
| ← AtumT left | 01:27 |
| → CAPTCHA_REQUIRED joined | 01:28 |
|
CAPTCHA_REQUIRED
| How do I update the checkout id of a submodule? | 01:28 |
|
| I used git submodule add <repo> | 01:29 |
|
| cd repo | 01:29 |
|
| git checkout adkjaofjagaga | 01:29 |
|
| git .gitmodules still does not say the version | 01:29 |
|
| I don't want to checkout master next time somebody clones this repo | 01:29 |
| ← relipse left | 01:37 |
| ← sudoforge left | 01:41 |
| → arcatech joined | 01:42 |
| → libertyprime joined | 01:43 |
| ← stats4647 left | 01:43 |
| ← mirrorbird left | 01:50 |
| ← libertyprime left | 01:56 |
| → libertyprime joined | 01:58 |
| → Goplat joined | 01:58 |
| → ilogger2 joined | 02:19 |
| → kgz joined | 02:22 |
| → chachasmooth joined | 02:24 |
| → Cabanossi joined | 02:33 |
| → alexeightsix joined | 02:35 |
| → jtmusky joined | 02:37 |
| → tiin57 joined | 02:38 |
| → vdamewood joined | 02:39 |
| ← chachasmooth left | 02:41 |
| → chachasmooth joined | 02:43 |
| → Guest20 joined | 02:48 |
| → lagothrix joined | 02:56 |
| → chiastre joined | 02:58 |
| → shush joined | 03:00 |
| ← tiin57 left | 03:05 |
| ← shush left | 03:05 |
| → mirrorbird joined | 03:10 |
| → tiin57 joined | 03:13 |
|
g00s
| i keep getting myself in trouble with git stash -u (to stash untracked stuff). i switch branches do stuff, come back, try git stash apply and almost always get "error: could not restore untracked files from stash". what am i doing wrong ? | 03:14 |
| → libertyprime joined | 03:19 |
| → kupi joined | 03:20 |
|
orbyt_
| g00s https://stackoverflow.com/a/20589663/3917064 | 03:32 |
|
g00s
| thanks orbyt_ | 03:33 |
| ← tiin57 left | 03:35 |
| → Muimi joined | 03:35 |
| → shush joined | 03:37 |
| → tiin57 joined | 03:38 |
| ← vdamewood left | 03:38 |
| ← shush left | 03:42 |
| → shush joined | 03:45 |
| ← shush left | 03:49 |
| → kjartan joined | 03:52 |
| → hussam joined | 03:53 |
| ← alexeightsix left | 03:56 |
| → sydbarret joined | 04:02 |
|
sydbarret
| how do i push a branch to heroku without merging into master. I wanna test that branch in heroku first | 04:02 |
|
Lady_Aleena
| Hello. I think I have a problem with my last commit message. Usually when I commit, only the first line of the commit message is shown after the commit. This last one, all five lines were shown. | 04:02 |
|
| I haven't pushed yet, but it looks like a line break was lost somewhere in between me writing the commit message and saving it. | 04:03 |
|
LordRyan
| sydbarret: you may have to either change your Heroku app to use that branch instead, or set up a new Heroku instance with the branch you'd like to use for testing. | 04:04 |
| ← tiin57 left | 04:05 |
|
sydbarret
| LordRyan cant i just do git push heroku mybranch:master | 04:05 |
|
| or what does that? | 04:05 |
|
Lady_Aleena
| My Google-fu was string tonight. Disregard my last question. | 04:05 |
| → blurkis joined | 04:05 |
|
LordRyan
| sydbarret: you can probably do that but keep in mind that if you change history, re-pushing might cause issues. | 04:06 |
| ← libertyprime left | 04:06 |
|
sydbarret
| LordRyan i wanna show you a code in the flask channel and perhaps you can tell me how to test | 04:07 |
| → libertyprime joined | 04:08 |
| → tiin57 joined | 04:08 |
| ← Guest20 left | 04:16 |
|
meowray
| How can I red the combined effect of 3 commits (they are not consecutive) | 04:17 |
|
LordRyan
| `git show commit1 commit2 commit3` | 04:18 |
| → shush joined | 04:19 |
| ← mirrorbird left | 04:20 |
| → mirrorbird joined | 04:22 |
| → ephemer0l joined | 04:22 |
| ← shush left | 04:23 |
| → tryte_ joined | 04:24 |
| → vdamewood joined | 04:25 |
| → justanotheruser joined | 04:25 |
| → Technodrome joined | 04:34 |
| ← tiin57 left | 04:35 |
| → tiin57 joined | 04:40 |
| → CoolerX joined | 04:40 |
|
CoolerX
| how exactly do forks work? | 04:40 |
|
| does github automatically sync forks with the original? | 04:40 |
|
PikaChokeMe
| don't think so | 04:40 |
|
| A fork is just a clone of a repo basically | 04:40 |
|
CoolerX
| hmm | 04:41 |
|
| so how do I do that/ | 04:41 |
|
PikaChokeMe
| They're not much different than a branch in the grand scheme of things... except you have to set up refs a little different to transfer stuff between them | 04:41 |
|
CoolerX
| when you have a large project the usual workflow is to create your own fork, make a bunch of commits and then submit a pull request to merge into the original repo on some branch | 04:42 |
|
LordRyan
| it depends on what you're using for the backend software | 04:42 |
|
CoolerX
| the fork is on github btw, not locally | 04:42 |
|
| is there a concept of local forks? | 04:43 |
|
LordRyan
| not really | 04:43 |
|
| GitHub does a neat thing with forks where they're all stored in the same "area". | 04:43 |
|
CoolerX
| ? | 04:43 |
|
| does that mean they are synced automatically? | 04:44 |
|
LordRyan
| Not exactly. Your "version" of the fork still has your changes, and the "original" repository won't get those changes until they're merged. | 04:44 |
|
CoolerX
| https://www.earthdatascience.org/courses/intro-to-earth-data-science/git-github/github-collaboration/update-github-repositories-with-changes-by-others/ | 04:44 |
|
| I mean changes in the original repo | 04:45 |
|
| being propagated to the fork | 04:45 |
|
| there are other people working on this project as well | 04:45 |
|
LordRyan
| No. Once you fork, you don't get changes automatically. | 04:45 |
|
CoolerX
| so what do you do? | 04:45 |
|
LordRyan
| I actually do not know the best way to do it. | 04:46 |
| → Phylock joined | 04:48 |
| → Guest20 joined | 04:48 |
|
CoolerX
| https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/syncing-a-fork | 04:55 |
|
| ok now it makes sense why git has requires you to specify "origin" | 04:57 |
|
| how do you merge changes of all branches? | 05:00 |
| → puff` joined | 05:00 |
|
CoolerX
| that articles tells you to "Merge the changes from upstream/master into your local master branch. This brings your fork's master branch into sync with the upstream repository, without losing your local changes." | 05:00 |
|
| but what about the other branches | 05:01 |
|
| do I have to switch to each branch manually and merge each of them? | 05:01 |
| → igemnace joined | 05:03 |
| ← tiin57 left | 05:04 |
|
LordRyan
| yea | 05:05 |
| → tiin57 joined | 05:08 |
| → makara1 joined | 05:22 |
| ← libertyprime left | 05:32 |
| → libertyprime joined | 05:33 |
| ← tiin57 left | 05:34 |
| ← sydbarret left | 05:37 |
| → bocaneri joined | 05:37 |
| → tiin57 joined | 05:38 |
| ← kupi left | 05:40 |
| ← libertyprime left | 05:41 |
| → libertyprime joined | 05:43 |
| → zulutango joined | 05:44 |
| → fstd_ joined | 05:54 |
| fstd_ → fstd | 05:58 |
| ← tiin57 left | 06:04 |
| → LetoThe2nd joined | 06:05 |
| → shush joined | 06:05 |
| → mightyjens joined | 06:07 |
| → tiin57 joined | 06:08 |
| → nsh joined | 06:11 |
| → vicfred joined | 06:13 |
| ← shush left | 06:14 |
| ← libertyprime left | 06:17 |
| → libertyprime joined | 06:19 |
| → nivag joined | 06:19 |
| → nivag__ joined | 06:19 |
| → nivag_ joined | 06:19 |
| ← libertyprime left | 06:21 |
| → KnoP joined | 06:24 |
| → mika joined | 06:25 |
| → bruce_lee joined | 06:27 |
| ← Technodrome left | 06:27 |
| → shicks2525 joined | 06:29 |
| ← tiin57 left | 06:34 |
| → mobidrop joined | 06:35 |
| → feriman joined | 06:37 |
| → tiin57 joined | 06:39 |
| ← mightyjens left | 06:42 |
| ← vicfred left | 06:45 |
| ← CoolerX left | 06:47 |
| → T_UNIX joined | 06:49 |
| → snowkidimd joined | 06:51 |
| → rfuentess joined | 06:55 |
| ← Guest20 left | 06:57 |
| ← tiin57 left | 07:04 |
| → tiin57 joined | 07:07 |
| ← mirrorbird left | 07:08 |
| → Guest20 joined | 07:08 |
| → bookworm joined | 07:10 |
| → jim joined | 07:12 |
| → mirrorbird joined | 07:14 |
| → calcul0n joined | 07:16 |
| → oxymoron93 joined | 07:16 |
| → rfuentess__ joined | 07:19 |
| ← mirrorbird left | 07:20 |
| → mirrorbird joined | 07:20 |
| ← rfuentess left | 07:21 |
| ← mobidrop left | 07:22 |
| → konrados joined | 07:23 |
| → mobidrop joined | 07:33 |
| ← tiin57 left | 07:35 |
| → chele joined | 07:36 |
| → peeps[zen] joined | 07:38 |
| → tiin57 joined | 07:38 |
| → nabil_ joined | 07:48 |
| ← mobidrop left | 07:54 |
| ← nabil_ left | 07:55 |
| ← mirrorbird left | 07:56 |
| → nabil joined | 07:56 |
| → muhaha joined | 07:56 |
| ← nivag__ left | 07:58 |
| ← nivag_ left | 07:58 |
| → nabil_ joined | 07:59 |
| → nabil__ joined | 08:01 |
| → mirrorbird joined | 08:02 |
| → ghostshadow001 joined | 08:02 |
| ← nabil left | 08:02 |
| → mobidrop joined | 08:04 |
| ← nabil_ left | 08:04 |
| ← tiin57 left | 08:04 |
| → nabil_ joined | 08:07 |
| → tiin57 joined | 08:08 |
| ← nabil__ left | 08:10 |
| → BlastuR joined | 08:11 |
|
Tuor
| Hi, I did commit1, commit2 and commit3. I did forgett to checkout commit1 making my commit3. I want to rebase commit3 onto commit1 (I don't want to include commit2 in commit3). How can I do that? | 08:11 |
|
ikke
| Do you want commit 3 in a new branch? And what should happen to commit2? | 08:12 |
|
BlastuR
| hey! im trying to git bisect something, I know one bad and the good commit, but in order to test each commit i need to cherry pick another commit (a feature branch). is it possible to make git bisect rebase my feature branch as a part of the bisect? | 08:13 |
|
Tuor
| ah branches... origin/mail -> commit1; date -> commit2; mail -> commit3 | 08:13 |
| ← blurkis left | 08:14 |
|
ikke
| git rebase --onto original/mail date mail | 08:14 |
| → blurkis joined | 08:15 |
|
j416
| BlastuR: yes, just make sure to give bisect the right commit when you say good/bad | 08:15 |
| → Wizek joined | 08:15 |
| → theoceaniscool joined | 08:17 |
| → venmx joined | 08:20 |
|
Tuor
| thx jkke! | 08:23 |
| → Dara joined | 08:23 |
| → jelmer joined | 08:25 |
| → unluckyshrubbery joined | 08:26 |
| → yitz joined | 08:26 |
|
BlastuR
| j416: how do i do that? i already have 2 branches, lets call them A and B. A is good+feature-branch and B is bad+feature branch. I then tried "git bisect start" "git bisect bad B" and "git bisect good A". Git then stated "Bisecting: a merge base must be tested",.. and then checked out a new commit for me to test. But this commit does not contain my feature branch? | 08:26 |
|
| sorry, A is good+cherry-picked "feature branch" commit and B is bad + cherry-picked "feature-branch" commit | 08:27 |
|
j416
| BlastuR: so cherry-pick what you need and test it | 08:27 |
| ← yitz left | 08:30 |
| → yitz joined | 08:31 |
| ← tiin57 left | 08:35 |
| → tiin57 joined | 08:35 |
| → esotericnonsense joined | 08:42 |
| → lkthomas_work joined | 08:44 |
|
lkthomas_work
| I got Branch A and B, while I am working on Branch A, the B side need to make changes and push to Merge Request, but somehwo MR also include Branch A change, how could I avoid that | 08:45 |
|
ikke
| lkthomas_work: by not basing branch B on branch A | 08:46 |
|
| You cannot base branch B on branch B and then only merge the commits unique to B | 08:47 |
|
| on branch A* | 08:47 |
|
lkthomas_work
| OH shit | 08:47 |
|
| that could be the case | 08:47 |
|
| you mean, I did git branch A, then git checkout -b B ? | 08:48 |
|
| that will based on Branch A instead of master | 08:48 |
|
ikke
| git checkout A; git checkout -b B | 08:48 |
|
| for eample | 08:48 |
|
| or rather | 08:48 |
|
lkthomas_work
| shi... | 08:48 |
|
| well that's unintented | 08:48 |
|
ikke
| git checkout A; git commit; git checkout -b B | 08:48 |
|
| that comit is then included in B as well | 08:49 |
|
| git rebase --onto master A B | 08:49 |
| ← konrados left | 08:50 |
| → konrados joined | 08:50 |
|
lkthomas_work
| why there are three branches | 08:51 |
|
| so A and B will move the upstream branch to master ? | 08:51 |
|
ikke
| A is used as a reference to determine which commits should be rebased | 08:51 |
|
| You only want to rebase commits unique to B, so you want the equivalent of git log A..B | 08:52 |
|
lkthomas_work
| right, well, it's going a bit too far, does git have settings to indicate what branch is it based on when I do git commit ? | 08:53 |
|
ikke
| lkthomas_work: there are shell prompts that show you the current branch | 08:53 |
|
| but I'm not sure if that would've helped | 08:54 |
|
| At least, not at commit time | 08:54 |
|
lkthomas_work
| actually, other way around | 08:54 |
|
| would it be possible to force branch from master only ? | 08:54 |
|
| I never need to commit across multiple branches | 08:54 |
|
ikke
| git checkout -b B master | 08:54 |
|
| for example | 08:54 |
|
| that would create branch B based on master | 08:54 |
|
lkthomas_work
| ikke, yeah, IF I could remember it everytime | 08:55 |
|
| that's a big IF | 08:55 |
| → voker57 joined | 08:56 |
|
ikke
| There is nothing in git to prevent you from creating a branch based on another branch but master | 08:56 |
|
lkthomas_work
| yes, but I want to lock myself down instead | 08:57 |
|
oxymoron93
| this is the state of mind to have about git ^ | 08:57 |
| → Job joined | 08:57 |
|
Job
| hello the command git push origin master is not responding ... | 08:57 |
|
| im using fedora 31 | 08:58 |
|
ikke
| lkthomas_work: 1) it helps to have a good workflow. Write it down if it helps | 08:58 |
|
lkthomas_work
| ikke, hehe, human make mistake | 08:58 |
|
ikke
| lkthomas_work: 2) Use tools like git log --graph --oneline (or other tools) to see how your history looks like | 08:58 |
|
| ^ | 08:58 |
|
| Before you push, inspect your work | 08:59 |
| → nabil joined | 08:59 |
|
ikke
| There are nice tools to visualize how your history looks like | 08:59 |
| → gpanders joined | 09:00 |
|
Job
| false alarm boys | 09:01 |
|
| see you around | 09:01 |
|
lkthomas_work
| ikke, true, I understand | 09:01 |
| ← Job left | 09:01 |
| ← nabil_ left | 09:01 |
|
ikke
| I make mistakes as well, mind you :) | 09:04 |
|
lkthomas_work
| ikke, hehe, everyone does | 09:04 |
| ← tiin57 left | 09:05 |
|
j416
| not Linus | 09:06 |
|
lkthomas_work
| j416, well he just read peoples work | 09:07 |
|
j416
| https://youtu.be/4XpnKHJAok8?t=1335 | 09:07 |
|
lkthomas_work
| if I read your work, I could yell at you as well | 09:07 |
| → tiin57 joined | 09:07 |
| → enoq joined | 09:08 |
| → jaziz joined | 09:12 |
| → Dunga joined | 09:13 |
|
Dunga
| Anyway I can run --assume-unchanged on all files and sub folders within a folder. | 09:15 |
|
j416
| good for you | 09:16 |
| → planetcall|work joined | 09:17 |
|
Jookia
| protip: yelling doesn't work well for project review | 09:19 |
| → dionysus69 joined | 09:21 |
| → heth joined | 09:24 |
| ← tiin57 left | 09:35 |
| ← muhaha left | 09:36 |
| → cdown_ joined | 09:37 |
| → tiin57 joined | 09:38 |
| cdown_ → cdown | 09:40 |
| → masber joined | 09:40 |
| → Lucas_Gray joined | 09:42 |
|
masber
| hi, why pull does not download all the branches? and how can I pull a remote branch? | 09:43 |
| → g00s joined | 09:43 |
| → monr0e joined | 09:45 |
| → nabil_ joined | 09:46 |
| ← nabil left | 09:49 |
| → Muzer joined | 09:50 |
| ← Lucas_Gray left | 09:58 |
|
j416
| masber: it does | 09:59 |
|
| masber: git branch -r | 09:59 |
|
| masber: go to !book and read about remote tracking branches | 10:00 |
|
gitinfo
| masber: 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 !parable | 10:00 |
|
masber
| ok, but it shows in red and with remote/origin prefix | 10:00 |
|
| so they are not the same | 10:00 |
|
j416
| indeed | 10:01 |
| → sozuba joined | 10:01 |
|
masber
| somehow I need to add --track to checkout to be able to use them, otherwise git says I am in a detached head | 10:01 |
| → Lucas_Gray joined | 10:01 |
|
j416
| masber: did you check the link? | 10:01 |
|
| specifically, this might be of use https://git-scm.com/book/en/v2/Git-Branching-Remote-Branches | 10:01 |
|
masber
| ok, I will check | 10:02 |
| ← tiin57 left | 10:05 |
| → tiin57 joined | 10:08 |
| → shush joined | 10:11 |
| ← enoq left | 10:12 |
| ← g00s left | 10:15 |
| ← shush left | 10:16 |
| → enoq joined | 10:17 |
| ← vdamewood left | 10:17 |
| → FH_thecat joined | 10:17 |
| → g00s joined | 10:21 |
| ← masber left | 10:21 |
| ← Muzer left | 10:22 |
| → Brainium joined | 10:24 |
| → sunri5e_ joined | 10:25 |
| → mobidrop_ joined | 10:29 |
| ← sunri5e_ left | 10:30 |
| → TheNik joined | 10:31 |
| ← mobidrop left | 10:32 |
| ← tiin57 left | 10:34 |
|
TheNik
| Hi there. I am planning to set up a personal website for things that may benefit from some web server based scripts. Decided I'd pair this with learning to use git, to manage said website. Am I correct in assuming that I should install a git client on my machine, install a git server on the server and create a repo on both of them? The server side repo should /not/ be the live folder? How would I correctly push from the | 10:36 |
|
| repo to live? | 10:36 |
| ← Dara left | 10:37 |
| → Muzer joined | 10:37 |
|
TheNik
| Apologies if the questions are stupid or if I am misusing terminology here | 10:37 |
| ← mirrorbird left | 10:38 |
| → tiin57 joined | 10:38 |
| → sunri5e joined | 10:38 |
|
bremner
| TheNik: you may find some hints linked at !deploy | 10:38 |
|
gitinfo
| TheNik: Git is not a deployment tool, but you can build one around it (in simple environments) or use it as an object store(for complex ones). Here are some options/ideas to get you started: http://gitolite.com/deploy.html | 10:38 |
|
TheNik
| Many thanks, that should get me started | 10:44 |
|
bremner
| more basic background can be found in !book | 10:48 |
|
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 !parable | 10:48 |
|
j416
| TheNik: you don't need a "git server" | 10:49 |
|
| TheNik: you probably have ssh access to your server, that's sufficient | 10:49 |
| → Swahili joined | 10:49 |
|
TheNik
| I do have SSH access | 10:49 |
|
Swahili
| I'd like to change a commit msg that has a type and was already pushed. I run git rebase --interactive and got a `noop` | 10:50 |
|
ikke
| Swahili: is it the last commit? | 10:50 |
|
Swahili
| ikke: Hi! yes it is | 10:50 |
|
ikke
| Swahili: Then you can use git commit --amend | 10:50 |
|
Swahili
| Ah cool : ) thank you | 10:51 |
|
ikke
| You'd need to force push afterwards (not pull) | 10:51 |
|
TheNik
| j416: In what sense, though? | 10:51 |
|
ikke
| TheNik: git does not need a sever componenent to work | 10:52 |
|
| you just need ssh access + git installed | 10:52 |
|
TheNik
| I suppose that's what I called a "git server" | 10:52 |
|
ikke
| Right, but that server can be a client at the same time | 10:53 |
| → tarkus joined | 10:53 |
|
TheNik
| I see what you mean | 10:53 |
|
Swahili
| Q: When we do git rebase --interactive and pick a commit, any change we do there, it modifies history obviously right? | 10:55 |
|
j416
| Swahili: correct | 10:55 |
|
TheNik
| Alright, thank you for all the helpful advice! | 10:55 |
|
j416
| o/ | 10:56 |
| ← snowkidimd left | 10:58 |
| ← makara1 left | 10:58 |
| → makara1 joined | 10:59 |
| → antranigv joined | 11:02 |
| ← tiin57 left | 11:05 |
| → tiin57 joined | 11:08 |
|
Swahili
| Q: I'd like to change a commit that I already pushed without having to create a new commit. A few seconds ago had a related question to change a commit message which rebase --interactive didn't do because was the last commit. So my question is how to change the last commit if rebase is not available? | 11:19 |
|
j416
| Swahili: what do you mean by 'rebase is not available'? | 11:20 |
|
Jookia
| Swahili: git commit --amend, but don't do it if your commit is public | 11:21 |
|
j416
| Swahili: you can use rebase regardless of whether the commit is the last one or not | 11:21 |
|
Swahili
| Jookia: ah ok! so make the file change and then do git commit --amend and force push | 11:21 |
|
j416
| Swahili: (but there are easier ways, like the one Jookia mentions, in the special case it's the last commit) | 11:21 |
|
Swahili
| j416: ok | 11:22 |
| ← Guest20 left | 11:22 |
| → mrig joined | 11:23 |
|
mrig
| Hello | 11:23 |
|
gitinfo
| mrig: 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. | 11:23 |
|
mrig
| Is it possible to reset to the previous commit but put all the changes from the HEAD into the folder as unstaged changes? | 11:24 |
|
j416
| mrig: git reset previouscommit | 11:25 |
|
mrig
| oh, reset but not hard, yes of course, I am so used to using the --hard flag that I'd forgotten about the normal version, thank you. | 11:26 |
|
j416
| o/ | 11:26 |
|
Jookia
| Swahili: force push upsets people, so be wary | 11:27 |
|
mrig
| What I'm actually trying to do is format a lot of mixed modifications by using the patch command, got myself into a muddle using stash with patch, is there any way to group patches at all that you would recommend? | 11:27 |
|
Swahili
| Jookia: absolutely, I just had to change a "timeout" value and let my colleagues know. it's just we keep the commit as a feature/fix/refactor/chore/etc commitizien | 11:28 |
|
mrig
| to sort or group patches, rather than making commits one at a time to prepare a few? | 11:28 |
|
j416
| mrig: when you say 'patch', do you mean the one outside of git, or something else? | 11:28 |
|
mrig
| j416: the patch flag on the add command, and was trying the patch flag on the stash command. | 11:29 |
|
| I am fine with the patch on the add command, but have so many things going on in the code as I've not committed for some time. All the coded changes are in similar files, so was wondering if there is some way that I can simplify grouping the sections of code. | 11:30 |
|
j416
| mrig: to get the terminology right, a patch is usually a diff (possibly with extra info like author), and that's different from what you're doing | 11:30 |
|
| mrig: what you call patches are in git terms called 'hunks' | 11:31 |
|
mrig
| Ah yes the patch command which is for selecting or editing hunks. | 11:31 |
|
j416
| say add -p or add --patch for clarity, it'll make it easier to understand nex ttime | 11:31 |
|
| it's not a command | 11:31 |
|
mrig
| Right yes, that makes sense. | 11:31 |
|
j416
| it's a flag to the command add | 11:31 |
|
| what did you have in mind when you say simplify? | 11:32 |
| → zebrag joined | 11:33 |
| ← tiin57 left | 11:34 |
|
mrig
| I've a list of operations that I have defined from all of the changes made and would like to group the hunks that correspond and make a commit for each operation; I can do this using --patch. It gets tricky doing this across all of the files one operation at a time and was wondering if there was any way to make the operation concurrent, to either stash or stage the hunks into the respective operations | 11:35 |
|
| group. | 11:35 |
|
j416
| not really | 11:35 |
|
| how would it know what hunks match? | 11:35 |
|
mrig
| I didn't think so, wanted to be sure though; Thank you for confirming that. | 11:36 |
|
| j416: I would do it manually still, just after a little more possibility for organisation in the staging area. | 11:37 |
| → z8z joined | 11:37 |
|
j416
| mrig: what kind of organization are you looking for? | 11:37 |
|
| mrig: what would it do, concretely? | 11:37 |
|
mrig
| allow me to work concurrently on staging the commits. | 11:38 |
| → tiin57 joined | 11:39 |
| → nessonic joined | 11:39 |
|
j416
| mrig: there's only one staging area, typically | 11:39 |
|
mrig
| Getting a cleaner view much faster as when I itterate over every file each time, I am seeing the same code over and over, this would not happen if it were already staged into a group. | 11:39 |
|
j416
| mrig: you can technically have more than one (git supports this), but you'd need some kind of wrapper script/program to help; maybe one exists, I don't know. | 11:40 |
|
| mrig: but just make one commit at a time? | 11:40 |
|
| mrig: should solve the problem? | 11:40 |
|
| mrig: the better solution of course is to commit more often | 11:40 |
|
mrig
| Well ideally I would be making them whilst going along, it is just that sometimes my working style, which can often be concurrently doing several things at once, leads me to forget. | 11:41 |
|
| Yes trying to develop that habit. | 11:41 |
|
| At the moment I am giving commits similar names and then squashing the like named commits together. | 11:42 |
|
| so that the order does not have to be chronological. | 11:42 |
|
| It is interesting to learn that it is possible to have several staging areas though. | 11:42 |
|
| The direct request is to simplify the case where one has not committed often enough and would like to separate all changes out into tidy organised commits. | 11:43 |
|
| Anyway, I shall continue as I am one by one, thank you very much for the information. | 11:44 |
|
j416
| o/ | 11:44 |
|
mrig
| Ah there we go, git reset and it is back as I need it to be :) | 11:45 |
|
| git is awesome. | 11:45 |
| → UrsoBranco joined | 11:45 |
|
j416
| huzzah | 11:45 |
| → donofrio joined | 11:51 |
| → cuppajoeman joined | 12:03 |
| ← tiin57 left | 12:04 |
|
mrig
| I suppose branches is really the solution here. | 12:05 |
| → kupi joined | 12:05 |
| → tiin57 joined | 12:09 |
| → gitter1234 joined | 12:11 |
| → shush joined | 12:12 |
| → Maxattax joined | 12:13 |
| ← feriman left | 12:14 |
| → Z10N joined | 12:14 |
| → feriman joined | 12:16 |
| ← shush left | 12:16 |
| ← igemnace left | 12:20 |
| → alexandre9099 joined | 12:21 |
| Z10N → ZION | 12:21 |
| ← blurkis left | 12:23 |
| ZION → Z10N | 12:23 |
| → blurkis joined | 12:24 |
| → benfelin joined | 12:24 |
| ← jaziz left | 12:24 |
| → TheSecondNik joined | 12:24 |
| ← TheNik left | 12:25 |
| TheSecondNik → TheNik | 12:25 |
|
alexandre9099
| hey, i did something apparently stupid, so i am working with a framework (cakephp) that has some "useless" files that don't need to be tracked, like logs, tmp and vendor, thing is, on the main commit i didn't have a gitignore file so all files went through to the commit. so i added the gitignore file and used git rm --cached on my side to untrack | 12:25 |
|
| those files. Thing is that my coleague did a pull and the files got deleted. What i did wrong and how can i fix it? | 12:25 |
|
| i the commit where i added the gitignore has like +1000 files deleted | 12:25 |
|
j416
| alexandre9099: that's expected behaviour. | 12:28 |
|
| alexandre9099: what is it that you want? | 12:28 |
|
alexandre9099
| j416 to simply not track the files, each dev should have their own version of the files | 12:28 |
|
j416
| alexandre9099: you've succeeded then | 12:28 |
|
| alexandre9099: you added those to your ignore list, so Git won't track them anymore. | 12:29 |
| ← Z10N left | 12:29 |
|
alexandre9099
| how? the other dev got the files deleted by my commit | 12:29 |
| → iVacon joined | 12:29 |
|
j416
| alexandre9099: yes, they were tracked, and you deleted them. | 12:29 |
|
| alexandre9099: the commit you pushed deleted them | 12:29 |
|
alexandre9099
| hmm, so how would i delete them from the remote repo but keep them on the dev's computer? | 12:30 |
|
iVacon
| use the web gui, delete them from there maybe | 12:30 |
| → dohzer joined | 12:30 |
|
j416
| the dev could check them out from the old commit, if they need them | 12:30 |
|
iVacon
| and dont sync | 12:30 |
|
| or clone | 12:30 |
|
j416
| iVacon: no | 12:30 |
|
alexandre9099
| j416 yeah, they did git checkout to go back, but then they wont have my code changes after this "incident" | 12:31 |
| → clime joined | 12:31 |
|
j416
| alexandre9099: checkout the files, not the commit | 12:31 |
|
iVacon
| im not sure | 12:31 |
|
j416
| alexandre9099: git checkout commit -- path/to/files | 12:31 |
|
| alexandre9099: that'll just get the files, and won't move HEAD | 12:31 |
| → twohot joined | 12:32 |
|
j416
| alexandre9099: and since they're ignored now, Git won't even show them | 12:32 |
|
alexandre9099
| i'll try it, but would that also work for folders? | 12:32 |
|
| (recursively) | 12:32 |
|
j416
| yes | 12:32 |
|
alexandre9099
| ok, thanks, brb with feedback ;) | 12:33 |
|
| (let's see if this dont get all messed up cause they are not working on HEAD/master [is this the same?]) | 12:33 |
|
twohot
| Hi all. Can someone explain how I can stop git from looking at --global config settings? It is confusing my repos with others I attempt to clone. | 12:33 |
|
BtbN
| The entire point of global settings is to apply to all repos | 12:34 |
| → Jookia joined | 12:34 |
| ← tiin57 left | 12:34 |
|
BtbN
| if something in there is repo specific, you should move it to that repos config | 12:34 |
|
twohot
| I know I am in trouble when a regular "git clone" asks for my ssh password | 12:35 |
|
BtbN
| "your ssh password"? | 12:35 |
|
twohot
| yes | 12:35 |
|
BtbN
| If you clone via ssh, it's quite normal that it wants to unlock your key, if that's what you mean. | 12:35 |
|
iVacon
| > git clone asks for ssh passwords | 12:35 |
|
| > prob put the wrong repo name | 12:35 |
|
twohot
| the local config points to the right repo | 12:36 |
| → geosmile joined | 12:36 |
|
BtbN
| If you're about to clone something, there is no local config (yet) | 12:36 |
| → alexeightsix joined | 12:37 |
| → muhaha joined | 12:37 |
| ← iVacon left | 12:37 |
|
twohot
| BtbN: Oh sorry, passed that scenario. I meant "git pull" | 12:38 |
| → tgunr joined | 12:38 |
|
clime
| is there a way to edit an already staged hunk? | 12:38 |
| → tiin57 joined | 12:38 |
|
clime
| ...added through git add -p | 12:38 |
|
BtbN
| clime, make changes and add them | 12:38 |
|
clime
| BtbN: what do you mean by make changes? i just want to push one hunk differently... | 12:39 |
|
j416
| alexandre9099: HEAD and master is not the same thing, no. | 12:40 |
|
BtbN
| I thought it's just staged? | 12:40 |
|
clime
| maybe git add -p again will do the thing...? | 12:40 |
|
| yes, i have them staged | 12:40 |
|
BtbN
| So you just added, but did not commit or push anything, right? | 12:40 |
| → pinpox joined | 12:40 |
|
BtbN
| If so, really just make your changes and git add them. | 12:41 |
| → treehug88 joined | 12:41 |
|
clime
| BtbN: i have all the changes I need done, i just need to push a hunk of changes differently than i did before | 12:41 |
|
| "push" to staging area | 12:42 |
|
BtbN
| So just make those changes, and add them. | 12:42 |
|
j416
| clime: you can use reset with -p to unstage individual hunks | 12:42 |
| ← treehug88 left | 12:42 |
|
BtbN
| There is no need to reset | 12:42 |
|
| just add the changes | 12:42 |
|
clime
| j416: oh that could help, thanks | 12:42 |
| → iVacon joined | 12:42 |
|
clime
| BtbN: idk what you mean, i have files in work tree in the state i need them | 12:42 |
|
BtbN
| Then use git add to stage them | 12:42 |
|
clime
| but i don't have staging are in the state i need | 12:43 |
|
BtbN
| That's what you use git add for... | 12:43 |
|
clime
| BtbN: not possible with another git add -p | 12:43 |
|
BtbN
| Why not? | 12:43 |
|
clime
| i'll try the reset method, that should work... | 12:43 |
| → treehug88 joined | 12:43 |
|
iVacon
| i just use git add . cause thats all i need. | 12:44 |
|
| but you might use smth else | 12:44 |
|
BtbN
| Until you add some temp file that was lingering around | 12:44 |
|
iVacon
| lets see if the commit is done | 12:45 |
|
| its done but it didnt push the readme | 12:46 |
|
| odd | 12:46 |
|
clime
| j416: thanks! | 12:47 |
|
j416
| \^^/ | 12:47 |
|
| clime: also useful is K while doing add -p; it'll go back one hunk and let you reconsider | 12:48 |
|
clime
| j416: ok, thx, i noticed while i was about to commit | 12:49 |
|
j416
| o/ | 12:49 |
| ← Swahili left | 12:49 |
|
iVacon
| im on gitlab and i need to change the project description | 12:50 |
|
| the readme is fixed | 12:50 |
|
| but its not changing on top | 12:51 |
|
j416
| iVacon: that has nothing to do with git | 12:52 |
| ← cuppajoeman left | 12:52 |
|
j416
| iVacon: refer to gitlab docs | 12:52 |
|
iVacon
| nvm fixed it myself | 12:52 |
| → cuppajoeman joined | 12:52 |
| ← iVacon left | 12:53 |
| ← antranigv left | 12:54 |
| → antranigv joined | 12:55 |
| → theorangeone_ joined | 12:55 |
| ← treehug88 left | 12:57 |
| ← tiin57 left | 13:04 |
| mobidrop_ → mobidrop | 13:05 |
| → noonien joined | 13:07 |
| ← cuppajoeman left | 13:08 |
| → cuppajoeman joined | 13:08 |
| → mirrorbird joined | 13:08 |
| → tiin57 joined | 13:08 |
| → snowkidimd joined | 13:11 |
| → CodeSlingerPaul joined | 13:16 |
| → deltam joined | 13:16 |
| ← mirrorbird left | 13:18 |
| ← snowkidimd left | 13:18 |
| ← hussam left | 13:22 |
| ← Phylock left | 13:24 |
| → vicfred joined | 13:30 |
| → lucasb joined | 13:34 |
| ← tiin57 left | 13:34 |
| → tiin57 joined | 13:39 |
| → SerialSmile joined | 13:44 |
| → dfee joined | 13:47 |
| → snowkidimd joined | 13:54 |
| rfuentess__ → rfuentess | 13:54 |
| → magic_ninja_work joined | 13:55 |
| → thiago joined | 13:57 |
| → cosimone joined | 13:59 |
| → h3ck joined | 13:59 |
| ← makara1 left | 14:00 |
| ← konrados left | 14:04 |
| ← tiin57 left | 14:04 |
| → tiin57 joined | 14:08 |
| → shush joined | 14:13 |
| → relipse joined | 14:16 |
| ← shush left | 14:17 |
| ← twohot left | 14:17 |
| → irrgit joined | 14:20 |
| → LuxuryMode joined | 14:21 |
| → twohot joined | 14:23 |
| → saluri joined | 14:23 |
| ← SerialSmile left | 14:24 |
| ← Lucas_Gray left | 14:27 |
| ← twohot left | 14:29 |
| ← magic_ninja_work left | 14:32 |
| → Lucas_Gray joined | 14:34 |
| ← tiin57 left | 14:34 |
| ← alexeightsix left | 14:34 |
| → tiin57 joined | 14:38 |
| ← Lucas_Gray left | 14:39 |
| → davispuh joined | 14:39 |
| → Lucas_Gray joined | 14:40 |
| ← cuppajoeman left | 14:45 |
| → rafasc joined | 14:45 |
| → cuppajoeman joined | 14:45 |
| ← saluri left | 14:50 |
| → arcatech joined | 14:52 |
| → smacko joined | 14:54 |
| → Dara joined | 14:55 |
| → Kaivo joined | 14:59 |
| → Hello71 joined | 14:59 |
| → mat001 joined | 15:00 |
| ← dohzer left | 15:00 |
| → mat001_ joined | 15:01 |
| → KnownSyntax joined | 15:04 |
| ← tiin57 left | 15:04 |
| ← mat001 left | 15:04 |
| ← mat001_ left | 15:06 |
| ← calcul0n left | 15:06 |
| → hussam joined | 15:06 |
| → tiin57 joined | 15:08 |
|
alexandre9099
| j416 yeah, git checkout commit -- path/to/files sems to have fixed it ;) thanks | 15:08 |
| → calcul0n joined | 15:08 |
| ← oxymoron93 left | 15:14 |
| → treehug88 joined | 15:16 |
| → HumanG33k joined | 15:16 |
| ← treehug88 left | 15:18 |
| → shush joined | 15:20 |
| ← mobidrop left | 15:23 |
| ← calcul0n left | 15:28 |
| ← Jookia left | 15:29 |
|
j416
| alexandre9099: o/ | 15:29 |
| → Jookia joined | 15:30 |
| ← cdown left | 15:30 |
| → cdown joined | 15:31 |
| → plitter joined | 15:31 |
| ← thiago left | 15:33 |
| ← clime left | 15:33 |
| → calcul0n joined | 15:34 |
| → thiago joined | 15:34 |
| ← tiin57 left | 15:35 |
| → mat001 joined | 15:37 |
| → tiin57 joined | 15:38 |
| ← mat001 left | 15:41 |
| ← rfuentess left | 15:44 |
| ← Brainium left | 15:46 |
| → mindCrime joined | 15:52 |
| ← enoq left | 15:53 |
| ← noonien left | 15:54 |
| → iNs joined | 15:54 |
| → DiffieHellman joined | 15:54 |
| ← chele left | 15:56 |
| → silverwhitefish joined | 16:00 |
| ← arcatech left | 16:01 |
| ← tiin57 left | 16:04 |
| ← dionysus69 left | 16:05 |
| ← alexandre9099 left | 16:07 |
| → tiin57 joined | 16:08 |
| ← muhaha left | 16:09 |
| ← zebrag left | 16:10 |
| → treehug88 joined | 16:12 |
| → Newami joined | 16:14 |
| → mat001 joined | 16:14 |
| → zebrag joined | 16:14 |
| → sudoforge joined | 16:17 |
| → sgen joined | 16:17 |
| → mat001_ joined | 16:18 |
| ← mat001 left | 16:20 |
| ← Jookia left | 16:21 |
| ← cuppajoeman left | 16:22 |
| ← mat001_ left | 16:23 |
| → cuppajoeman joined | 16:23 |
| → Jookia joined | 16:23 |
| ← Newami left | 16:24 |
| → royal_screwup21 joined | 16:26 |
| ← heth left | 16:29 |
| → heth joined | 16:30 |
| ← Lucas_Gray left | 16:32 |
| → mat001 joined | 16:33 |
| → cdown_ joined | 16:34 |
| ← zebrag left | 16:34 |
| ← tiin57 left | 16:34 |
| ← cdown left | 16:36 |
| cdown_ → cdown | 16:36 |
| ← mat001 left | 16:37 |
| → zebrag joined | 16:37 |
| → markus-k joined | 16:37 |
| → stats4647 joined | 16:38 |
| → tiin57 joined | 16:38 |
| → Guest20 joined | 16:41 |
| ← cuppajoeman left | 16:43 |
| → cd joined | 16:46 |
| ← Guest20 left | 16:48 |
| ← z8z left | 16:49 |
| ← FH_thecat left | 16:50 |
| → FH_thecat joined | 16:51 |
| → g4570n joined | 16:55 |
| → mat001 joined | 16:56 |
| → orbyt_v7 joined | 17:00 |
| → Rick8024 joined | 17:02 |
| ← FH_thecat left | 17:03 |
| ← Rick8024 left | 17:03 |
| ← tiin57 left | 17:04 |
| → crose joined | 17:05 |
| ← KnoP left | 17:05 |
| → Betal joined | 17:07 |
| → tiin57 joined | 17:08 |
| ← dfee left | 17:08 |
| → shush_ joined | 17:12 |
| → cuppajoeman joined | 17:14 |
| ← mat001 left | 17:15 |
| ← shush left | 17:15 |
| → orbyt_ joined | 17:18 |
| → standardname joined | 17:22 |
| ← tarkus left | 17:24 |
| ← treehug88 left | 17:28 |
| → dfee joined | 17:32 |
| ← royal_screwup21 left | 17:33 |
| → royal_screwup21 joined | 17:34 |
| → treehug88 joined | 17:34 |
| ← tiin57 left | 17:34 |
| → tiin57 joined | 17:38 |
| ← royal_screwup21 left | 17:39 |
| ← LetoThe2nd left | 17:52 |
| → imMute joined | 17:53 |
| → dougquaid joined | 18:01 |
| ← T_UNIX left | 18:03 |
| → fannagoganna joined | 18:04 |
| ← tiin57 left | 18:04 |
| → royal_screwup21 joined | 18:05 |
|
dougquaid
| Can a branch have a different remote server than master? | 18:08 |
| ← ghostshadow001 left | 18:08 |
| → tiin57 joined | 18:08 |
|
rafasc
| dougquaid: yes check git branch --set-upstream-to | 18:09 |
|
dougquaid
| thanks | 18:09 |
|
rafasc
| but that will also change what it tracks for ahead/behind. | 18:10 |
|
| If you want more of a triangular workflow, it's slightly harder to set up. | 18:10 |
| ← royal_screwup21 left | 18:11 |
|
rafasc
| e.g. by configuring a branch."name".pushRemote | 18:11 |
| → heroux joined | 18:12 |
|
dougquaid
| I just want to make changes to a github repo and also merge in their changes to my branch, but I'd rather not have a github account. I think I can live with the ahead/behind thing | 18:13 |
| → saluri joined | 18:13 |
| → surfist1 joined | 18:13 |
| → Phylock joined | 18:14 |
| ← saluri left | 18:14 |
|
rafasc
| dougquaid: are you pushing your changes somewhere? | 18:14 |
|
dougquaid
| Just to my local git server. I don't intend on pushing to github or making any pull requests | 18:15 |
| → tarkus joined | 18:15 |
|
rafasc
| I would recommend just adding github as one remote, and just fetch and merge occasionally. | 18:15 |
| ← TheNik left | 18:16 |
|
rafasc
| I think the branch tracking is more useful for the branches and remotes you are pushing to. | 18:16 |
|
| git remote add upstream github.com/user/repo; then occasionally you can: git pull upstream <branch>; | 18:17 |
|
dougquaid
| Thanks I'll try that | 18:18 |
| → mobidrop joined | 18:18 |
| ← bocaneri left | 18:23 |
|
haymawk
| I am trying to resolve merge conflicts so that I can make a pull request. I did a "git pull origin <branch>" to pull the changes in. There are 4 files marked with CONFLICT. However "git mergetool" just spits out "No files need merging". How can I resolve these conflicts? | 18:23 |
| ← treehug88 left | 18:24 |
|
haymawk
| I don't see any conflict markers "<<<<<<<<<<<<<<<<<" in the files | 18:24 |
|
| this is interesting though, I can launch "git mergetool <specific file>" and it will pull up the conflicts. Is there a bug in the new version? | 18:26 |
| ← cosimone left | 18:26 |
| → Lunatrius joined | 18:26 |
|
rafasc
| haymawk: your merge tool might use a different algorithm to solve conflicts than what git uses. | 18:30 |
| ← AngryOwl left | 18:31 |
| → AngryOwl joined | 18:32 |
| → Duckle joined | 18:32 |
|
rafasc
| I use kdiff3, and usually it solves conflicts correctly that git wasn't sure. | 18:32 |
| ← tiin57 left | 18:34 |
|
haymawk
| I also use kdiff3. In the past when kdiff3 has auto resolved conflicts, it usually brings up the window and says "0 conflicts found". Then kdiff3 marks the file as resolved on close. | 18:36 |
| → tiin57 joined | 18:38 |
| ← Dara left | 18:39 |
| → royal_screwup21 joined | 18:40 |
| → nvmd joined | 18:42 |
| → xelxebar joined | 18:42 |
| ← royal_screwup21 left | 18:45 |
| ← Muimi left | 18:47 |
|
rafasc
| haymawk: what does git status say? | 18:48 |
| → clime joined | 18:48 |
|
rafasc
| I don't remember very well, but I have the impression that there are corner cases when it's conflicts of the type "deleted by us/them" | 18:50 |
| → TheNik joined | 18:55 |
|
haymawk
| here's the full output https://pastebin.com/i3N0ahZQ | 18:59 |
| → yonder joined | 18:59 |
|
rafasc
| haymawk: does git diff; show any changes for those "unmerged paths"? | 19:02 |
| ← tiin57 left | 19:04 |
|
haymawk
| yes | 19:04 |
| ← yitz left | 19:07 |
|
haymawk
| "git mergetool" -> "No files need merging"; however git mergetool Visio/AddIn/app.config launches kdiff3 which says "Total number of conflicts: 21, Nr of automatically solved conflicts: 18, Nr of unsolved conflicts: 3" | 19:08 |
| → tiin57 joined | 19:08 |
| → comptroller joined | 19:10 |
| → yitz joined | 19:10 |
| → jstein joined | 19:11 |
| ← geosmile left | 19:18 |
| → gopper joined | 19:19 |
| → sunrunner20 joined | 19:21 |
| ← gopper left | 19:21 |
| → sindns joined | 19:25 |
| → vultyre joined | 19:26 |
| ← vultyre left | 19:27 |
| → wootehfoot joined | 19:27 |
| → noonien joined | 19:30 |
| → royal_screwup21 joined | 19:33 |
| ← tiin57 left | 19:34 |
| ← planetcall|work left | 19:37 |
| → tiin57 joined | 19:38 |
| ← vicfred left | 19:38 |
| ← sozuba left | 19:39 |
| → PikaChokeMe_ joined | 19:41 |
| → sozuba joined | 19:41 |
|
haymawk
| I have to run, but I'm going to assume there's something messed up with my mergetool configuration. | 19:42 |
| ← sozuba left | 19:48 |
| ← tarkus left | 19:49 |
| ← nessonic left | 19:49 |
| → sozuba joined | 19:51 |
| → justsomeguy joined | 19:51 |
| → m0viefreak joined | 19:55 |
| ← royal_screwup21 left | 19:56 |
| → ADG1089 joined | 19:57 |
| → royal_screwup21 joined | 19:57 |
| → arcatech joined | 20:01 |
| ← royal_screwup21 left | 20:01 |
| → jrofd joined | 20:01 |
| ← orbyt_ left | 20:04 |
| ← tiin57 left | 20:04 |
| ← sozuba left | 20:06 |
| → tiin57 joined | 20:07 |
| ← Maxattax left | 20:10 |
| → royal_screwup21 joined | 20:11 |
| ← fannagoganna left | 20:14 |
| ← snowkidimd left | 20:15 |
| ← comptroller left | 20:18 |
| → comptroller joined | 20:21 |
| ← cd left | 20:21 |
| → Lucas_Gray joined | 20:22 |
| ← wootehfoot left | 20:24 |
| → vicfred joined | 20:24 |
| ← ADG1089 left | 20:24 |
| → impermanence joined | 20:26 |
|
impermanence
| I just set a local as my remote for some testing. | 20:26 |
|
| If I want to checkout master do I need to create it first like git checkout -b master? | 20:26 |
|
| or can I just git checkout master? | 20:27 |
|
rafasc
| git checkout master is enough if a local master already exists. | 20:28 |
|
impermanence
| it does not | 20:28 |
|
rafasc
| if it doesn't, the answer is slightly more complicated. git checkout master; may work. Git will try to guess what you mean by that, and do something equivalent to git checkout --track origin/master | 20:29 |
|
impermanence
| git checkout -b master tells me I just switched to master | 20:29 |
|
| but then when I git branch nothing returns... | 20:29 |
|
rafasc
| what does git status say? | 20:30 |
|
impermanence
| on branch master | 20:30 |
|
| cool | 20:30 |
|
| thanks | 20:30 |
|
| good call | 20:30 |
|
rafasc
| you may be in the unborn branch state. | 20:30 |
|
| meaning you are techincally on master, but master does not have commits yet. | 20:30 |
|
impermanence
| which is indeed the case | 20:30 |
|
| how can I clone a local to another (local) directory? | 20:33 |
|
| I thought it was just git clone path/to/source path/to/other/dir | 20:34 |
|
rafasc
| you cannot clone directories, only repositories. | 20:34 |
|
impermanence
| but this just creates a dir in path/to/source/ | 20:34 |
|
| right | 20:34 |
|
rafasc
| it should not create that. | 20:34 |
|
impermanence
| sorry the dir I am in is a repo | 20:34 |
| ← tiin57 left | 20:34 |
|
impermanence
| what is the command to clone this repo locally to another local dir? | 20:34 |
|
rafasc
| git clone path/to/source /path/to/other/dir; should work as long as path/to/source is a git repo, and path/to/other/dir doesn't exist, or is empty. | 20:35 |
|
impermanence
| so it doesn't need to be git clone path/to/source/.git /path/to/other/dir or anything? | 20:35 |
| → shabius joined | 20:36 |
|
rafasc
| impermanence: no, git can figure that out itself. | 20:36 |
|
| you can use the path to .git/ but it is not necessary. | 20:37 |
| ← HumanG33k left | 20:37 |
|
impermanence
| I screwed up the path of course :) | 20:37 |
|
rafasc
| machine is always right :D | 20:37 |
|
impermanence
| why I love it | 20:37 |
| → tiin57 joined | 20:37 |
|
impermanence
| it didn't carry the source though | 20:39 |
|
| is that because there have been no commits? | 20:39 |
|
| basically I was on master | 20:39 |
|
| I touched and edited a little toy file | 20:39 |
|
| then I cloned that repo to a different dir | 20:39 |
|
| but the toy file is not present after checking out a new branch | 20:39 |
|
| is that because I had previously not committed that file to master? | 20:40 |
| ← royal_screwup21 left | 20:40 |
| → royal_screwup21 joined | 20:40 |
| → igemnace joined | 20:40 |
| ← gitter1234 left | 20:40 |
| ← blurkis left | 20:40 |
|
impermanence
| I think I have to first push changes to the local master | 20:40 |
|
| ? | 20:41 |
| → blurkis joined | 20:41 |
|
mackerman
| Commit to the repo first. Then new clones will have the history. | 20:42 |
| → nabil joined | 20:42 |
|
impermanence
| do I have to actually push or just commit? | 20:42 |
|
| just commit apparently | 20:42 |
|
mackerman
| push is sending commits to a remote. | 20:43 |
| ← nabil_ left | 20:43 |
| ← royal_screwup21 left | 20:45 |
| → nabil_ joined | 20:45 |
| ← nabil left | 20:46 |
|
impermanence
| so pushing to local is not really a thing huh? | 20:47 |
|
| what about if the remote for test purposes is set to a local dir? | 20:48 |
|
rafasc
| impermanence: uncommitted changes do not belong to any branch, so when you cloned, the branch was empty. You get it empty. | 20:49 |
|
| impermanence: you can push to a local repo, but usually it needs to be --bare clone. Because git imposes restrictions on pushing into commits with branches checked out. | 20:50 |
| → orbyt_ joined | 20:50 |
|
rafasc
| you can disable that feature, but it's easier to just have a --bare clone. | 20:50 |
|
impermanence
| ah. okay. god git is so subtle and powerful. | 20:51 |
| → Brainium joined | 20:51 |
|
impermanence
| remote rejected master -> master (branch is currently checked out) | 20:52 |
|
| so I checked out master | 20:52 |
|
| then | 20:52 |
|
| git merge test | 20:52 |
|
standardname
| I just lol'd reading "god git is so subtle and powerful" | 20:53 |
|
impermanence
| k | 20:53 |
|
| ha | 20:53 |
|
| yeah but it is true though | 20:53 |
|
| I mean I don't know shit about it...but it's a beast | 20:53 |
|
| if it weren't people wouldn't be fucking up their repos constantly... | 20:53 |
|
| which they most definitely are | 20:53 |
| ← h3ck left | 20:54 |
| ← kupi left | 20:55 |
| → h3ck joined | 20:55 |
|
impermanence
| what do I need to do to deal with 'remote rejected master -> master (branch is currently checked out)' | 20:55 |
| → royal_screwup21 joined | 20:58 |
| ← feriman left | 21:01 |
| ← jstein left | 21:02 |
| ← tiin57 left | 21:04 |
| ← jrofd left | 21:06 |
| → PikaChokeMe joined | 21:07 |
| → tiin57 joined | 21:08 |
| → lukey joined | 21:10 |
| ← PikaChokeMe_ left | 21:10 |
| ← dfee left | 21:16 |
| ← Phylock left | 21:16 |
| → tarkus joined | 21:16 |
| ← vicfred left | 21:17 |
| ← tgunr left | 21:17 |
| ← rafasc left | 21:21 |
| → rafasc joined | 21:22 |
| → puff joined | 21:27 |
| ← h3ck left | 21:29 |
| → j12866 joined | 21:29 |
|
sdgathman
| impermanence: the remote is not a bare repo. The owner needs to checkout some other branch, then you can push to their master. | 21:30 |
| → infl00p joined | 21:30 |
|
impermanence
| I solved it with some dumb hack lol. | 21:30 |
|
| it was just a test | 21:30 |
|
| i'm over it...! | 21:30 |
| → Phylock joined | 21:30 |
|
impermanence
| thank you though | 21:30 |
| ← shush_ left | 21:34 |
| → shush joined | 21:34 |
| ← tiin57 left | 21:34 |
| → tiin57 joined | 21:38 |
| → tafa2 joined | 21:38 |
| ← shush left | 21:39 |
| → cliluw joined | 21:39 |
| → dfee joined | 21:42 |
| → shush joined | 21:44 |
| → thomasross joined | 21:44 |
| → bn_work joined | 21:45 |
| → to1ne joined | 21:47 |
|
bn_work
| hi, git 2.13.6, has anyone tried https://stackoverflow.com/a/15398512 into their workflow? If so, does it work / have any side effects by using stash, rebase and and `reset --soft HEAD~`? | 21:47 |
| ← mrig left | 21:48 |
| → ilmostro joined | 21:49 |
| ← nabil_ left | 21:50 |
|
bn_work
| (the script basically adds an alias to auto-trim trailing whitespace in your index and/or tree) | 21:50 |
| → jaziz joined | 21:53 |
| ← to1ne left | 21:57 |
| ← theoceaniscool left | 22:03 |
| ← orbyt_v7 left | 22:04 |
| ← tiin57 left | 22:04 |
| → to1ne joined | 22:06 |
| → cosimone joined | 22:06 |
| → morisama joined | 22:07 |
| ← arcatech left | 22:07 |
| → tiin57 joined | 22:08 |
| ← m0viefreak left | 22:10 |
| ← LuxuryMode left | 22:11 |
| ← calcul0n left | 22:11 |
| → wrbuckley joined | 22:11 |
|
wrbuckley
| My first time on Freenode. | 22:13 |
|
| Nice to find a channel that discusses git. | 22:14 |
| ← impermanence left | 22:15 |
|
Jookia
| wrbuckley: welcome | 22:20 |
| → orbyt_v7 joined | 22:22 |
| ← royal_screwup21 left | 22:29 |
|
fossegrim
| wrbuckley: Welcome! There are lots of good channels around here about most worthwhile projects. | 22:29 |
| → royal_screwup21 joined | 22:29 |
|
wrbuckley
| Thanks for the welcoming statements. | 22:30 |
|
| It looks as if the only messages I will see are those posted after I log into a channel, and then only for as long as I stay logged into that channel. | 22:30 |
| → physikoi joined | 22:30 |
|
wrbuckley
| This is to say, it looks to be that I cannot review the prior history of any channel. | 22:31 |
|
| Is this correct? | 22:31 |
|
mackerman
| Yes. There is no official log. | 22:31 |
|
Jookia
| wrbuckley: IRC is more one of thet things you stay logged in on and ask or see what happens | 22:32 |
|
| are you new to git? | 22:32 |
|
physikoi
| Hi #git. I'm having a lot of trouble diffing a file due to whitespace and EOL characters. Since I have no idea how to correct the whitespace, I was just going to copy paste the actual code changes. However, I can't even figure out how to get my diff to ignore EOL changes and changes to tab/space indentation. Halp please? | 22:32 |
|
Jookia
| physikoi: diffs shouldn't ignore tab/space indentation, but you can normalize EOLs. are you on windows? | 22:33 |
|
physikoi
| wrbuckley: if you use irssi, it'll record a log for you if you set it up. Probably similar functionality with other clients | 22:33 |
|
| I'm actually on mac, but one of my team mates does use windows | 22:33 |
|
wrbuckley
| I have been using git for about eight months. Starting to get the hang of it. I did use git to post some software on GitHub several years ago: shustringer. | 22:34 |
| ← tiin57 left | 22:34 |
| ← royal_screwup21 left | 22:34 |
|
Jookia
| physikoi: https://docs.github.com/en/github/using-git/configuring-git-to-handle-line-endings | 22:34 |
| ← mobidrop left | 22:35 |
| ← relipse left | 22:35 |
| → Weegeeweeg joined | 22:38 |
| → tiin57 joined | 22:38 |
|
physikoi
| Jookia: Hm, well i followed the instructions. This doesn't seem to help diffing the screwedup file tho | 22:41 |
| → causasui joined | 22:44 |
| → goldmund joined | 22:46 |
| → royal_screwup21 joined | 22:47 |
|
Jookia
| physikoi: you might need to fix your line endings using a script/tool since you've already checked them out | 22:47 |
|
physikoi
| I actually have an example. Remote:`<?^Mnamespace Lib\Escrow\Stripe;^Muse Lib\Escrow\Stripe\EscrowPayoutManager,^M Lib\Escrow\Authorize\AuthorizeDotNetManager,^M Lib\Quickbooks\QuickbooksManager` | 22:48 |
|
| On local: those are five lines ending in ^M | 22:49 |
|
| oops, by ^M i mean the CR character | 22:51 |
| ← royal_screwup21 left | 22:51 |
| ← clime left | 22:53 |
| ← dfee left | 22:54 |
| → dfee joined | 22:55 |
| ← Lucas_Gray left | 22:55 |
| ← CodeSlingerPaul left | 22:57 |
| ← cosimone left | 22:57 |
|
physikoi
| it's alright. i'm just gonna go manual (online diff, checkout, paste difference). boom | 22:57 |
| → Lucas_Gray joined | 23:02 |
| ← igemnace left | 23:04 |
| ← tiin57 left | 23:04 |
| → tiin57 joined | 23:08 |
|
bn_work
| ok, guess I'll be the guinea pig :) so it's been a while but once I update `~/.gitconfig` are changes instantaneous? or do I need to issues some sort of "reload" command? | 23:11 |
|
Jookia
| bn_work: should be instant for new invocations of git | 23:11 |
| ← shush left | 23:12 |
| ← goldmund left | 23:12 |
|
bn_work
| thanks | 23:13 |
| → shush joined | 23:16 |
| ← mindCrime left | 23:18 |
| → mindCrime joined | 23:18 |
| → bambanx joined | 23:18 |
| → daurnimator joined | 23:19 |
|
bn_work
| so can anyone comment on this whitespace fix hack? | 23:19 |
|
| it looks like if both index and tree is "dirty", it does a commit, stash save, then rebase on HEAD~, pop, then `reset --soft HEAD~`; otherwise if just index is dirty, it does the same except w/o the stash save + pop. | 23:22 |
|
TheNik
| I am trying to push from my local git repo to a remote one via SSH. "git push ssh://pi@k****.de:port/path/to/repo.git master" returns "fatal: protocol error: bad line length character: pi@k". When I ssh to the same location (https://stackoverflow.com/a/8175315) I see that the four chars it returned are from a password prompt | 23:23 |
|
| How do I specify the password for this push command? | 23:24 |
| → igemnace joined | 23:24 |
| ← Lucas_Gray left | 23:24 |
| ← Phylock left | 23:27 |
| ← g4570n left | 23:31 |
| → vicfred joined | 23:31 |
| → g4570n joined | 23:33 |
| ← tiin57 left | 23:34 |
|
gildarts
| Generally, it is better to set up keys and use them. | 23:37 |
| → tiin57 joined | 23:38 |
| ← bambanx left | 23:43 |
|
bn_work
| so... IF (index && tree are dirty) THEN commit, stash save, `rebase --whitespace=fix HEAD~` (rebase/replay last commit while fixing whitespace on top of 1st parent ancestor of HEAD), then re-apply stash, then adjust HEAD to HEAD~ (1st parent ancestor of HEAD) | 23:44 |
| ← shush left | 23:44 |
|
bn_work
| my question is why is the last `reset --soft HEAD~` necessary? | 23:45 |
|
| I guess that "forgets" the whitespace fixed commit? but why? | 23:46 |
|
| here's the git commands in question: https://github.com/ntc2/conf/blob/7b400748554a72bdd9acdf8c96c58a773cf99a5c/dot.gitconfig#L353-L366 | 23:47 |
|
Jookia
| bn_work: git reset --soft HEAD~ puts your branch to the previous commit but moves the previous commit to your working tree and index | 23:47 |
|
bn_work
| or more specifically https://github.com/ntc2/conf/blob/7b400748554a72bdd9acdf8c96c58a773cf99a5c/dot.gitconfig#L357-L361 , or L361 | 23:47 |
|
Jookia
| moves the previous commit's tree* | 23:48 |
| → kupi joined | 23:48 |
|
bn_work
| Jookia: I thought it leaves the index alone? | 23:49 |
|
| > --soft \ Does not touch the index file or the working tree at all (but resets the head to <commit>, just like all modes do). This leaves all your changed files "Changes to be committed", as git status would put it. | 23:50 |
|
Jookia
| bn_work: i think it keeps the changes in the index | 23:50 |
|
bn_work
| Jookia: as in "leaves the index alone"? | 23:50 |
|
Jookia
| ah, that makes sense | 23:50 |
|
| you keep the commit's working tree and index file | 23:50 |
|
| but change HEAD | 23:51 |
|
| which makes it a diff | 23:51 |
|
bn_work
| Jookia: right, you're just adjusting the HEAD pointer, IIRC | 23:51 |
|
Jookia
| i was looking at it from the other perspective | 23:51 |
|
bn_work
| Jookia: my question is why is that step done in the context of this whitespace fix alias | 23:51 |
|
| Jookia: "makes it a diff"? | 23:52 |
| → shush joined | 23:52 |
|
Jookia
| bn_work: well since the working tree/index are different to HEAD | 23:52 |
|
bn_work
| Jookia: I think it just "forgets" the HEAD commit | 23:52 |
|
Jookia
| you've changed HEAD so it's different now | 23:52 |
|
bn_work
| well, it could have been diff(erent) if your tree + index was dirty anyway? | 23:54 |
|
| to begin with | 23:54 |
|
TheNik
| gildarts: I think I managed to do that | 23:55 |
|
bn_work
| I guess if it was clean to begin with, then yes, you introduce a diff there too | 23:55 |
|
TheNik
| Now I can push to the remote machine, but my branches folder on the target repo remains empty, but the push creates a bunch of (stuff) in objects | 23:55 |
|
| Is that correct behaviour? | 23:56 |
|
bn_work
| Jookia: oh wait, which question were you answering? :) "makes it a diff"? or the question in re. to the whitespace fix context? | 23:56 |
|
Jookia
| bn_work: i guess the situation is this: you have 3 trees, the HEAD, the working tree, and the staging area (index). if you have changes with broken line endings it depends what index they're in | 23:56 |
| ← nvmd left | 23:57 |
|
Jookia
| bn_work: by committing your broken line endings in the staging area to a temporary commit git fixes up the line endings, then you move those changes back to the staging area by undoing the commit using reset | 23:58 |
|
bn_work
| Jookia: hmm, not quite following... I'm assuming you're using an analogy here because there's only 1 index | 23:58 |
|
Jookia
| bn_work: there's your working tree, the staging area (known as the index), and HEAD. so 3 trees | 23:58 |
|
TheNik
| Freshly "git init --bare" the remote repo, then "git push ssh://pi@host:port/path/to/repo.git master" on the local repo, which creates no errors, but the remote repo.git/branches/ is empty | 23:59 |