Вопрос

What is the right way to organize ssh access to sub-repositories in mercurial? Consider the following situation:

master
|--.hgsub
|--slave1
|--slave2 

And .hgsub:

slave1 = ssh://user@host://var/local/repos/slave1
slave1 = ssh://user@host://var/local/repos/slave2

The problem is that .hgsub is the part of the repository thus it is not possible (or is it?) to store various usernames in the ssh addresses of the repos. And I really want to avoid using a "global" user to access the repositories just because of this.

Это было полезно?

Решение

You have basically two choices:

  1. If your subrepositories live in the same server as the container, use relative paths. This is the most convenient solution.
  2. Otherwise, you can have each user define a subpath rule. Look for the subpath word in this document.
Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top