
Security News
Scaling Socket from Zero to 10,000+ Organizations
Socket CEO Feross Aboukhadijeh shares lessons from scaling a developer security startup to 10,000+ organizations in this founder interview.
@unic/estatico-copy
Advanced tools
Copies files, optionally renames them.
$ npm install --save-dev @unic/estatico-copy
const gulp = require('gulp');
const env = require('minimist')(process.argv.slice(2));
/**
* Copy files
* Copies files, optionally renames them.
*
* Using `--watch` (or manually setting `env` to `{ watch: true }`) starts file watcher
* When combined with `--skipBuild`, the task will not run immediately but only after changes
*/
gulp.task('copy', () => {
const task = require('@unic/estatico-copy');
const instance = task({
src: [
'./src/**/*.{png,gif,jpg,woff,ttf}',
],
srcBase: './src',
dest: './dist',
watch: {
src: [
'./src/**/*.{png,gif,jpg,woff,ttf}',
],
name: 'copy',
},
}, env);
// Don't immediately run task when skipping build
if (env.watch && env.skipBuild) {
return instance;
}
return instance();
});
Run task (assuming the project's package.json specifies "scripts": { "gulp": "gulp" }):
$ npm run gulp copy
See possible flags specified above.
plugin(options, env) => taskFn
Type: Object
Default: null
Each property is passed to gulp.src, the key is used for the generated sprite's name.
Type: String
Default: null
Passed as base option to gulp.src.
Type: String
Default: null
Passed to gulp.dest.
Type: Object
Default: null
Passed to file watcher when --watch is used.
Type: Object
Type: Object
Default:
{
firstPass: true,
}
Passed to gulp-changed-in-place.
Type: Function
Default: null
Optional file renaming.
Type: { info: Function, debug: Function, error: Function }
Default: Instance of estatico-utils's Logger utility.
Set of logger utility functions used within the task.
Type: Object
Default: {}
Result from parsing CLI arguments via minimist, e.g. { dev: true, watch: true }.
Apache 2.0.
FAQs
Copies files, optionally renames them.
We found that @unic/estatico-copy demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Socket CEO Feross Aboukhadijeh shares lessons from scaling a developer security startup to 10,000+ organizations in this founder interview.

Research
Socket Threat Research maps a rare inside look at OtterCookie’s npm-Vercel-GitHub chain, adding 197 malicious packages and evidence of North Korean operators.

Research
Socket researchers identified a malicious Chrome extension that manipulates Raydium swaps to inject an undisclosed SOL transfer, quietly routing fees to an attacker wallet.