zfsonlinux/zfs — pull request #1679 by prakashsurya (2013-08-26 16:38:32+00:00)
Title: Add script to fix file names in upstream patches

Added a simple perl script to do a search and replace on the Illumos
ZFS file names and replace them with the ZFS on Linux equivalent.

Would a script like this be useful? Currently it only fixes up the file
names found in upstream patches to use the ZFS on Linux file names.
Before I spend any more time adding all of the possible upstream files,
I wanted to see if a script like this would be useful enough to land?

I've only used it on patches created by `git format-patch -k` on the
upstream illumos-gate tree, but there's no reason it can't be updated to
work with patches created by `diff`.

Example usage:
```
$ ./scripts/zfs2zol-patch.pl < 0001-3537-want-pool-io-kstats.patch > 0001-3537-want-pool-io-kstats.patch.linux
$ patch -p1 < 0001-3537-want-pool-io-kstats.patch.linux
```