Documentation

Support

Unity Version Control

server.conf variables

Configure server variables for triggers in Unity Version Control.
Read time 1 minuteLast updated 21 days ago

You can define variables in the
server.conf
file. Their value passes on to the trigger script or program as environment variables. To define these variables, you need to add a section called
TriggerVariables
to the
server.conf
file, which you can find in the server installation folder. The following example shows one way you can use this file:
<?xml version="1.0"?><ServerConfigData> <Language>en</Language> <WorkingMode>UPWorkingMode</WorkingMode> <ServerType>ServerTypeAll</ServerType> <TriggerVariables> <TriggerVariable name="TRIGGERS_PATH" value="c:\triggers" /> </TriggerVariables></ServerConfigData>
This sample defines a variable called
TRIGGERS_PATH
with the value
c:\\triggers
. For example, you can use this variable in the script field when you create a trigger:
cm trigger create before-checkin "code checker" "@TRIGGERS_PATH\stylecheck.bat"