All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC] support git am in tools/libxfs-apply
@ 2020-05-09 16:39 Christoph Hellwig
  2020-05-09 16:44 ` Eric Sandeen
  0 siblings, 1 reply; 2+ messages in thread
From: Christoph Hellwig @ 2020-05-09 16:39 UTC (permalink / raw)
  To: sandeen; +Cc: linux-xfs

Here is my local hack for using git am in tools/libxfs-apply.  What
would be the best way to integrate it for real?

---
 tools/libxfs-apply | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/libxfs-apply b/tools/libxfs-apply
index deb9c225..923dc10f 100755
--- a/tools/libxfs-apply
+++ b/tools/libxfs-apply
@@ -396,7 +396,7 @@ apply_patch()
 		fi
 	else
 		echo "Applying with patch utility:"
-		patch -p1 < $_new_patch.2
+		git am -s $_new_patch.2
 		echo "Patch was applied in $REPO; check for rejects, etc"
 	fi
 
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [RFC] support git am in tools/libxfs-apply
  2020-05-09 16:39 [RFC] support git am in tools/libxfs-apply Christoph Hellwig
@ 2020-05-09 16:44 ` Eric Sandeen
  0 siblings, 0 replies; 2+ messages in thread
From: Eric Sandeen @ 2020-05-09 16:44 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: linux-xfs

On 5/9/20 11:39 AM, Christoph Hellwig wrote:
> Here is my local hack for using git am in tools/libxfs-apply.  What
> would be the best way to integrate it for real?

I only use the tool in a guilt environment so this "else" doesn't matter too
much to me.  :)

but I'm not sure who would ever want a bare "patch," since iterating over
libxfs commits would just pile patch upon patch, and IMHO git am makes much
more sense (other than the tight fuzz restrictions of git-am?)
 
so maybe this is the right solution, not a hack, other than also changing
the echoed messages as well.

-Eric

> ---
>  tools/libxfs-apply | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tools/libxfs-apply b/tools/libxfs-apply
> index deb9c225..923dc10f 100755
> --- a/tools/libxfs-apply
> +++ b/tools/libxfs-apply
> @@ -396,7 +396,7 @@ apply_patch()
>  		fi
>  	else
>  		echo "Applying with patch utility:"
> -		patch -p1 < $_new_patch.2
> +		git am -s $_new_patch.2
>  		echo "Patch was applied in $REPO; check for rejects, etc"
>  	fi
>  
> 

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-05-09 16:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-09 16:39 [RFC] support git am in tools/libxfs-apply Christoph Hellwig
2020-05-09 16:44 ` Eric Sandeen

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.