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.

Stop output of subdirectories

See original GitHub issue

I have a directory structure with: icons/main/[svgs in here] icons/secondary/[svgs in here] icons/other/[svgs in here]

When I run svgr with:

npx @svgr/cli -d outputDir icons

then outputDir is filled with the main, secondary and other directories (each containing the new React components).

Is there an in-built way to add them all to the root of the output directory?

Issue Analytics

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

github_iconTop GitHub Comments

1reaction
gregbergecommented, Sep 19, 2021

Hello @Eli-Nathan, no unfortunately it is not possible. You have to flatten directory by yourself before running SVGR.

0reactions
gregbergecommented, Jan 29, 2022

This will not happen, I don’t want to deal with conflicts of a same filename in two directories.

Read more comments on GitHub >

github_iconTop Results From Across the Web

shell - Bash - Excluding subdirectories using the find command
Since there's now no output-producing or executing primary in the expression, it is evaluated as: ... Pruning all permission denied directories in find....
Read more >
Ask Question - Unix StackExchange
How can I suppress printing the full path to subdirectories when using CDPATH=".:/some/path"? ... causes cd SUBDIR to stop working if ./SUBDIR and ......
Read more >
Make du's output more useful with this neat trick - Red Hat
Sort your disk usage data in any order you want with these du command options.
Read more >
MS-DOS and Windows Command Line Dir Command
The dir command displays a list of files and subdirectories in a directory. ... Use /-C to disable the display of separator.
Read more >
xcopy | Microsoft Learn
Copies files and directories, including subdirectories. For examples of how to use this command, see Examples.
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