Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 542293
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T10:25:53+00:00 2026-05-13T10:25:53+00:00

How do you manage common library source in a DVCS? Currently, my team uses

  • 0

How do you manage common library source in a DVCS?

Currently, my team uses Perforce to manage our software projects. Using Perforce’s “Workspace Mapping” feature, I am able to easily map common library source into dev application directories in a way that keeps the transformation between source management and dev project work transparent. For example, the Repository looks something like this:


SCM TREE STRUCTURE

  • root
    • apps
      • ForumSite
      • AdminTool
    • common
      • event.logger
      • json.parser
    • db
      • Users
      • SiteConfiguration

Due to the nifty P4 mapping feature, our developers can pull a complete set of source for the projects they work on in the form that makes the most sense using a workspace map. A typical dev project folder might look something like this:


DEV PROJECT FOLDER

/projects
    /FALL-2009
        /ForumSite
            /deps
                /event.logger
                /json.parser
        /AdminTool
            /deps
                /event.logger
                /json.parser
        /Users-db
        /SiteConfiguration-db
    /FALL-2009-PATCH-01
        /json.parser
        /SiteConfiguration-db
    /FALL-2009-PATCH-02
        /AdminTool
            /deps
                /event.logger
                /json.parser
        /SiteConfiguration-db

When a dev edits source in any of his/her components or applications, the changes are mapped back to the right source control directory at the right version point. This is transparent to the dev, reducing the complexity of management and time to set up new projects.

I’m researching Git, Bazaar and Mercurial as potential alternatives to Perforce. Can anyone provide insight into how common component source is handled in the DVCS world?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T10:25:53+00:00Added an answer on May 13, 2026 at 10:25 am

    In Git, you would use git submodule for this purpose.

    Git submodules are stored as references to a revision from another repository, along with a file providing a URL to find the other repository. When you perform a git submodule update, Git will clone a copy of the referenced repository (or you can configure it to point to a different copy of the same repository at a different URL, as it is a DVCS and so any clone of a repository that contains the referenced revision will also work), and then check out the referenced revision.

    Sadly, it is not as seamless as one might wish. Checking out a new revision in the parent repository does not actually check out the submodule; you need to do an explicit git submodule update to accomplish this. We have tried wrapping git pull; git submodule update as a single command, but there are a lot of other commands (such as git rebase) that involve checking out files which can get you into a confusing state because they don’t update the submodules as well. Once you get familiar with how submodules work, it will all work out, but it provides a bit of friction.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Our team is looking at using Team Foundation Server v.11 (2012) to manage our
A continual sticking point for my team has been our Common library. (Looking at
I'm using Eclipse to manage my Android project, which uses Amazon's Android libraries for
I manage a CakePHP 1.1 CMS website, and our hosts just upgraded PHP to
I'm developing a common library (external jar) that is being provided to different developers
For example, I need to generate a shared library, libXXX.so. What's the common way
What are common alternatives to using the Tomcat (or Websphere) container-managed security? I have
I manage my websites with ISPConfig 3.0.4. This is a great tool but I
class Manage { spl_autoload_register(function($class) { include $class . '.class.php'; }); } Say I have
I manage to identify duplicate records from two different databases: select * from taskperformance

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.