annotate mercurial-common/src/jetbrains/buildServer/buildTriggers/vcs/mercurial/Constants.java @ 379:55c2c88a2d82 Eluru-6.5.x

TW-17630, TW-18815 fix encoding for hg log command Mercurial stores commit messages in UTF-8. During commit it tries to guess a system encoding and transcode message from system encoding to UTF-8. When it prints to output it transcodes from UTF-8 to the system encoding and replace characters which cannot be represented in the system encoding with the symbol of '?'. Default console encoding on windows is cp437, and it cannot represent non-latin symbols, see http://mercurial.selenic.com/wiki/CharacterEncodingOnWindows for details. The fix is to not use a console to run hg, and tell mercurial to do the output in UTF-8.
author Dmitry Neverov <dmitry.neverov@jetbrains.com>
date Wed, 15 Feb 2012 12:07:12 +0400
parents 0ce0e78bf21d
children 643fa1236f4e
rev   line source
27
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
1 /*
160
5198b02fc5e9 Update copyrights
Dmitry Neverov <dmitry.neverov@jetbrains.com>
parents: 116
diff changeset
2 * Copyright 2000-2011 JetBrains s.r.o.
27
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
3 *
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
4 * Licensed under the Apache License, Version 2.0 (the "License");
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
5 * you may not use this file except in compliance with the License.
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
6 * You may obtain a copy of the License at
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
7 *
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
8 * http://www.apache.org/licenses/LICENSE-2.0
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
9 *
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
10 * Unless required by applicable law or agreed to in writing, software
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
11 * distributed under the License is distributed on an "AS IS" BASIS,
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
13 * See the License for the specific language governing permissions and
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
14 * limitations under the License.
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
15 */
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
16 package jetbrains.buildServer.buildTriggers.vcs.mercurial;
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
17
45
4059fcc5473e ask for credentials on mercurial settings page
Pavel.Sher
parents: 44
diff changeset
18 import jetbrains.buildServer.vcs.VcsRoot;
4059fcc5473e ask for credentials on mercurial settings page
Pavel.Sher
parents: 44
diff changeset
19
27
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
20 public interface Constants {
28
a7cab5083ada libraries moved on top level, dummy implementation of agent side checkout interface
Pavel.Sher
parents: 27
diff changeset
21 String VCS_NAME = "mercurial";
27
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
22 String REPOSITORY_PROP = "repositoryPath";
57
99e757f2527b branches support
Pavel.Sher
parents: 45
diff changeset
23 String BRANCH_NAME_PROP = "branchName";
27
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
24 String HG_COMMAND_PATH_PROP = "hgCommandPath";
116
1c7e94c0ad2f Add ability to use mercurial installed on the system.
Dmitry Neverov <dmitry.neverov@jetbrains.com>
parents: 95
diff changeset
25 String HG_PATH_ENV = "TEAMCITY_HG_PATH";
62
b328c6b6526d TW-5636: Mercurial plugin can easilly hit Windows MAX_PATH limitations
Pavel.Sher
parents: 57
diff changeset
26 String SERVER_CLONE_PATH_PROP = "serverClonePath";
45
4059fcc5473e ask for credentials on mercurial settings page
Pavel.Sher
parents: 44
diff changeset
27 String USERNAME = "username";
4059fcc5473e ask for credentials on mercurial settings page
Pavel.Sher
parents: 44
diff changeset
28 String PASSWORD = VcsRoot.SECURE_PROPERTY_PREFIX + "password";
167
0ce0e78bf21d Add constant for uncompressed transfer
Dmitry Neverov <dmitry.neverov@jetbrains.com>
parents: 160
diff changeset
29 String UNCOMPRESSED_TRANSFER = "uncompressedTransfer";
27
7944e8985ebd prepare modules structure for agent side checkout
Pavel.Sher
parents:
diff changeset
30 }