Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Perforce & Jenkins change comments encoding spoiled

We have Perforce for source control and Jenkins for Continuous Integration. They are integrated using JENKINS Perforce Plugin. Eclipse IDE with P4Eclipse (the Perforce Plug-in for Eclipse) for developing/committing.

There problem is that changes comments (usually wrote in Chinese) get spoiled. (Sources with Chinese comments are compiled without this problem.)

What is the reason? How to fix?

Where Perforce Server and JENKINS plugin encoding is set?

Change comments are spoiled

UPDATE August 2014

While browsing /jenkins/systemInfo page of Jenkins I noticed that property file.encoding had value CP1252 (see Windows-1252) as that Jenkins was running on Windows. Because that properties are actually properties of Tomcat, we set up UTF-8 using one of option inside Change Tomcat's Charset.defaultCharset in windows . After Tomcat restart we got file.encoding UTF8, but it did not solved the problem.

Once again, Sources are in UTF-8 and they have no problem after arriving on Jenkins server. It is about commits comments.

UPDATE 2:

It is not browser related as comments within Java code are shown correctly.
We took closer look and found that Jenkins stores changes comments in xml file per every job. And in that file encoding is already spoiled.

like image 481
Paul Verest Avatar asked Dec 03 '12 06:12

Paul Verest


People also ask

What is Perforce used for?

Perforce Software is a leading provider of development and DevOps solutions. This includes the original Perforce version management system, now called Helix Core, as well as dynamic development, intelligent testing, risk management, and boundaryless collaboration solutions.

Is Perforce still used?

Today it is popular among professional teams of all scales, from indie developers to large enterprises, as well as critical open source projects such as Android and the Linux kernel. Yet Perforce, a commercial centralized SCM system, still resonates with game developers and other subsets of software developers.

Is Perforce any good?

Perforce is great for managing a large scale codebase with a fairly large engineering team. It is fast, powerful, and has solid security features to lockdown specific branches. Perforce is best suited for established software companies with the resources to set up and maintain a Perforce server.

What is the difference between Perforce and Git?

One of the key differences between these two systems is that Git is based on a distributed, decentralised model, while Perforce is centralised. Both have their advantages, of course, but with a centralised system, there's no way to decentralise it later. A distributed VCS, on the other hand, can be centralised.


1 Answers

Have you tried changing the page-encoding on the browser itself?

Depends on the browser, but on Firefox, you would click View -> Character Encoding -> Chinese

like image 91
Slav Avatar answered Sep 25 '22 14:09

Slav