import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.Path;
+import org.eclipse.jgit.storage.file.FileRepository;
import org.tizen.common.util.DialogUtil;
import org.tizen.nativeappcommon.wizards.TizenProjectWizard;
TizenPlatformTemplateModel selectedTemplate = ((TizenPlatformMainWizardPage)fMainPage).getLastSelectedTemplate();
GitDescription desc = selectedTemplate.getDesc();
+ String sshConn = PreferencesManager.getActiveGitBaseURI();
+ GitCommander commander = new GitCommander(sshConn);
if (desc != null) {
// this is git project
IPath gitPath = new Path(selectedTemplate.getDesc().getProject());
- String sshConn = PreferencesManager.getActiveGitBaseURI();
- GitCommander commander = new GitCommander(sshConn);
// cloning git project
try {
if (!commander.CloneOperation(projectPath, gitPath, getContainer())) {
commander.ApplySharedProject(newProject, getContainer());
}
else {
+
result = super.performFinish();
+
+ try {
+ FileRepository gitRepos = new FileRepository(newProject.getLocation().toString()+"/.git");
+ gitRepos.create();
+ } catch (IOException e) {
+ DialogUtil.openMessageDialog("Warning: Converting the project to Git failed!");
+ }
+ commander.ApplySharedProject(newProject, getContainer());
}
return result;