2012-02-21 5 views
1

При запуске Mercurial я получаю эту ошибку:Как установить мое имя пользователя в Mercurial?

[email protected]:gem5$ hg qnew my_p.diff 
abort: no username supplied (see "hg help config") 

hg help config говорит:

The configuration files use a simple ini-file format. A configuration file 
consists of sections, led by a "[section]" header and followed by "name = 
value" entries: 

    [ui] 
    username = Firstname Lastname <[email protected]> 
    verbose = True 

Но где же, что ини файл?

ответ

3

Если предположить, что на Linux, создать файл .hgrc в любом домашнем каталоге или в хранилище директории в вопросе,

dirunderhgcontrol/.hg/.hgrc

Добавить информацию (Ui, имя пользователя, многословный ...) вы заявили в ваш вопрос к новому файлу, а затем попробуйте.

5

hg help config

These files do not exist by default and you will have to create the appropriate configuration files yourself: global configuration like the username setting is typically put into "%USERPROFILE%\mercurial.ini" or "$HOME/.hgrc" and local configuration is put into the per-repository "/.hg/hgrc" file.

Смежные вопросы