Git export/import commits history

0 votes
we have one big git repo, which includes 3 folders for different projects:

Existing repo consists of - .net_newrepo, java_newrepo, android_newrepo

New project should contain history only about particular project. .net about .net, and not about ios and android etc.
Jul 12, 2018 in Git & GitHub by Nilesh
• 6,880 points
163 views

1 answer to this question.

0 votes

This should work

$ cd dotnet_newrepo
$ git filter-branch --subdirectory-filter dotnet_is_dir -- --all
$ cd ..
$ cd java_newrepo
$ git filter-branch --subdirectory-filter java_is_dir -- --all
$ cd ..
$ cd android_newrepo
$ git filter-branch --subdirectory-filter android_is_dir -- --all
$ cd ..
answered Jul 12, 2018 by Kalgi
• 2,620 points

edited Jul 12, 2018 by Kalgi

Related Questions In Git & GitHub

0 votes
1 answer
0 votes
1 answer

Git origin not found

For this to work, you need to ...READ MORE

answered Apr 25, 2018 in Git & GitHub by DragonLord999
• 8,380 points
149 views
0 votes
1 answer

Configure Git and GitHub

In version control with Git, we deal ...READ MORE

answered Apr 26, 2018 in Git & GitHub by DragonLord999
• 8,380 points
30 views
0 votes
1 answer

Git pull vs Git Fetch

The objective of both these commands is ...READ MORE

answered Apr 26, 2018 in Git & GitHub by DragonLord999
• 8,380 points
249 views
0 votes
1 answer

Git & GitHub

Even though their names sound the same, ...READ MORE

answered Apr 26, 2018 in Git & GitHub by DragonLord999
• 8,380 points
23 views
+1 vote
2 answers

Git Commands

This command basically adds all your changes ...READ MORE

answered Aug 14, 2018 in Git & GitHub by Kalgi
• 40,440 points
60 views
+13 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 26, 2018 in DevOps & Agile by DragonLord999
• 8,380 points
147 views
0 votes
1 answer