Universal Robots Forum

Best practice for source control

I would like to keep my UR program in version control system, e.g. git. How do I that?

When I create a program, I get 3 files.

  • urp - This is binary and not suitable for version control, cause I can not compare versions or merge differences
  • script - This would be best choice, probably. Two problems though. There are $ markers with line numbers which are changing. One line change changes all the other lines below. Second, major deal breaker, robot does not want to load them.
  • txt - This is also read only and only contains Program part.

Is there at least a command line to build urp from script and back?

Ok, I can uncompress urp to get xml file, but still that does not really help if I want to merge.


So basically .urp is single source of truth. It is a gzipped xml file. I wonder if I can merge the changes done in two separate files.

1 Like

The urp file is what you want. .script is interpreted version of .urp & installation file. Therefore a complete image is .urp & installation.

Best regards


Brent Bartson
Technical Support Manager, North America

Universal Robots USA, Inc.
5430 Data Court
Suite 300
Ann Arbor, MI 48108
United States

Phone: +1 844-462-6268 Ext. 1002
Cell: +1 734-660-1602


Please note that this message may contain confidential information. If you have received this message by mistake, please inform the sender of the mistake, then delete the message from your system without making, distributing or retaining any copies of it. Although we believe that the message and any attachments are free from viruses and other errors that might affect the computer or IT system where it is received and read, the recipient opens the message at his or her own risk. We assume no responsibility for any loss or damage arising from the receipt or use of this message.



Did you have any success with implementing source control? I too would like to use git.

My department really needs a better VCS, as things quickly can become a mess. I have an upcoming project where I’ll need to implement 16 different programs to work with 8 different customer parts.


Is there any effective way to manage the version of programs and installations on the controller? I can store programs in a repository or vault, but if another person introduces changes over time to the robot system, this can lead to some quality escapes.

My approach for version control is to use the urp Program only as a stub (which is never or almost never changing). And the real programming happens in scripts, which are “included” into this stub. Every program node can be expressed in a script (to see how: use that program node, “save all” and check the resulting script). To learn about the syntax, check the document “scriptManual.pdf”:

I understand, that graphical programming is easier, but I prefer to “write” my programs and to have them in a searchable, editor-editable and versionable format.

1 Like

That’s a helpful idea. I did something similar with an application in which I needed to vary the velocity and acceleration of a painting program. However, the debugging tools for scripts are not that developed. While I’m happy that the interpreter will show what line of a script file has a syntax error, it would also be nice to create a breakpoint or move the program pointer to a specific line to check a position or move.

From the related thread above, it appears you can uncompress the .urp and .installation file to get an xml file. You can also make edits to that xml file with a xml-friendly editor, and simply change the extension to .urp to load it back onto the UR robot. The only challenge here is Universal Robots hasn’t published the syntax, but it still seems promising to be able to compare both .urp and .installation files. The .variables file is already in text format.