0

I want to execute a command to perforce server from java application, but there is no API support adding global value

  • Command to get all files from specific workspace p4 -c P4CLIENT files //P4CLIENT/...@123456
  • Current solution to execute a p4 cmd WITHOUT global value as below:
IOptionsServer server = ServerFactory.getOptionsServer(uri, defaultProps);
server.connect();
server.setUserName(username);
server.login(password);

server.execMapCmd(String string, String[] strings, Map<String, Object> map) 

Is there anyway or other API can usse option -c P4CLIENT?

Cuong Nguyen
  • 85
  • 1
  • 10
  • Global options are implemented by the client, not the server. The various client APIs all have API functions that implement the features provided by global options in the CLI -- in this case `setUserName` takes the place of the `-u` global option. – Samwise Feb 10 '23 at 14:37

0 Answers0