Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

folder hierarchy not preserved (again) #45

Closed
lingtalfi opened this issue May 1, 2020 · 2 comments
Closed

folder hierarchy not preserved (again) #45

lingtalfi opened this issue May 1, 2020 · 2 comments

Comments

@lingtalfi
Copy link

Hi, I know this has been asked before but I couldn't find a solution.
I have this folder structure:

- /myapp/src/assets/
----- file1.svg
----- icons/
--------- icon1.svg
--------- icon2.svg

And when I use the plugin like this:

		copy({
			targets: [
				{
					src: 'src/assets/**/*',
					dest: 'public/build/assets',
					flatten: true,
				},
			]
		}),

I expect to have this:

- /myapp/public/build/assets/
----- file1.svg
----- icons/
--------- icon1.svg
--------- icon2.svg

But instead I have this:

- /myapp/public/build/assets/
----- file1.svg
----- icon1.svg
----- icon2.svg
----- icons/
--------- icon1.svg
--------- icon2.svg

Is that a bug? If not, what did I miss?

@vladshcherbin
Copy link
Owner

@lingtalfi hey, won't this work?

copy({
  targets: [{
    src: 'src/assets/*',
    dest: 'public/build/assets'
  }]
})

@lingtalfi
Copy link
Author

it worked. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants