question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Copy multiple files

See original GitHub issue

Hi,

Did I miss something? It is not possible anymore to copy several files at once?

// Fonts
mix.copy([
    'node_modules/bootstrap-sass/assets/fonts',
    'node_modules/font-awesome/fonts/fontawesome-webfont.eot',
    'node_modules/font-awesome/fonts/fontawesome-webfont.svg',
    'node_modules/font-awesome/fonts/fontawesome-webfont.ttf',
    'node_modules/font-awesome/fonts/fontawesome-webfont.woff',
    'node_modules/font-awesome/fonts/fontawesome-webfont.woff2',
    'node_modules/font-awesome/fonts/FontAwesome.otf'
], 'public/fonts');
yarn run dev
yarn run v0.18.1
$ node node_modules/cross-env/bin/cross-env.js NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js
 95% emitting
 ERROR  Failed to compile with 1 errors

 error

Path must be a string. Received [ 'node_modules/bootstrap-sass/assets/fonts',
  'node_modules/font-awesome/fonts/fontawesome-webfont.eot',
  'node_modules/font-awesome/fonts/fontawesome-webfont.svg',
  'node_modules/font-awesome/fonts/fontawesome-webfont.ttf',
  'node_modules/font-awesome/fonts/fontawesome-webfont.woff',
  'node_modules/font-awesome/fonts/fontawesome-webfont.woff2',
  'node_modules/font-awesome/fonts/FontAwesome.otf' ]

                              Asset       Size  Chunks                    Chunk Names
  /js/admin.534d689a9bad56db9eb5.js     882 kB       0  [emitted]  [big]  /js/admin
/css/admin.8439a64d84663d9b78da.css    2.38 kB       0  [emitted]         /js/admin
                  mix-manifest.json  116 bytes          [emitted]
error Command failed with exit code 2.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

13reactions
JeffreyWaycommented, Feb 7, 2017

I didn’t realize that you could pass an array before. I’ve just pushed a commit to allow you to do:

mix.copy(['one.txt', 'two.txt'], 'output/path');
0reactions
jreancommented, Feb 8, 2017

Thank you @JeffreyWay !

Read more comments on GitHub >

github_iconTop Results From Across the Web

I want to copy multiple files and move them to a new folder ...
Select the multiple files as follows: Click one, then, while holding down the Ctrl key, click all the others, one at a time....
Read more >
The many ways to copy, move, or delete multiple files - PCWorld
The two-handed approach: Click one file. Then hold down Ctrl while you click each additional desired file. The one-handed approach: Point to a ......
Read more >
How to Select or Highlight Multiple Files and Folders
Select multiple files or folders grouped together · Click the first file or folder, and then press and hold Shift . · While...
Read more >
How to Select Multiple Files or Folders on a Windows Computer
How to Select Multiple Windows Files or Folders With the CTRL Key ... You can do a lot with a keyboard on your...
Read more >
How to Select, Copy and Paste, Delete, Rename ... - YouTube
Being able to select multiple files and folders is so helpful when you want to share, copy or even delete multiple files.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found