electrode-confippet icon indicating copy to clipboard operation
electrode-confippet copied to clipboard

Windows support?

Open wmertens opened this issue 8 years ago • 1 comments
trafficstars

Sorry, not a windows user myself, but I know that you're supposed to use path.join or path.resolve to get valid paths on both Unix and Windows.

I'm thinking that maybe confippet could have a default function root which takes the remaining refs, resolves them, splits them on /, and then uses path.resolve(config.root || process.cwd, ...refs) to generate a valid path on all platforms? So you could e.g. specify paths as icons: '{{root:config.assets:-icons}}'?

I suppose some way to escape : and / in refs would also be necessary.

wmertens avatar Feb 10 '17 08:02 wmertens

I think if dealing with paths correctly on Unix and windows is required, confippet could just use path.normalize for anything that's meant to be a path, and internally keep everything as Unix paths.

jchip avatar Jun 07 '17 05:06 jchip