1

I am using microsoft rush to build a mono-repo. I have to build two projects - tools-common and tools-backend tools-backend depends on tools-common. rush rebuild works fine on the local machine. But on azure devops, it tries to first build tools-backend and it fails for not finding tools-common.

My questions are.

  1. Why rush on azure devops fails to detect the order?
  2. How can I ensure that it picks up tools-common before tools-backend ?
Amit Teli
  • 875
  • 11
  • 25
  • I solved it by adding `tools-common` in devDependencies as well. Earlier it was in peerDependencies only. It seems that rush does not try to resolve peerDependencies. So if we have a local project, we should add it both in dev and peer dependencies. Why it worked on my local machine was it held copy of tools-common dist from previous run. It would not work on local either when I totally purged and cleaned dist. This is what I have found. But any better explanation is welcome. – Amit Teli Nov 26 '20 at 02:15
  • 1
    Hi, Thanks for your sharing, you could convert your comment into an answer, it could help other community members who get the same issues. Thanks. – Vito Liu Nov 26 '20 at 05:55

1 Answers1

0

I solved it by adding tools-common in devDependencies as well. Earlier it was in peerDependencies only. It seems that rush does not try to resolve peerDependencies. So if we have a local project, we should add it both in dev and peer dependencies.

Why it worked on my local machine was it held copy of tools-common dist from previous run. It would not work on local either This is what I have found. But any better explanation is welcome.

Amit Teli
  • 875
  • 11
  • 25