# \[Proposal\] Lock file for Swift Package Manager

**URL:** <https://forums.swift.org/t/proposal-lock-file-for-swift-package-manager/686>\
**Category:** Discussion\
**Created:** [December 20, 2015, 9:01am UTC](https://forums.swift.org/t/proposal-lock-file-for-swift-package-manager/686 "2015-12-20T09:01:57Z")\
**Posts on this page:** 6\
**Page:** 2

<div class="post-metadata">

**Author:** ![Ankit\_Agarwal1](https://avatars.discourse-cdn.com/v4/letter/a/e56c9b/32.png) [@Ankit\_Agarwal1](https://forums.swift.org/u/Ankit_Agarwal1)\
**Post date:** [January 7, 2016, 7:34pm UTC](https://forums.swift.org/t/proposal-lock-file-for-swift-package-manager/686/21 "2016-01-07T19:34:24Z")

</div>

I think git submodules can be added as an additional feature rather than  
depending on it completely for locking because it is a bit problematic to  
use with a team and has many issues

> **[Why your company shouldn’t use Git submodules](https://codingkilledthecat.wordpress.com/2012/04/28/why-your-company-shouldnt-use-git-submodules/)**
>
> A programmer had a version control problem and said, “I know, I’ll use submodules.” Now they have two problems. It is not uncommon at all when working on any kind of larger-scale …

> **···**
>
> On Thu, Jan 7, 2016 at 1:10 AM, Max Howell \<max.howell@apple.com\> wrote:
> 
> > Another option that has occurred to me after talking with Tim Kientzle is  
> > to use \*git submodules\*
> > 
> > submodules lock other clones to a specific revision. Our Packages/  
> > directory is already a directory of clones.
> > 
> > I have not given it a lot of thought yet, but there is possibly power in  
> > reusing this existing part of git.
> > 
> > Mailed here for input.
> 
> --  
> Ankit

---

<div class="post-metadata">

**Author:** ![Max\_Howell](https://avatars.discourse-cdn.com/v4/letter/m/cc9497/32.png) [@Max\_Howell](https://forums.swift.org/u/Max_Howell)\
**Post date:** [January 7, 2016, 7:39pm UTC](https://forums.swift.org/t/proposal-lock-file-for-swift-package-manager/686/22 "2016-01-07T19:39:23Z")

</div>

> I think git submodules can be added as an additional feature rather than depending on it completely for locking because it is a bit problematic to use with a team and has many issues
> 
> [Why your company shouldn’t use Git submodules | Coding Killed the Cat](https://codingkilledthecat.wordpress.com/2012/04/28/why-your-company-shouldnt-use-git-submodules/)

All the issues in the article are addressed by wrapping git with another tool, which we would do.

---

<div class="post-metadata">

**Author:** ![Ankit\_Agarwal1](https://avatars.discourse-cdn.com/v4/letter/a/e56c9b/32.png) [@Ankit\_Agarwal1](https://forums.swift.org/u/Ankit_Agarwal1)\
**Post date:** [January 7, 2016, 7:53pm UTC](https://forums.swift.org/t/proposal-lock-file-for-swift-package-manager/686/23 "2016-01-07T19:53:22Z")

</div>

Can you elaborate "wrapping git with another tool" ?

> **···**
>
> On Fri, Jan 8, 2016 at 1:09 AM, Max Howell \<max.howell@apple.com\> wrote:
> 
> > I think git submodules can be added as an additional feature rather than  
> > depending on it completely for locking because it is a bit problematic to  
> > use with a team and has many issues
> > 
> > [Why your company shouldn’t use Git submodules | Coding Killed the Cat](https://codingkilledthecat.wordpress.com/2012/04/28/why-your-company-shouldnt-use-git-submodules/)
> > 
> > All the issues in the article are addressed by wrapping git with another  
> > tool, which we would do.
> 
> --  
> Ankit

---

<div class="post-metadata">

**Author:** ![Max\_Howell](https://avatars.discourse-cdn.com/v4/letter/m/cc9497/32.png) [@Max\_Howell](https://forums.swift.org/u/Max_Howell)\
**Post date:** [January 7, 2016, 8:00pm UTC](https://forums.swift.org/t/proposal-lock-file-for-swift-package-manager/686/24 "2016-01-07T20:00:35Z")

</div>

> > I think git submodules can be added as an additional feature rather than depending on it completely for locking because it is a bit problematic to use with a team and has many issues
> > 
> > [Why your company shouldn’t use Git submodules | Coding Killed the Cat](https://codingkilledthecat.wordpress.com/2012/04/28/why-your-company-shouldnt-use-git-submodules/)
> 
> All the issues in the article are addressed by wrapping git with another tool, which we would do.
> 
> Can you elaborate "wrapping git with another tool" ?

`swift build` wraps git. All the pain points in that article are due to a lack of automation for various git-steps.

---

<div class="post-metadata">

**Author:** ![Max\_Howell](https://avatars.discourse-cdn.com/v4/letter/m/cc9497/32.png) [@Max\_Howell](https://forums.swift.org/u/Max_Howell)\
**Post date:** [January 13, 2016, 1:01am UTC](https://forums.swift.org/t/proposal-lock-file-for-swift-package-manager/686/25 "2016-01-13T01:01:34Z")

</div>

Just to follow up here. This is not forgotten. I’ll be trying to follow up with more details this week.

> **···**
>
> > > > I think git submodules can be added as an additional feature rather than depending on it completely for locking because it is a bit problematic to use with a team and has many issues
> > > > 
> > > > [Why your company shouldn’t use Git submodules | Coding Killed the Cat](https://codingkilledthecat.wordpress.com/2012/04/28/why-your-company-shouldnt-use-git-submodules/)
> > > 
> > > All the issues in the article are addressed by wrapping git with another tool, which we would do.
> > > 
> > > Can you elaborate "wrapping git with another tool" ?
> > 
> > `swift build` wraps git. All the pain points in that article are due to a lack of automation for various git-steps.

---

<div class="post-metadata">

**Author:** ![Ankit\_Agarwal1](https://avatars.discourse-cdn.com/v4/letter/a/e56c9b/32.png) [@Ankit\_Agarwal1](https://forums.swift.org/u/Ankit_Agarwal1)\
**Post date:** [January 13, 2016, 1:06am UTC](https://forums.swift.org/t/proposal-lock-file-for-swift-package-manager/686/26 "2016-01-13T01:06:58Z")

</div>

Great!

> **···**
>
> On Wed, Jan 13, 2016 at 6:31 AM, Max Howell \<max.howell@apple.com\> wrote:
> 
> > Just to follow up here. This is not forgotten. I’ll be trying to follow up  
> > with more details this week.
> 
> --  
> Ankit

[Previous page](https://forums.swift.org/t/proposal-lock-file-for-swift-package-manager/686.md?page=1)
