[JIRA] (JENKINS-38860) Git plugin using local config to update submodules

2016-11-23 Thread bdanilov...@preemptsecurity.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Boris Danilovich commented on  JENKINS-38860  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
  Re: Git plugin using local config to update submodules   
 

  
 
 
 
 

 
 You can run "git submodule deinit" on the repo on your jenkins.  
 

  
 
 
 
 

 
 
 

 
 
 Add Comment  
 

  
 

  
 
 
 
  
 

  
 
 
 
 

 
 This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)  
 
 

 
   
 

  
 

  
 

   





-- 
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[JIRA] (JENKINS-38860) Git plugin using local config to update submodules

2016-10-10 Thread bdanilov...@preemptsecurity.com (JIRA)
Title: Message Title


 
 
 
 

 
 
 

 
   
 Boris Danilovich created an issue  
 

  
 
 
 
 

 
 
  
 
 
 
 

 
 Jenkins /  JENKINS-38860  
 
 
  Git plugin using local config to update submodules   
 

  
 
 
 
 

 
Issue Type: 
  Bug  
 
 
Assignee: 
 Mark Waite  
 
 
Components: 
 git-plugin  
 
 
Created: 
 2016/Oct/10 12:55 PM  
 
 
Environment: 
 Jenkins v2.6, Git plugin version 3.0.0  
 
 
Priority: 
  Major  
 
 
Reporter: 
 Boris Danilovich  
 

  
 
 
 
 

 
 In order to get all of the submodules, the git plugin looks in the local configuration file: 

 

 > git config --get-regexp ^submodule # timeout=10
 > git config --get submodule.externals/jzmq.url # timeout=10
 > git submodule update --remote externals/jzmq
 > git config --get submodule.protobuf-java-format.url # timeout=10
 > git submodule update --remote protobuf-java-format
FATAL: Command "git submodule update --remote protobuf-java-format" returned status code 1:
stdout: 
stderr: error: pathspec 'protobuf-java-format' did not match any file(s) known to git.
 

 However, the .git/config file is local per repository, and old entries and sections do not get overriden. Therefore, when a submodule is no longer in use or has moved, the old configuration can cause an error. Anyway, the local configuration is not part of the remote repository, which is the correct clean repo which is the exclusive authority on git configs. A possible solution would be to call deninit in order to remove the old configuration.