Aki Kanerva Posted March 25, 2020 Report Share Posted March 25, 2020 Hi there, New user here, trying to figure out how to migrate an existing Git repo into Plastic Cloud. This is just a one-time operation, I don't need to sync anything with Git after the initial import. I have a local Git repo in bare format, exported with the git clone --mirror command. How do I use this package as the basis of a new Plastic Cloud repo? Thanks in advance! Link to comment Share on other sites More sharing options...
calbzam Posted March 26, 2020 Report Share Posted March 26, 2020 Hi Aki, There are different possibilities to import a git repo to Plastic: https://www.plasticscm.com/features/plasticscm-for-git-users - You can create a git fast-export package of your repo and then this package can me imported into Plastic. - You can use GitSinc. In order to use this option, your git repo should be located on a Git server. Regards, Carlos. 1 Link to comment Share on other sites More sharing options...
Aki Kanerva Posted March 26, 2020 Author Report Share Posted March 26, 2020 Thanks Carlos! Still need some further assistance though. Following the example in the help page for fast-export, I exported the bare repo using the following command (took about an hour and a half): git fast-export --all -M --signed-tags=strip --tag-of-filtered-object=drop > export.dat Then I tried using this command to import it: cm fast-import PlasticRepoName ..\GitRepo.git\export.dat And received this output: ]uldn't process command [??b l o b ]ror: Couldn't process command [??b l o b Link to comment Share on other sites More sharing options...
Aki Kanerva Posted March 26, 2020 Author Report Share Posted March 26, 2020 In case this is relevant, I'm on Windows 10. Link to comment Share on other sites More sharing options...
Aki Kanerva Posted March 26, 2020 Author Report Share Posted March 26, 2020 Ah, I figured it out! I changed from PowerShell to Command Prompt, and things started working. Git produced the export in a matter of minutes, and the file size was a little less than half of what was generated when using Powershell. I'm guessing PowerShell insisted on using UTF-8 encoding or something weird. Link to comment Share on other sites More sharing options...
calbzam Posted March 27, 2020 Report Share Posted March 27, 2020 Thanks for the update! Carlos. Link to comment Share on other sites More sharing options...
lrg_steven Posted June 1, 2022 Report Share Posted June 1, 2022 I'm glad that I saw this post. PowerShell messes up git exports so badly, it should probably be noted in the docs. The only time I've ever done a git export was for this. I thought it was weird that the PowerShell export took hours and produced a ~50GB file for an ~30GB repo. Doing everything on the normal command prompt produced a ~30GB file in less than a minute and I don't get that weird "]uldn't process command [??b l o b" error when importing. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now