All of lore.kernel.org
 help / color / mirror / Atom feed
From: free.amit.kumar@gmail.com (Amit Kumar)
To: kernelnewbies@lists.kernelnewbies.org
Subject: How to get patches from e-mail client?
Date: Mon, 17 Apr 2017 08:26:05 +0000	[thread overview]
Message-ID: <20170417082605.GC3961@li620-105.members.linode.com> (raw)
In-Reply-To: <20170417081620.GA28656@osadl.at>

On Mon, Apr 17, 2017 at 08:16:20AM +0000, Nicholas Mc Guire wrote:
> On Mon, Apr 17, 2017 at 08:02:32AM +0000, Amit Kumar wrote:
> > On Mon, Apr 17, 2017 at 03:52:42PM +0800, Rock Lee wrote:
> > > Hi:
> > > If I want to get a patch and use "git am" to merge it into my project,
> > > how can I do? I mean I can copy and paste a patch from my e-mail
> > > client, but it is too silly. Is there any way to save a email as a
> > > patch?
> > Run mutt. Select the patch you want to download using up/down arrow key.
> > Press s. Delete the mailbox name provide using Backspace key and provide
> > path on local filesystem e.g. ~/patches/logical_name.patch. It will ask
> > to save, yes is default, so press Enter.
> > 
> > Now your patch is saved on local filesystem. Create a topic branch e.g.
> > Your on master,
> > git checkout -b work
> > 
> > Now you are on topic branch work, run as follows,
> > 
> > git am ~/patches/logical_name.patch
> > 
> > If you are on the right tree then it should apply the patch and commit.
> > If something goes wrong, please follow the instructions provided by git.
> > 
> > I think this will help.
> >
> you can simplify this in mutt by adding:
> 
> macro index A '| git am -s'
> 
> to your ~/.muttrc 
> To apply a patch simply move into the repository you want to 
> work on open mutt and hit  A  at that email to pipe it into 
> git am -s  and apply it.
Something to learn. Thanks.
Regards,
Amit Kumar
> 
> thx!
> hofrat 

      parent reply	other threads:[~2017-04-17  8:26 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-17  7:52 How to get patches from e-mail client? Rock Lee
2017-04-17  8:02 ` Amit Kumar
2017-04-17  8:11   ` Amit Kumar
2017-04-17  8:16   ` Nicholas Mc Guire
2017-04-17  8:25     ` Rock Lee
2017-04-17  9:23       ` Amit Kumar
2017-04-17  8:26     ` Amit Kumar [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170417082605.GC3961@li620-105.members.linode.com \
    --to=free.amit.kumar@gmail.com \
    --cc=kernelnewbies@lists.kernelnewbies.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.