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

version 1.2.1 doesn't work on windows platform #6

Open
Mavrin opened this issue Sep 15, 2016 · 3 comments
Open

version 1.2.1 doesn't work on windows platform #6

Mavrin opened this issue Sep 15, 2016 · 3 comments
Labels

Comments

@Mavrin
Copy link
Contributor

Mavrin commented Sep 15, 2016

image
Looks like this commit broke 25644fb

@lahmatiy
Copy link
Owner

@Mavrin Could you fix it? Since I don't use express-open-in-editor currently. The changes was made according to #5

@lahmatiy lahmatiy added the bug label Sep 15, 2016
@Mavrin
Copy link
Contributor Author

Mavrin commented Sep 17, 2016

In version 1.2.1
from query string
c:/project/editor/field.jsx:51:13:90:6
after resolve name and apply replace
\project\editor\field.jsx:51:13:90:6
In version 1.2.0
from query string
c:/project/editor/field.jsx:51:13:90:6
after resolve name and apply replace
c:\project\editor\field.jsx:51:13:90:6
I don't know what i should fix. I can't understand why we should cut drive for window platform.

@lahmatiy
Copy link
Owner

lahmatiy commented Sep 20, 2016

Middleware recieves an absolute path to host, but relative path to cwd. We need keep path relative, but normalize it - that's why path.resolve('/', filename) is using.
But on windows platform path.resolve() adds drive that's not desired behaviour since cwd will be added by opener.

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

No branches or pull requests

2 participants