0
votes

I'm using the cache task in my Azure Devops build pipeline cause I want to cache my NPM packages so they don't have to be downloaded every time I run the build.

enter image description here

To cache the node_modules folder of my solution should I use $(System.DefaultWorkingDirectory)/node_modules or just node_modules in the path input ?

1

1 Answers

1
votes

If you want to cache npm's node_modules, then the value of path should be $(Pipeline.Workspace)/.npm/lib/node_modules.

You can click this document for detailed information.