schickling/chromeless

Windows Build Compatibility

Open

#70 geöffnet am 28. Juli 2017

Auf GitHub ansehen
 (5 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)TypeScript (13.240 Stars) (606 Forks)batch import
APIProxyhelp wanted

Beschreibung

I found a couple issues while trying to build this on Windows.

  1. For "npm run build" --> "rm -rf dist; tsc -d"

    • "rm -rf dist;" doesn't make sense on windows since the rm command doesn't exist. The command to remove a directory in windows is "rmdir"
    • I'm open to suggestions on how to solve this one, my only thought is to have 2 different build scripts (one for windows and one for mac/linux)
  2. https://github.com/graphcool/chromeless/blob/master/src/chrome/local-runtime.ts#L204-L205

    • This line sets the tmp directory as "/tmp". On windows this refers to "C:/tmp". I think we should change this line to refer to just "tmp/" so that it refers to a tmp folder inside the current directory.
    • Also, fs.writeFileSync() assumes the tmp folder exists, I think we need code in here to check for the folder and add the folder if it doesn't exist.

Once we have solid solutions to these 2 things, I can implement a PR.

Contributor Guide