{"thread":{"id":"14461","subject":"applying and committing patches in a single git command","startedAt":"2008-07-15T08:50:24Z","lastAt":"2008-07-15T11:03:14Z","messageCount":6,"participants":["Erez Zilber","Stephan Beyer","Boaz Harrosh","Andreas Ericsson"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"83377","messageId":"ce513bcc0807150150l783e9ff1kd7780dc59f4b5a3d@mail.gmail.com","threadId":"14461","inReplyTo":null,"subject":"applying and committing patches in a single git command","fromName":"Erez Zilber","fromEmail":"erezzi.list@gmail.com","sentAt":"2008-07-15T08:50:24Z","receivedAt":"2008-07-15T08:50:24Z","isPatch":false,"sender":{"key":"erezzi.list@gmail.com","avatar":null},"body":"Hi,\n\nSomeone created a patch with git-format-patch and sent it to me. I\nwould like to apply & commit the patch. If I use git-apply, it only\npatches my tree without committing it. Now, I need to copy the commit\nlog, run git-commit and paste the commit log there. Is there a more\nintelligent way to do that?\n\nThanks,\nErez\n"},{"id":"83378","messageId":"20080715085228.GA6244@leksak.fem-net","threadId":"14461","inReplyTo":"ce513bcc0807150150l783e9ff1kd7780dc59f4b5a3d@mail.gmail.com","subject":"Re: applying and committing patches in a single git command","fromName":"Stephan Beyer","fromEmail":"s-beyer@gmx.net","sentAt":"2008-07-15T08:52:28Z","receivedAt":"2008-07-15T08:52:28Z","isPatch":false,"sender":{"key":"s-beyer@gmx.net","avatar":"https://avatars.githubusercontent.com/u/143889?v=4"},"body":"Hi,\n\nErez Zilber wrote:\n> Hi,\n> \n> Someone created a patch with git-format-patch and sent it to me. I\n> would like to apply & commit the patch. If I use git-apply, it only\n> patches my tree without committing it. Now, I need to copy the commit\n> log, run git-commit and paste the commit log there. Is there a more\n> intelligent way to do that?\n\ngit-am is exactly what you want.\n\nRegards.\n\n-- \nStephan Beyer <s-beyer@gmx.net>, PGP 0x6EDDD207FCC5040F\n"},{"id":"83379","messageId":"487C659E.60606@panasas.com","threadId":"14461","inReplyTo":"ce513bcc0807150150l783e9ff1kd7780dc59f4b5a3d@mail.gmail.com","subject":"Re: applying and committing patches in a single git command","fromName":"Boaz Harrosh","fromEmail":"bharrosh@panasas.com","sentAt":"2008-07-15T08:53:50Z","receivedAt":"2008-07-15T08:53:50Z","isPatch":false,"sender":{"key":"bharrosh@panasas.com","avatar":"https://gravatar.com/avatar/347e426f8ca0409f6891ceeefd4c3c2d8769608382323057efeaa362b4c3dbf3?d=mp&s=160"},"body":"Erez Zilber wrote:\n> Hi,\n> \n> Someone created a patch with git-format-patch and sent it to me. I\n> would like to apply & commit the patch. If I use git-apply, it only\n> patches my tree without committing it. Now, I need to copy the commit\n> log, run git-commit and paste the commit log there. Is there a more\n> intelligent way to do that?\n> \n> Thanks,\n> Erez\n> \ngit-am, can take all bunch of them at once\n\nBoaz\n"},{"id":"83383","messageId":"ce513bcc0807150246g790ca009vc0a76bd6ef0aac9b@mail.gmail.com","threadId":"14461","inReplyTo":"487C659E.60606@panasas.com","subject":"Re: applying and committing patches in a single git command","fromName":"Erez Zilber","fromEmail":"erezzi.list@gmail.com","sentAt":"2008-07-15T09:46:18Z","receivedAt":"2008-07-15T09:46:18Z","isPatch":false,"sender":{"key":"erezzi.list@gmail.com","avatar":null},"body":"On Tue, Jul 15, 2008 at 11:53 AM, Boaz Harrosh <bharrosh@panasas.com> wrote:\n> Erez Zilber wrote:\n>> Hi,\n>>\n>> Someone created a patch with git-format-patch and sent it to me. I\n>> would like to apply & commit the patch. If I use git-apply, it only\n>> patches my tree without committing it. Now, I need to copy the commit\n>> log, run git-commit and paste the commit log there. Is there a more\n>> intelligent way to do that?\n>>\n>> Thanks,\n>> Erez\n>>\n> git-am, can take all bunch of them at once\n>\n> Boaz\n>\n\nThanks. I have 2 more questions:\n1. How can I tell git-am to take a patch from an e-mail from a gmail account?\n2. If I have the actual patch on my machine (not in an e-mail\nmessage), I guess that I need something else (not git-am). Is there\nanything like that?\n\nThanks,\nErez\n"},{"id":"83384","messageId":"487C752E.4090707@op5.se","threadId":"14461","inReplyTo":"ce513bcc0807150246g790ca009vc0a76bd6ef0aac9b@mail.gmail.com","subject":"Re: applying and committing patches in a single git command","fromName":"Andreas Ericsson","fromEmail":"ae@op5.se","sentAt":"2008-07-15T10:00:14Z","receivedAt":"2008-07-15T10:00:14Z","isPatch":false,"sender":{"key":"ae@op5.se","avatar":"https://gravatar.com/avatar/426e89595c75a8f5252dd0c989e5fabe5bcac616e68557427ad9aef6b0ca342a?d=mp&s=160"},"body":"Erez Zilber wrote:\n> On Tue, Jul 15, 2008 at 11:53 AM, Boaz Harrosh <bharrosh@panasas.com> wrote:\n>> Erez Zilber wrote:\n>>> Hi,\n>>>\n>>> Someone created a patch with git-format-patch and sent it to me. I\n>>> would like to apply & commit the patch. If I use git-apply, it only\n>>> patches my tree without committing it. Now, I need to copy the commit\n>>> log, run git-commit and paste the commit log there. Is there a more\n>>> intelligent way to do that?\n>>>\n>>> Thanks,\n>>> Erez\n>>>\n>> git-am, can take all bunch of them at once\n>>\n>> Boaz\n>>\n> \n> Thanks. I have 2 more questions:\n> 1. How can I tell git-am to take a patch from an e-mail from a gmail account?\n\nYou can't, but you can save your gmail message to disc and pass\nthe saved file to \"git am\" (don't use \"git-am\" over \"git am\";\nwe're trying to get away from that old format of typing).\n\n> 2. If I have the actual patch on my machine (not in an e-mail\n> message), I guess that I need something else (not git-am). Is there\n> anything like that?\n> \n\ngit apply patchfile\npatch (-p1) < patchfile\n\n-- \nAndreas Ericsson                   andreas.ericsson@op5.se\nOP5 AB                             www.op5.se\nTel: +46 8-230225                  Fax: +46 8-230231\n"},{"id":"83386","messageId":"ce513bcc0807150403v75233737w127719dd30e48176@mail.gmail.com","threadId":"14461","inReplyTo":"487C752E.4090707@op5.se","subject":"Re: applying and committing patches in a single git command","fromName":"Erez Zilber","fromEmail":"erezzi.list@gmail.com","sentAt":"2008-07-15T11:03:14Z","receivedAt":"2008-07-15T11:03:14Z","isPatch":false,"sender":{"key":"erezzi.list@gmail.com","avatar":null},"body":"On Tue, Jul 15, 2008 at 1:00 PM, Andreas Ericsson <ae@op5.se> wrote:\n> Erez Zilber wrote:\n>>\n>> On Tue, Jul 15, 2008 at 11:53 AM, Boaz Harrosh <bharrosh@panasas.com>\n>> wrote:\n>>>\n>>> Erez Zilber wrote:\n>>>>\n>>>> Hi,\n>>>>\n>>>> Someone created a patch with git-format-patch and sent it to me. I\n>>>> would like to apply & commit the patch. If I use git-apply, it only\n>>>> patches my tree without committing it. Now, I need to copy the commit\n>>>> log, run git-commit and paste the commit log there. Is there a more\n>>>> intelligent way to do that?\n>>>>\n>>>> Thanks,\n>>>> Erez\n>>>>\n>>> git-am, can take all bunch of them at once\n>>>\n>>> Boaz\n>>>\n>>\n>> Thanks. I have 2 more questions:\n>> 1. How can I tell git-am to take a patch from an e-mail from a gmail\n>> account?\n>\n> You can't, but you can save your gmail message to disc and pass\n> the saved file to \"git am\" (don't use \"git-am\" over \"git am\";\n> we're trying to get away from that old format of typing).\n>\n>> 2. If I have the actual patch on my machine (not in an e-mail\n>> message), I guess that I need something else (not git-am). Is there\n>> anything like that?\n>>\n>\n> git apply patchfile\n> patch (-p1) < patchfile\n\nThanks.\n"}]}