Skip to content
This repository has been archived by the owner on Nov 7, 2023. It is now read-only.
/ gulp-apply-patch Public archive

Gulp plugin to patch files using unified diffs.

Notifications You must be signed in to change notification settings

kaa/gulp-apply-patch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Note

This project is no longer maintained

gulp-apply-patch

Patch files using unified diffs as part of a gulp build process.

Usage

Install gulp-apply-patch using npm as a development dependency:

npm install --save-dev gulp-apply-patch

In your gulpfile.js use it in a task as follows.

var applyPatch  = require('gulp-apply-patch');

gulp.task('patch', function() {
  gulp.src('vnd/**/*.js')
    .pipe(patch("patches/*.patch"))
    .pipe(gulp.dest('out'));
});

Reference

applyPath(patches, options)

Take one or more unified diffs and applies those in order to the piped files, when ever the relative path of the piped file matches the path of the diff.

patches

Type: String | Array

Either a path string or glob string that will be used to load patch files from disk, or an array of raw unified diffs.

options

Type: Object

options.replaceCLRLF

Type: Boolean
Default: false

Replace \r\n with \n for Windows compatibility.

About

Gulp plugin to patch files using unified diffs.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published