From mboxrd@z Thu Jan 1 00:00:00 1970 From: free.amit.kumar@gmail.com (Amit Kumar) Date: Mon, 17 Apr 2017 08:02:32 +0000 Subject: How to get patches from e-mail client? In-Reply-To: References: Message-ID: <20170417080232.GA3961@li620-105.members.linode.com> To: kernelnewbies@lists.kernelnewbies.org List-Id: kernelnewbies.lists.kernelnewbies.org 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. Regards, Amit Kumar > > -- > Cheers, > Rock > > _______________________________________________ > Kernelnewbies mailing list > Kernelnewbies at kernelnewbies.org > https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies