# Help with GIT submodules

**URL:** <https://forum.getkirby.com/t/help-with-git-submodules/1488>\
**Category:** Questions\
**Tags:** v2\
**Created:** [June 29, 2015, 9:40pm UTC](https://forum.getkirby.com/t/help-with-git-submodules/1488 "2015-06-29T21:40:12Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![louiswalch](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/louiswalch/32/3819_2.png) [@louiswalch](https://forum.getkirby.com/u/louiswalch)\
**Post date:** [June 29, 2015, 9:40pm UTC](https://forum.getkirby.com/t/help-with-git-submodules/1488/1 "2015-06-29T21:40:12Z")

</div>

I have a Kirby project housed in a GIT repo on my local computer. This contains submodules for both Kirby core and Panel as suggested by [this article](http://getkirby.com/blog/working-with-git). I just pushed it to GitHub, then went onto my server and pulled down the repo. The ‘panel’ and ‘kirby’ folders are present, but empty.

Tried this via remote server, and it didn’t help.

```
git submodule foreach --recursive git checkout master
git submodule foreach --recursive git pull

```

My .gitmodules file includes:

```
[submodule "kirby"]
    path = kirby
    url = https://github.com/getkirby/kirby.git
[submodule "panel"]
    path = panel
    url = https://github.com/getkirby/panel.git

```

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [June 29, 2015, 9:47pm UTC](https://forum.getkirby.com/t/help-with-git-submodules/1488/2 "2015-06-29T21:47:12Z")

</div>

What you need to do:

```auto
git submodule init
git submodule update

```

---

<div class="post-metadata">

**Author:** ![louiswalch](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/louiswalch/32/3819_2.png) [@louiswalch](https://forum.getkirby.com/u/louiswalch)\
**Post date:** [June 29, 2015, 9:50pm UTC](https://forum.getkirby.com/t/help-with-git-submodules/1488/3 "2015-06-29T21:50:30Z")

</div>

I get this error:

```
No submodule mapping found in .gitmodules for path 'deploy/kirby'

```

> [@texnixe](#):
>
> git submodule init

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [June 29, 2015, 10:04pm UTC](https://forum.getkirby.com/t/help-with-git-submodules/1488/4 "2015-06-29T22:04:53Z")

</div>

I wonder where this path ‘deploy/kirby’ comes from … have you made any changes to the original setup?

---

<div class="post-metadata">

**Author:** ![louiswalch](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/louiswalch/32/3819_2.png) [@louiswalch](https://forum.getkirby.com/u/louiswalch)\
**Post date:** [June 29, 2015, 11:21pm UTC](https://forum.getkirby.com/t/help-with-git-submodules/1488/5 "2015-06-29T23:21:51Z")

</div>

The website is installed in a sub-directory of my repo called deploy.

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [June 30, 2015, 6:12am UTC](https://forum.getkirby.com/t/help-with-git-submodules/1488/6 "2015-06-30T06:12:48Z")

</div>

I see, that is probably the reason why the submodule mapping does not work. You could try to change the path in .gitmodules to deploy/kirby and try again.

---

<div class="post-metadata">

**Author:** ![lukasbestle](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/lukasbestle/32/11437_2.png) [@lukasbestle](https://forum.getkirby.com/u/lukasbestle)\
**Post date:** [July 17, 2015, 7:29pm UTC](https://forum.getkirby.com/t/help-with-git-submodules/1488/7 "2015-07-17T19:29:56Z")

</div>

BTW: Even easier and more reliable is `git submodule update --init --recursive`, which works in one step.

---

<div class="post-metadata">

**Author:** ![distantnative](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/distantnative/32/11319_2.png) [@distantnative](https://forum.getkirby.com/u/distantnative)\
**Post date:** [February 6, 2025, 5:17pm UTC](https://forum.getkirby.com/t/help-with-git-submodules/1488/8 "2025-02-06T17:17:00Z")

</div>

Archived on February 6, 2025, 5:17pm UTC


