jycouet / VSTSExtensions

MIT License
30 stars 11 forks source link

Could not find globally installed yarn #28

Closed ColinKrist closed 3 years ago

ColinKrist commented 4 years ago

tried workaround - https://github.com/jycouet/VSTSExtensions/issues/16 didn't work. Is yarn supported?

image

image

elwynelwyn commented 4 years ago

I notice the src has changed to not use yarn global at all, and force npx for the running of the tool: https://github.com/jycouet/VSTSExtensions/blob/master/renovateMe/buildtask/src/index.ts#L46

However in my own pipeline it is still running yarn global add (I still have the fix from #16 in place so it is working fine for me). I wonder if a new version of the task needs to be published so we can force our pipelines to use the npx version? @jycouet are you able to check please if the published task matches the latest source code?

jycouet commented 4 years ago

Yes, the source here is synchronized with what is published. The task should use npx now to get the renovate tool.

But inside renovate it's still using npm or yarn.

elwynelwyn commented 4 years ago

Here's logs from my pipeline - it's running task version 0.1.0 and still using the yarn global:

2020-03-09T18:31:41.9080472Z ##[section]Starting: Renovate
2020-03-09T18:31:41.9089092Z ==============================================================================
2020-03-09T18:31:41.9089521Z Task         : Renovate Me
2020-03-09T18:31:41.9089870Z Description  : Renovate your libs on your selected VSTS repo
2020-03-09T18:31:41.9090466Z Version      : 0.1.0
2020-03-09T18:31:41.9090728Z Author       : Jean-Yves COUET
2020-03-09T18:31:41.9091334Z Help         : [Renovate Me](https://marketplace.visualstudio.com/items?itemName=jyc.vsts-extensions-renovate-me) based on [renovate](https://github.com/singapore/renovate)
2020-03-09T18:31:41.9092197Z ==============================================================================
2020-03-09T18:31:42.0567993Z [command]/usr/bin/yarn global add renovate@latest
2020-03-09T18:31:42.2299163Z yarn global v1.22.0
2020-03-09T18:31:42.3032804Z [1/4] Resolving packages...
2020-03-09T18:31:43.5198643Z warning renovate > npm > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
2020-03-09T18:31:43.5200515Z warning renovate > npm > node-gyp > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
2020-03-09T18:31:44.4552861Z [2/4] Fetching packages...
2020-03-09T18:31:55.3236237Z [3/4] Linking dependencies...
2020-03-09T18:32:03.0147402Z [4/4] Building fresh packages...
2020-03-09T18:33:04.4263145Z success Installed "renovate@19.165.0" with binaries:
2020-03-09T18:33:04.4266260Z       - renovate
2020-03-09T18:33:04.4267562Z       - renovate-config-validator
2020-03-09T18:33:04.4306613Z Done in 82.21s.
2020-03-09T18:33:04.4537996Z [command]/home/vsts/.yarn/bin/renovate MyOrg/MyRepo --platform azure --endpoint https://myorg.visualstudio.com/ --token *** --require-config true --log-level info --host-rules=[{"domainName":"github.com","token":"***"}]
2020-03-09T18:33:05.6955459Z  INFO: Repository started (repository=MyOrg/MyRepo)
...snip

Any suggestions for getting myself onto the newer version of the task?

jycouet commented 4 years ago

That's really strange @elwynelwyn. On the marketplace it's 0.3.10 Did you try to uninstall and install it again?