jayfella c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
..
.circleci c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
example c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
lib c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
node_modules c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
test c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
.eslintrc c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
.prettierrc c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
CHANGELOG.md c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
LICENSE c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
README.md c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
index.js c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos
package.json c97084e992 Initial Commit %!s(int64=5) %!d(string=hai) anos

README.md

npm version build status

gulp-copy

Copy source files to new destination and use that destination as new source (for further piping). Automatically creates needed folders before proceeding. Ability to remove 'prefixes' from path.

Most likely you don't need this package for your gulp pipeline, a lot can be accomplished with just gulp.dest. A reason to use this package would be to keep some depth (prefix options).

Usage

// gulpfile.js

var gulpCopy = require('gulp-copy');
var otherGulpFunction = require('gulp-other-function');
var sourceFiles = ['source1/*', 'source2/*.txt'];
var destination = 'dest/';
var outputPath = 'some-other-dest/';

return gulp
    .src(sourceFiles)
    .pipe(gulpCopy(outputPath, options))
    .pipe(otherGulpFunction())
    .dest(destination);

Options

prefix: integer, defining how many parts of the path (separated by /) should be removed from the original path

Example

A simple implemention of a gulpfile using gulp-copy is available in the example folder. You can run gulp or npx gulp from within the folder.

Updates

See changelog for all updates.