madskristensen / NpmTaskRunner

Visual Studio extension
Other
88 stars 32 forks source link

Task runner doesn't show up in the context menu nor in its window #43

Open SelaOAL opened 7 years ago

SelaOAL commented 7 years ago

Installed product versions

Description

I don't see the task runner explorer when right clicking the package.json.

Steps to recreate

Right click it and it isn't there. Also if I get to the task runner window from view>other windows, nothing is there. I think it isn't being bound to the project?

scottaddie commented 7 years ago

@SelaOAL The extension currently only supports a package.json file located in the root of the project. See issue https://github.com/madskristensen/NpmTaskRunner/issues/37 for more info. Is your package.json file located in the root of the project?

SelaOAL commented 7 years ago

Yes it's in the root, I tried on this project: https://github.com/Autodesk-Forge/forge-boilers.nodejs/tree/master/5%20-%20viewer%2Bserver%2Boss%2Bderivatives

scottaddie commented 7 years ago

Is there a ".njsproj" file that you're opening in VS 2015? If so, where is this on disk in relation to the actual project files?

SelaOAL commented 7 years ago

So I moved the solution and njsproj files to where the code was and now I see it in the conetext menu, but now it seems that there are errors when I run certain commands from there that don't happen if I run the same commands from the console.

(happens in the above project)

PS: is there a way to debug from running a script?

datumgeek commented 7 years ago

@scottaddie - please please please consider supporting package.json in sub-folders. i am using spa cli tools and want to keep all the spa contents in a sub-folder. the spa cli generates the package.json in the sub-folder also.

i can then use the spa cli to bundle the app (using webpack behind the scenes) and deposit the results in the wwwroot folder.

if the npm task runner context menu showed up in the package.json in the spa sub-folder, i wouldn't have to drop out to a bash shell to bundle the spa app :smile:

go badgers :wink: (class of 1987) 👴

scottaddie commented 7 years ago

@datumgeek The VS Web Team is aware of the limitation. As stated by Mads in issue 37, the core Task Runner Explorer code needs to be updated in order for this extension to support it. Unfortunately, that code isn't open source, so I cannot fix it.

@madskristensen This is undoubtedly the most requested feature I see, particularly when building SPAs. Any updates on whether this will be fixed by the team?

madskristensen commented 7 years ago

@scottaddie Yes, and it's high on our backlog

speedgoofy commented 7 years ago

Just checking up on this feature, any good news coming down the pipeline?

JohnYoungers commented 7 years ago

Also checking in: with the smaller/frequent updates in VS2017 I would think this subfolder issue should be something that could be resolved in a minor update

ElVisPL commented 6 years ago

No update about it?

lifeinchords commented 6 years ago

This is still broken.

ElVisPL commented 6 years ago

If you using grunt or other similar tools I suggest you this solution:

Create 'master' gruntfile in root (or equivalent for other tools) and run tasks from subdirectories from this master file

Fortunately for package.json there are nuget extensions that work for subdirectories

lifeinchords commented 6 years ago

Some thoughts:

I had this working when I first installed it yesterday. Today I resumed after checking in package.json and context menu item was gone.

I noticed this when I set up a gulp file, which showed up in Task Runner Explorer window, but didn't see the npm stuff. Looked at the Output tab, I realized I had 2 errors.

screen shot 2017-11-21 at 5 36 14 pm

After that, I did this sequence, best I remember:

Then, right clicking package.json showed the Task Explorer item

shrug

inyourspot commented 5 years ago

I had the same issue. Somehow the extension was disabled. I had to go into Tools->Extension Manger and Enable it.