# Creating a submodule and bringing history from the main project

2 messages from 2010-08-22 to 2010-08-23. Participants: Guillermo Gonzalez, Jens Lehmann.
Thread: https://gitlist.dev/t/24830

## Guillermo Gonzalez, 2010-08-22 17:24

Subject: Creating a submodule and bringing history from the main project
Message-ID: <AANLkTimoTN10EfeiE3Viim_x1Y3jRG89ANzRd69ah7jz@mail.gmail.com>
URL: https://gitlist.dev/e/AANLkTimoTN10EfeiE3Viim_x1Y3jRG89ANzRd69ah7jz%40mail.gmail.com
In-Reply-To: <AANLkTi=JWdp7ZneDpN5r4Zi4VaDfvW40QBZ-=sGx66O2@mail.gmail.com>

```
Hello!

I have a big project, currently using GIT,  and I wish to take some
sudirectories -or libraries- and put them in a separate repo (and
incorporate them via submodule support), so other commiters can have
access to a specific part of the project only.

Is it possible to somehow export the history of say lib/componentX
into a new repository componentX.git?

Thank you very much!

Guillermo

```

## Jens Lehmann, 2010-08-23 16:30

Subject: Re: Creating a submodule and bringing history from the main project
Message-ID: <4C72A23F.4030600@web.de>
URL: https://gitlist.dev/e/4C72A23F.4030600%40web.de
In-Reply-To: <AANLkTimoTN10EfeiE3Viim_x1Y3jRG89ANzRd69ah7jz@mail.gmail.com>

```
Am 22.08.2010 19:24, schrieb Guillermo Gonzalez:
> Is it possible to somehow export the history of say lib/componentX
> into a new repository componentX.git?

Sounds like you want to use "git filter-branch", see:
http://progit.org/book/ch6-4.html#making_a_subdirectory_the_new_root

```
