V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
sarices
V2EX  ›  问与答

私单如何更好地做好源码管理

  •  
  •   sarices · 2015-05-18 10:46:56 +08:00 · 2257 次点击
    这是一个创建于 3272 天前的主题,其中的信息可能已经有所发展或是发生改变。
    以前都是单干,源码管理是git,一般都是本地git,没有远程仓库,自动同步到dropbox
    现在有和一个朋友搞,部署了自己的远程仓库,两个分支master 和dev 自己测测试服务器部署dev,客户的服务器部署master,然后每人本地自己另外开一个分支导致现在流程有点麻烦

    checkout dev > pull dev(远程仓库) > checkout 自己分支 > rebase dev > checkout dev > merge 自己分支 > push dev(远程和测试服务器)

    感觉哪里不对,好繁复的流程
    17 条回复    2015-05-18 12:23:42 +08:00
    wy315700
        1
    wy315700  
       2015-05-18 10:48:04 +08:00
    github 私有库
    sarices
        2
    sarices  
    OP
       2015-05-18 10:49:53 +08:00
    @wy315700 速度不可忍受,比我家里的nas远程访问还慢
    wy315700
        3
    wy315700  
       2015-05-18 10:50:50 +08:00
    @sarices bitbucket什么的都可以啊,还有gitcafe,
    icemanpro
        4
    icemanpro  
       2015-05-18 10:52:46 +08:00
    df4VW
        5
    df4VW  
       2015-05-18 10:53:19 +08:00
    @sarices 不翻墙的么。。?
    sarices
        6
    sarices  
    OP
       2015-05-18 11:03:46 +08:00
    @wy315700
    @icemanpro
    @df4VW
    现在用docker部署了gitlab
    msg7086
        7
    msg7086  
       2015-05-18 11:06:24 +08:00
    流程看着没问题啊,标准的gitflow简化版。
    如果觉得命令行太烦,那就用个gui。

    我以前做开发是开分支然后发pull request,互审代码无误再merge。
    mind3x
        8
    mind3x  
       2015-05-18 11:13:38 +08:00
    bitbucket一分钱都不要你的
    wy315700
        9
    wy315700  
       2015-05-18 11:16:06 +08:00
    @sarices 自己部署维护成本还是高
    drivedreams
        10
    drivedreams  
       2015-05-18 11:22:37 +08:00
    git.oschina.com 开源中国的私有库啊
    clino
        11
    clino  
       2015-05-18 11:22:45 +08:00
    可以架个gerrit来用,我们代码相关协作都用这个,用来code review还是很方便的
    drivedreams
        12
    drivedreams  
       2015-05-18 11:23:11 +08:00
    后缀打错了 http://git.oschina.net/
    sarices
        13
    sarices  
    OP
       2015-05-18 11:40:07 +08:00
    @msg7086 就是感觉流程好繁琐,master分支是在线上合并的,然后用hook部署到客户的服务器
    sarices
        14
    sarices  
    OP
       2015-05-18 11:45:14 +08:00
    @mind3x @wy315700 @drivedreams 国内还是算了,自己部署代码泄露是自己的问题,自己部署成本也不高,docker非常好部署,家里的服务器带宽还可以,公司有一大堆服务器可以用
    @clino 这个可以试试,现在代码都是自己本地看,基本上有bug再开分支解决
    msg7086
        15
    msg7086  
       2015-05-18 12:11:29 +08:00
    @sarices 如果你是命令行用户的话,试试直接用 git flow * 呢?
    learnshare
        16
    learnshare  
       2015-05-18 12:13:32 +08:00
    Bitbucket 比较适合私有项目的协作
    proudzhu
        17
    proudzhu  
       2015-05-18 12:23:42 +08:00 via Android
    Checkout 自己分支 -> git fetch origin -> git rebase origin/dev -> git push origin
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   2200 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 02:33 · PVG 10:33 · LAX 19:33 · JFK 22:33
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.