0

I'm a bit confused with git/azure/shared libraries and not found any clear guidance online either, it's a moving goal post it seems.

I'm used to having a solution with multiple projects in. Some of those are class libraries shared among a number of other solutions. I do need to change the code in these libraries. Sourcesafe/Team Server works fine for that.

I need to move to Azure Repo and git and i'm struggling to work out an approach.

Do i have different repos for each shared project?

In Repos are these separate projects or one project with separate repos.

How do i go about using different sources for different projects within a single solution?

If anyone can point me to any reference or examples, that would be great!

thanks Paul

paulinventome
  • 1,047
  • 2
  • 10
  • 11

1 Answers1

0

Some of those are class libraries shared among a number of other solutions. I do need to change the code in these libraries.

and

Do i have different repos for each shared project?

  • In this case, the generally recommended solution is indeed to create a repository for each shared library and publish nuget packages that will be consumed by your multiple solutions.

  • Another solution is to use submodules but that would add some burden, so I don't think it's a good solution.

  • A last solution is to do what is called monorepo where all is in the same repository. But it is doable only if you update all the shared libraries in the same time in all the projects and if you are the maintainer of all the shared libraries. And also if everyone have the rights on all the source codes.

There are surely other solutions more or less recommended like using git subtree, ...

You have to gather information and decide yourself what is the better for you and perhaps change the way to do in the future (continuous improvement!?!)

Philippe
  • 28,207
  • 6
  • 54
  • 78