0

Sort of new to Git, but I'm thinking of moving over from SVN. I know that Git does not allow you to block off a single directory from users, so it's all or nothing in terms of access, but a frequent scenario I have is that I want to use source control for a whole project, but share only the /bin directory with a client. Are there strategies or best practices for this? I'm looking at BitBucket as a host, so I wouldn't be hosting Git myself, therefore I don't think I can make any modifications to how Git works.

What do you guys do?

AlexB
  • 687
  • 2
  • 7
  • 15
  • 1
    If the client shouldn't have access to the source, why would you give them access to your source control system? – Wooble Aug 31 '12 at 23:45
  • I often will give SVN access to the deployment files. I want clients to be able to get the latest version of those files, and so SVN works well for that, but sometimes I don't want to let them have the source files. – AlexB Sep 01 '12 at 00:31
  • Source control systems usually deal badly with versioning binaries anyway; some other deployment strategy is probably a better idea. – Wooble Sep 01 '12 at 14:15

1 Answers1

0

Put the bin directory in a separate repository. If it must be a subdirectory, use submodules.

Karl Bielefeldt
  • 47,314
  • 10
  • 60
  • 94
  • That was my first thought, although I was wondering if there were any "accepted" ways of doing this. From my reading, submodules have some weird issues? But that's mainly if you have to pull from them frequently. I guess if it was just a /bin folder, you'd mainly be pushing builds there? – AlexB Sep 01 '12 at 00:57
  • The "accepted" way is going to be using a separate repo, that's why I said only use a submodule if you must. – Karl Bielefeldt Sep 01 '12 at 01:15