git --bare 옵션 사용시 로컬 저장소 업데이트 방법은 무엇일까요?

dorado2의 이미지

http://wiki.kldp.org/wiki.php/GitGuideForKernelDevelopment
웹의 내용을 바탕으로 git를 테스트해보고 있습니다.
wiki 내용이 살짝 오래되었지만, 아직 거의 유효하네요.

linux-2.6에 대한 로컬 미러를 만들고, 거기서 브랜치를 만들어서 작업하는 방식으로 해보려고 하는데요.

아래와 같이 clone을 하고, 위 링크의 내용대로 git remote add linus git://... 이렇게
upstream tracking하는 부분도 설정해 주었습니다.

git clone -n --bare <a href="//git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git" rel="nofollow">git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git</a> linux-2.6-dev
git clone git://localhost/linux-2.6-dev linux-2.6-mine
git remote add linus <a href="//git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git" rel="nofollow">git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git</a> 

그런데 이렇게 만들면 linux-2.6-dev 아래에는 파일 checkout이 안 되어 있어서 그런지, 해당 디렉토리에서
git pull을 해도 upstream의 신규 변경 사항이 업데이트가 안 되네요.

반면에 아래처럼 그냥 clone을 해오면, git pull로 단번에 upstream 내용이 업데이트가 됩니다.

git clone <a href="//git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git" rel="nofollow">git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git</a> linux-2.6

링크내용대로 git fetch -v linus 이렇게 하고, 로컬 브랜치(linux-2.6-mine)에서 git pull을 해도 소용이 없네요.

linux-2.6-dev 쪽 아래의 내용들을 살펴보면, FETCH_HEAD나 ref쪽은 upstream의 최신 commit id값이
들어가 있기는 한데, 정작 git log나 linux-2.6-mine에서의 git pull로 확인해보면 upstream의 최신 내용이
적용되지 않는 상황입니다.

[root@host linux-2.6-dev]# git show-ref |grep master
74fca6a42863ffacaf7ba6f1936a9f228950f657 refs/heads/master
0d03d59d9b31cd1e33b7e46a80b6fef66244b1f2 refs/remotes/linus/master
 
[root@host linux-2.6-dev]#  cat HEAD 
ref: refs/heads/master
 
[root@host linux-2.6-dev]#  cat FETCH_HEAD 
0d03d59d9b31cd1e33b7e46a80b6fef66244b1f2	not-for-merge	branch 'master' of 
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6

아마 workflow가 좀 잘못된 것 같은데, --bare 옵션을 사용했을 때 해당 저장소의 update는 어떤 방식으로
하시는지 궁금합니다.

그리고 git를 운영할 때 좋은 구조나 방식도 있다면 조언 부탁드립니다~

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

BBCode

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param>
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

Textile

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • You can use Textile markup to format text.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Markdown

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • Quick Tips:
    • Two or more spaces at a line's end = Line break
    • Double returns = Paragraph
    • *Single asterisks* or _single underscores_ = Emphasis
    • **Double** or __double__ = Strong
    • This is [a link](http://the.link.example.com "The optional title text")
    For complete details on the Markdown syntax, see the Markdown documentation and Markdown Extra documentation for tables, footnotes, and more.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Plain text

  • HTML 태그를 사용할 수 없습니다.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 줄과 단락은 자동으로 분리됩니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.