I run truffle init webpack, and it installs and runs fine.
But immediately when I then do truffle compile, I get this error.
Line 2
Char 1
Object Expected
800A138F
Microsoft Jscript runtime error
Infact if I try truffle (anything), I get the error.
If I check the truffle.js file, its referring to this line.
require('babel-register')
I've run npm-install to make sure I had this file
Still get the error.
Any ideas?
Solved: Just incase anyone has this same issue. It was the fact that its trying to run truffle.js in that directory, instead of actually running truffle.cmd.
So you need to find your truffle.cmd file, and rename it to something else. Like truf.cmd
I found mine in
\Users\AppData\Roaming\npm\truffle.cmd
Now you can do
truf init
truf compile
truf migrate
etc
@holoverse You can also run like this:
truffle.cmd compile
Most helpful comment
Solved: Just incase anyone has this same issue. It was the fact that its trying to run truffle.js in that directory, instead of actually running truffle.cmd.
So you need to find your truffle.cmd file, and rename it to something else. Like truf.cmd
I found mine in
\Users\AppData\Roaming\npm\truffle.cmd
Now you can do
truf init
truf compile
truf migrate
etc