1 |
> >> If all you need to do is host git repositories, I suggest putting bare |
2 |
> >> repos on a server somewhere and having everyone push/pull over SSH. You |
3 |
> >> can use the bare-bones gitweb (comes with git in portage) to view the |
4 |
> >> repos from a web browser. You'll need a separate bug tracking mechanism |
5 |
> >> in that case. |
6 |
> > |
7 |
> > I haven't used git before at all. Is this pretty easy to set up? |
8 |
> > |
9 |
> |
10 |
> If your users all have SSH access to some server, you don't have to do |
11 |
> anything at all. Git works by pushing and pulling from other |
12 |
> repositories. Those repos may reside on a friend's machine, or a server |
13 |
> somewhere; conceptually, it doesn't matter[1]. |
14 |
> |
15 |
> So, for example, I have a git repo for my reapply_default_acl project in |
16 |
> ~/src. I can clone this somewhere else by doing, |
17 |
> |
18 |
> $ mkdir -p tmp/acl |
19 |
> $ cd tmp/acl/ |
20 |
> $ git clone ~/src/reapply_default_acl |
21 |
> Cloning into 'reapply_default_acl'... |
22 |
> done. |
23 |
> |
24 |
> that easy. To do it over SSH is identical. I can connect to my own |
25 |
> machine via SSH for another example: |
26 |
> |
27 |
> $ rm -rf reapply_default_acl |
28 |
> $ $ git clone ssh://mjo@localhost:443/~/src/reapply_default_acl |
29 |
> Cloning into 'reapply_default_acl'... |
30 |
> Password: |
31 |
> remote: Counting objects: 102, done. |
32 |
> remote: Compressing objects: 100% (85/85), done. |
33 |
> remote: Total 102 (delta 34), reused 3 (delta 0) |
34 |
> Receiving objects: 100% (102/102), 33.86 KiB, done. |
35 |
> Resolving deltas: 100% (34/34), done. |
36 |
> |
37 |
> That's all that's involved. You give people "commit access" by allowing |
38 |
> them to write to the directory. |
39 |
> |
40 |
> |
41 |
> [1] This is a slight lie. If you're going to have a centralized repo |
42 |
> that you only push to, you'll want to do two things. First, create the |
43 |
> server repo with `git init --bare` so that you don't have an extra copy |
44 |
> of checked-out files lying around. Second, go into the 'hooks' folder of |
45 |
> the server repo and rename the post-update.sample file to post-update. |
46 |
|
47 |
Thank you for taking the time to explain this. You just sextupled my git |
48 |
knowledge. It does sound easy. Would a basic layout like this plus gitweb |
49 |
plus fugitive/gitv yield a git setup that wouldn't feel lacking for |
50 |
collaboration amongst a few people? It sounds like a bug tracker would be |
51 |
a good addition. |
52 |
|
53 |
- Grant |