{"thread":{"id":"43303","subject":"Re: [PATCH 2/3] git-svn: documentation updates","startedAt":"2006-11-29T02:51:40Z","lastAt":"2006-12-03T02:12:44Z","messageCount":11,"participants":["Seth Falcon","Steven Grimm","Eric Wong","Pazu","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":3},"messages":[{"id":"297336","messageId":"1164768702941-git-send-email-normalperson@yhbt.net","threadId":"43303","inReplyTo":null,"subject":"[PATCH 1/3] git-svn: color support for the log command","fromName":"Eric Wong","fromEmail":"normalperson@yhbt.net","sentAt":"2006-11-29T02:51:40Z","receivedAt":"2006-11-29T02:51:40Z","isPatch":true,"sender":{"key":"e@80x24.org","avatar":null},"body":" * match LESS environment settings to those in pager.c\n * parse diff.color and pager.color settings in the\n   config file, and pass --color to git-log\n * --color and --pager= settings are supported\n\nSigned-off-by: Eric Wong <normalperson@yhbt.net>\n---\n git-svn.perl |   67 ++++++++++++++++++++++++++++++++++++++++-----------------\n 1 files changed, 47 insertions(+), 20 deletions(-)\n\ndiff --git a/git-svn.perl b/git-svn.perl\nindex c3ad5ec..d8d8716 100755\n--- a/git-svn.perl\n+++ b/git-svn.perl\n@@ -60,6 +60,7 @@ nag_lib() unless $_use_lib;\n my $_optimize_commits = 1 unless $ENV{GIT_SVN_NO_OPTIMIZE_COMMITS};\n my $sha1 = qr/[a-f\\d]{40}/;\n my $sha1_short = qr/[a-f\\d]{4,40}/;\n+my $_esc_color = qr/(?:\\033\\[(?:(?:\\d+;)*\\d*)?m)*/;\n my ($_revision,$_stdin,$_no_ignore_ext,$_no_stop_copy,$_help,$_rmdir,$_edit,\n \t$_find_copies_harder, $_l, $_cp_similarity, $_cp_remote,\n \t$_repack, $_repack_nr, $_repack_flags, $_q,\n@@ -68,7 +69,8 @@ my ($_revision,$_stdin,$_no_ignore_ext,$\n \t$_limit, $_verbose, $_incremental, $_oneline, $_l_fmt, $_show_commit,\n \t$_version, $_upgrade, $_authors, $_branch_all_refs, @_opt_m,\n \t$_merge, $_strategy, $_dry_run, $_ignore_nodate, $_non_recursive,\n-\t$_username, $_config_dir, $_no_auth_cache, $_xfer_delta);\n+\t$_username, $_config_dir, $_no_auth_cache, $_xfer_delta,\n+\t$_pager, $_color);\n my (@_branch_from, %tree_map, %users, %rusers, %equiv);\n my ($_svn_co_url_revs, $_svn_pg_peg_revs);\n my @repo_path_split_cache;\n@@ -135,6 +137,8 @@ my %cmd = (\n \t\t\t  'show-commit' => \\$_show_commit,\n \t\t\t  'non-recursive' => \\$_non_recursive,\n \t\t\t  'authors-file|A=s' => \\$_authors,\n+\t\t\t  'color' => \\$_color,\n+\t\t\t  'pager=s' => \\$_pager,\n \t\t\t} ],\n \t'commit-diff' => [ \\&commit_diff, 'Commit a diff between two trees',\n \t\t\t{ 'message|m=s' => \\$_message,\n@@ -759,16 +763,17 @@ sub show_log {\n \t\t}\n \t}\n \n+\tconfig_pager();\n \tmy $pid = open(my $log,'-|');\n \tdefined $pid or croak $!;\n \tif (!$pid) {\n \t\texec(git_svn_log_cmd($r_min,$r_max), @args) or croak $!;\n \t}\n-\tsetup_pager();\n+\trun_pager();\n \tmy (@k, $c, $d);\n \n \twhile (<$log>) {\n-\t\tif (/^commit ($sha1_short)/o) {\n+\t\tif (/^${_esc_color}commit ($sha1_short)/o) {\n \t\t\tmy $cmt = $1;\n \t\t\tif ($c && cmt_showable($c) && $c->{r} != $r_last) {\n \t\t\t\t$r_last = $c->{r};\n@@ -777,25 +782,25 @@ sub show_log {\n \t\t\t}\n \t\t\t$d = undef;\n \t\t\t$c = { c => $cmt };\n-\t\t} elsif (/^author (.+) (\\d+) ([\\-\\+]?\\d+)$/) {\n+\t\t} elsif (/^${_esc_color}author (.+) (\\d+) ([\\-\\+]?\\d+)$/) {\n \t\t\tget_author_info($c, $1, $2, $3);\n-\t\t} elsif (/^(?:tree|parent|committer) /) {\n+\t\t} elsif (/^${_esc_color}(?:tree|parent|committer) /) {\n \t\t\t# ignore\n-\t\t} elsif (/^:\\d{6} \\d{6} $sha1_short/o) {\n+\t\t} elsif (/^${_esc_color}:\\d{6} \\d{6} $sha1_short/o) {\n \t\t\tpush @{$c->{raw}}, $_;\n-\t\t} elsif (/^[ACRMDT]\\t/) {\n+\t\t} elsif (/^${_esc_color}[ACRMDT]\\t/) {\n \t\t\t# we could add $SVN->{svn_path} here, but that requires\n \t\t\t# remote access at the moment (repo_path_split)...\n-\t\t\ts#^([ACRMDT])\\t#   $1 #;\n+\t\t\ts#^(${_esc_color})([ACRMDT])\\t#$1   $2 #;\n \t\t\tpush @{$c->{changed}}, $_;\n-\t\t} elsif (/^diff /) {\n+\t\t} elsif (/^${_esc_color}diff /) {\n \t\t\t$d = 1;\n \t\t\tpush @{$c->{diff}}, $_;\n \t\t} elsif ($d) {\n \t\t\tpush @{$c->{diff}}, $_;\n-\t\t} elsif (/^    (git-svn-id:.+)$/) {\n+\t\t} elsif (/^${_esc_color}    (git-svn-id:.+)$/) {\n \t\t\t($c->{url}, $c->{r}, undef) = extract_metadata($1);\n-\t\t} elsif (s/^    //) {\n+\t\t} elsif (s/^${_esc_color}    //) {\n \t\t\tpush @{$c->{l}}, $_;\n \t\t}\n \t}\n@@ -901,12 +906,30 @@ sub cmt_showable {\n \treturn defined $c->{r};\n }\n \n+sub log_use_color {\n+\treturn 1 if $_color;\n+\tmy $dc;\n+\tchomp($dc = `git-repo-config --get diff.color`);\n+\tif ($dc eq 'auto') {\n+\t\tif (-t *STDOUT || (defined $_pager &&\n+\t\t    `git-repo-config --bool --get pager.color` !~ /^false/)) {\n+\t\t\treturn ($ENV{TERM} && $ENV{TERM} ne 'dumb');\n+\t\t}\n+\t\treturn 0;\n+\t}\n+\treturn 0 if $dc eq 'never';\n+\treturn 1 if $dc eq 'always';\n+\tchomp($dc = `git-repo-config --bool --get diff.color`);\n+\t$dc eq 'true';\n+}\n+\n sub git_svn_log_cmd {\n \tmy ($r_min, $r_max) = @_;\n \tmy @cmd = (qw/git-log --abbrev-commit --pretty=raw\n \t\t\t--default/, \"refs/remotes/$GIT_SVN\");\n \tpush @cmd, '-r' unless $_non_recursive;\n \tpush @cmd, qw/--raw --name-status/ if $_verbose;\n+\tpush @cmd, '--color' if log_use_color();\n \treturn @cmd unless defined $r_max;\n \tif ($r_max == $r_min) {\n \t\tpush @cmd, '--max-count=1';\n@@ -2533,14 +2556,18 @@ sub tz_to_s_offset {\n \treturn ($1 * 60) + ($tz * 3600);\n }\n \n-sub setup_pager { # translated to Perl from pager.c\n-\treturn unless (-t *STDOUT);\n-\tmy $pager = $ENV{PAGER};\n-\tif (!defined $pager) {\n-\t\t$pager = 'less';\n-\t} elsif (length $pager == 0 || $pager eq 'cat') {\n-\t\treturn;\n+# adapted from pager.c\n+sub config_pager {\n+\t$_pager ||= $ENV{GIT_PAGER} || $ENV{PAGER};\n+\tif (!defined $_pager) {\n+\t\t$_pager = 'less';\n+\t} elsif (length $_pager == 0 || $_pager eq 'cat') {\n+\t\t$_pager = undef;\n \t}\n+}\n+\n+sub run_pager {\n+\treturn unless -t *STDOUT;\n \tpipe my $rfd, my $wfd or return;\n \tdefined(my $pid = fork) or croak $!;\n \tif (!$pid) {\n@@ -2548,8 +2575,8 @@ sub setup_pager { # translated to Perl f\n \t\treturn;\n \t}\n \topen STDIN, '<&', $rfd or croak $!;\n-\t$ENV{LESS} ||= '-S';\n-\texec $pager or croak \"Can't run pager: $!\\n\";;\n+\t$ENV{LESS} ||= 'FRSX';\n+\texec $_pager or croak \"Can't run pager: $! ($_pager)\\n\";\n }\n \n sub get_author_info {\n-- \n1.4.4.1.g22a08\n"},{"id":"294338","messageId":"11647687042130-git-send-email-normalperson@yhbt.net","threadId":"43303","inReplyTo":"1164768702941-git-send-email-normalperson@yhbt.net","subject":"[PATCH 2/3] git-svn: documentation updates","fromName":"Eric Wong","fromEmail":"normalperson@yhbt.net","sentAt":"2006-11-29T02:51:41Z","receivedAt":"2006-11-29T02:51:41Z","isPatch":true,"sender":{"key":"e@80x24.org","avatar":null},"body":"Eliminate 'commit' from some places and plug 'dcommit' more.\nAlso update the section --id (GIT_SVN_ID) usage since we\nhave multi-init/multi-fetch now.\n\nSigned-off-by: Eric Wong <normalperson@yhbt.net>\n---\n Documentation/git-svn.txt |   40 +++++++++++++++++++---------------------\n 1 files changed, 19 insertions(+), 21 deletions(-)\n\ndiff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt\nindex a764d1f..a45067e 100644\n--- a/Documentation/git-svn.txt\n+++ b/Documentation/git-svn.txt\n@@ -49,7 +49,7 @@ latest revision.\n \n Note: You should never attempt to modify the remotes/git-svn\n branch outside of git-svn.  Instead, create a branch from\n-remotes/git-svn and work on that branch.  Use the 'commit'\n+remotes/git-svn and work on that branch.  Use the 'dcommit'\n command (see below) to write git commits back to\n remotes/git-svn.\n \n@@ -274,7 +274,7 @@ ADVANCED OPTIONS\n \n -b<refname>::\n --branch <refname>::\n-Used with 'fetch' or 'commit'.\n+Used with 'fetch', 'dcommit' or 'commit'.\n \n This can be used to join arbitrary git branches to remotes/git-svn\n on new commits where the tree object is equivalent.\n@@ -368,7 +368,7 @@ SVN was very wrong.\n Basic Examples\n ~~~~~~~~~~~~~~\n \n-Tracking and contributing to an Subversion managed-project:\n+Tracking and contributing to a Subversion-managed project:\n \n ------------------------------------------------------------------------\n # Initialize a repo (like git init-db):\n@@ -377,10 +377,9 @@ Tracking and contributing to an Subversi\n \tgit-svn fetch\n # Create your own branch to hack on:\n \tgit checkout -b my-branch remotes/git-svn\n-# Commit only the git commits you want to SVN:\n-\tgit-svn commit <tree-ish> [<tree-ish_2> ...]\n-# Commit all the git commits from my-branch that don't exist in SVN:\n-\tgit-svn commit remotes/git-svn..my-branch\n+# Do some work, and then commit your new changes to SVN, as well as\n+# automatically updating your working HEAD:\n+\tgit-svn dcommit\n # Something is committed to SVN, rebase the latest into your branch:\n \tgit-svn fetch && git rebase remotes/git-svn\n # Append svn:ignore settings to the default git exclude file:\n@@ -404,26 +403,24 @@ which can lead to merge commits reversin\n DESIGN PHILOSOPHY\n -----------------\n Merge tracking in Subversion is lacking and doing branched development\n-with Subversion is cumbersome as a result.  git-svn completely forgoes\n-any automated merge/branch tracking on the Subversion side and leaves it\n-entirely up to the user on the git side.  It's simply not worth it to do\n-a useful translation when the original signal is weak.\n+with Subversion is cumbersome as a result.  git-svn does not do\n+automated merge/branch tracking by default and leaves it entirely up to\n+the user on the git side.\n \n [[tracking-multiple-repos]]\n TRACKING MULTIPLE REPOSITORIES OR BRANCHES\n ------------------------------------------\n-This is for advanced users, most users should ignore this section.\n-\n Because git-svn does not care about relationships between different\n branches or directories in a Subversion repository, git-svn has a simple\n hack to allow it to track an arbitrary number of related _or_ unrelated\n-SVN repositories via one git repository.  Simply set the GIT_SVN_ID\n-environment variable to a name other other than \"git-svn\" (the default)\n-and git-svn will ignore the contents of the $GIT_DIR/svn/git-svn directory\n-and instead do all of its work in $GIT_DIR/svn/$GIT_SVN_ID for that\n-invocation.  The interface branch will be remotes/$GIT_SVN_ID, instead of\n-remotes/git-svn.  Any remotes/$GIT_SVN_ID branch should never be modified\n-by the user outside of git-svn commands.\n+SVN repositories via one git repository.  Simply use the --id/-i flag or\n+set the GIT_SVN_ID environment variable to a name other other than\n+\"git-svn\" (the default) and git-svn will ignore the contents of the\n+$GIT_DIR/svn/git-svn directory and instead do all of its work in\n+$GIT_DIR/svn/$GIT_SVN_ID for that invocation.  The interface branch will\n+be remotes/$GIT_SVN_ID, instead of remotes/git-svn.  Any\n+remotes/$GIT_SVN_ID branch should never be modified by the user outside\n+of git-svn commands.\n \n [[fetch-args]]\n ADDITIONAL FETCH ARGUMENTS\n@@ -486,7 +483,8 @@ If you are not using the SVN::* Perl lib\n conflicting changeset to SVN at a bad moment (right before you commit)\n causing a conflict and your commit to fail, your svn working tree\n ($GIT_DIR/git-svn/tree) may be dirtied.  The easiest thing to do is\n-probably just to rm -rf $GIT_DIR/git-svn/tree and run 'rebuild'.\n+probably just to rm -rf $GIT_DIR/git-svn/tree and run 'rebuild'.   You\n+can avoid this problem entirely by using 'dcommit'.\n \n We ignore all SVN properties except svn:executable.  Too difficult to\n map them since we rely heavily on git write-tree being _exactly_ the\n-- \n1.4.4.1.g22a08\n"},{"id":"297020","messageId":"1164768705707-git-send-email-normalperson@yhbt.net","threadId":"43303","inReplyTo":"11647687042130-git-send-email-normalperson@yhbt.net","subject":"[PATCH 3/3] git-svn: fix multi-init","fromName":"Eric Wong","fromEmail":"normalperson@yhbt.net","sentAt":"2006-11-29T02:51:42Z","receivedAt":"2006-11-29T02:51:42Z","isPatch":true,"sender":{"key":"e@80x24.org","avatar":null},"body":"After the bugfix to connect to repositories where the user has\nlimited read permissions, multi-init was broken due to our\nSVN::Ra connection being limited to working in a subdirectory;\nso we now create a new Ra connection for init-ing branches\nand another for tags\n\nAlong with that fix, allow the user to use the command-line\noption flags for multi-init (--revision being the most notable;\nbut also --no-auth-cache, --config-dir, --username (for passing\nto SVN), and --shared/--template for passing to git-init-db\n\nSigned-off-by: Eric Wong <normalperson@yhbt.net>\n---\n git-svn.perl |   13 +++++++++----\n 1 files changed, 9 insertions(+), 4 deletions(-)\n\ndiff --git a/git-svn.perl b/git-svn.perl\nindex d8d8716..3891122 100755\n--- a/git-svn.perl\n+++ b/git-svn.perl\n@@ -124,7 +124,12 @@ my %cmd = (\n \t\t\t  'no-graft-copy' => \\$_no_graft_copy } ],\n \t'multi-init' => [ \\&multi_init,\n \t\t\t'Initialize multiple trees (like git-svnimport)',\n-\t\t\t{ %multi_opts, %fc_opts } ],\n+\t\t\t{ %multi_opts, %init_opts,\n+\t\t\t 'revision|r=i' => \\$_revision,\n+\t\t\t 'username=s' => \\$_username,\n+\t\t\t 'config-dir=s' => \\$_config_dir,\n+\t\t\t 'no-auth-cache' => \\$_no_auth_cache,\n+\t\t\t} ],\n \t'multi-fetch' => [ \\&multi_fetch,\n \t\t\t'Fetch multiple trees (like git-svnimport)',\n \t\t\t\\%fc_opts ],\n@@ -3316,11 +3321,11 @@ sub libsvn_commit_cb {\n \n sub libsvn_ls_fullurl {\n \tmy $fullurl = shift;\n-\t$SVN ||= libsvn_connect($fullurl);\n+\tmy $ra = libsvn_connect($fullurl);\n \tmy @ret;\n \tmy $pool = SVN::Pool->new;\n-\tmy ($dirent, undef, undef) = $SVN->get_dir($SVN->{svn_path},\n-\t\t\t\t\t\t$SVN->get_latest_revnum, $pool);\n+\tmy $r = defined $_revision ? $_revision : $ra->get_latest_revnum;\n+\tmy ($dirent, undef, undef) = $ra->get_dir('', $r, $pool);\n \tforeach my $d (keys %$dirent) {\n \t\tif ($dirent->{$d}->kind == $SVN::Node::dir) {\n \t\t\tpush @ret, \"$d/\"; # add '/' for compat with cli svn\n-- \n1.4.4.1.g22a08\n"},{"id":"294280","messageId":"456D36CE.1060300@midwinter.com","threadId":"43303","inReplyTo":"11647687042130-git-send-email-normalperson@yhbt.net","subject":"Re: [PATCH 2/3] git-svn: documentation updates","fromName":"Steven Grimm","fromEmail":"koreth@midwinter.com","sentAt":"2006-11-29T07:29:18Z","receivedAt":"2006-11-29T07:29:18Z","isPatch":true,"sender":{"key":"koreth@midwinter.com","avatar":"https://gravatar.com/avatar/71b4d2e8b62f168bdc9e9205341159e3567003b4f9e2127c617c5fa0a1f5bad2?d=mp&s=160"},"body":"Eric Wong wrote:\n> Eliminate 'commit' from some places and plug 'dcommit' more.\n> Also update the section --id (GIT_SVN_ID) usage since we\n> have multi-init/multi-fetch now.\n>   \n\nIn the spirit of the \"should the -a option be the default in \ngit-commit?\" discussion... What are the chances that a future version of \ngit-svn could change the \"dcommit\" command to \"commit\" and the current \n\"commit\" to something else? I know it's a historical artifact, but given \nthat git-svn is (by definition) aimed at Subversion users who are \nprobably used to running \"svn commit\", it seems like making \"git-svn \ncommit\" be the thing you usually want to run would be a good thing. One \nless habit to unlearn.\n\n"},{"id":"294596","messageId":"20061129085419.GB4486@hand.yhbt.net","threadId":"43303","inReplyTo":"456D36CE.1060300@midwinter.com","subject":"Re: [PATCH 2/3] git-svn: documentation updates","fromName":"Eric Wong","fromEmail":"normalperson@yhbt.net","sentAt":"2006-11-29T08:54:19Z","receivedAt":"2006-11-29T08:54:19Z","isPatch":true,"sender":{"key":"e@80x24.org","avatar":null},"body":"Steven Grimm <koreth@midwinter.com> wrote:\n> Eric Wong wrote:\n> >Eliminate 'commit' from some places and plug 'dcommit' more.\n> >Also update the section --id (GIT_SVN_ID) usage since we\n> >have multi-init/multi-fetch now.\n> >  \n> \n> In the spirit of the \"should the -a option be the default in \n> git-commit?\" discussion... What are the chances that a future version of \n> git-svn could change the \"dcommit\" command to \"commit\" and the current \n> \"commit\" to something else? I know it's a historical artifact, but given \n> that git-svn is (by definition) aimed at Subversion users who are \n> probably used to running \"svn commit\", it seems like making \"git-svn \n> commit\" be the thing you usually want to run would be a good thing. One \n> less habit to unlearn.\n\nI've been considering something along those lines.  I'm interested in\nrenaming the current 'commit' command to something else (it still has\nits uses), but I haven't figured out what to call it...\n\nAlso, something that can wrap (git commit && git svn dcommit) into one\nstep would be nice.\n\n-- \n"},{"id":"295270","messageId":"loom.20061129T133305-813@post.gmane.org","threadId":"43303","inReplyTo":"20061129085419.GB4486@hand.yhbt.net","subject":"Re: [PATCH 2/3] git-svn: documentation updates","fromName":"Pazu","fromEmail":"pazu@pazu.com.br","sentAt":"2006-11-29T12:35:07Z","receivedAt":"2006-11-29T12:35:07Z","isPatch":true,"sender":{"key":"pazu@pazu.com.br","avatar":null},"body":"Eric Wong <normalperson <at> yhbt.net> writes:\n\n> Also, something that can wrap (git commit && git svn dcommit) into one\n> step would be nice.\n\nWhat I'd like to see is foreign systems integration for git pull/push. If git\nhad to use git-svn behind the curtains, so be it would be -very- nice if the\nuser could just use git pull/push.\n\n-- Pazu\n"},{"id":"294279","messageId":"m2wt5es0r3.fsf@ziti.fhcrc.org","threadId":"43303","inReplyTo":"20061129085419.GB4486@hand.yhbt.net","subject":"Re: [PATCH 2/3] git-svn: documentation updates","fromName":"Seth Falcon","fromEmail":"sethfalcon@gmail.com","sentAt":"2006-11-29T15:58:40Z","receivedAt":"2006-11-29T15:58:40Z","isPatch":true,"sender":{"key":"sethfalcon@gmail.com","avatar":"https://gravatar.com/avatar/fd62fe73d3013b12fce71d5269ec52eaca3c4cee479efc6eea3603d6f1d8bf8d?d=mp&s=160"},"body":"Eric Wong <normalperson@yhbt.net> writes:\n> I've been considering something along those lines.  I'm interested in\n> renaming the current 'commit' command to something else (it still has\n> its uses), but I haven't figured out what to call it...\n\nI think this would be a sensible change and will help new users get\nstarted with git-svn.  \n\n> Also, something that can wrap (git commit && git svn dcommit) into one\n> step would be nice.\n\nFor my workflow, that wouldn't be all that useful.  I find that I\naccumulate a few commits locally and then send them all to svn.  For\nthis workflow, what would be useful is if dcommit could understand a\ncommand like:\n\n    git svn dcommit remotes/git-svn..HEAD~2\n\nSometimes I realize I should have sent a stack of commits to svn, but\nnow have some newer commits that aren't quite ready on the head of my\nbranch.  \n\nWhile the workaround is easy (create a new branch and dcommit from\nit), I think there is a usability argument in that when one\nsees an example like dcommit foo..bar, one expects all\nthe other magic to work.  I feel for this and accidentally committed a\nfew commits I didn't want to send.  If nothing else, perhaps git-svn\ncould error out and say, \"hey, I don't do that\".\n\n"},{"id":"296194","messageId":"20061203013955.GD1369@localdomain","threadId":"43303","inReplyTo":"loom.20061129T133305-813@post.gmane.org","subject":"Re: [PATCH 2/3] git-svn: documentation updates","fromName":"Eric Wong","fromEmail":"normalperson@yhbt.net","sentAt":"2006-12-03T01:39:55Z","receivedAt":"2006-12-03T01:39:55Z","isPatch":true,"sender":{"key":"e@80x24.org","avatar":null},"body":"Pazu <pazu@pazu.com.br> wrote:\n> Eric Wong <normalperson <at> yhbt.net> writes:\n> \n> > Also, something that can wrap (git commit && git svn dcommit) into one\n> > step would be nice.\n> \n> What I'd like to see is foreign systems integration for git pull/push. If git\n> had to use git-svn behind the curtains, so be it would be -very- nice if the\n> user could just use git pull/push.\n\nBoth push and pull are git/bk/hg(?)-specific terms; most SVN users are\nnot accustomed to them.  Using 'pull' with git-svn has already been\ndiscouraged for a while (since the introduction of dcommit); and\nhaving a 'push' without a 'pull' would be very confusing.\n\nI am interested in putting the .git/svn/*/info/url information into\n.git/config, however (like modern remotes).\n\n-- \n"},{"id":"298104","messageId":"20061203014942.GF1369@localdomain","threadId":"43303","inReplyTo":"m2wt5es0r3.fsf@ziti.fhcrc.org","subject":"Re: [PATCH 2/3] git-svn: documentation updates","fromName":"Eric Wong","fromEmail":"normalperson@yhbt.net","sentAt":"2006-12-03T01:49:42Z","receivedAt":"2006-12-03T01:49:42Z","isPatch":true,"sender":{"key":"e@80x24.org","avatar":null},"body":"Seth Falcon <sethfalcon@gmail.com> wrote:\n> Eric Wong <normalperson@yhbt.net> writes:\n> > I've been considering something along those lines.  I'm interested in\n> > renaming the current 'commit' command to something else (it still has\n> > its uses), but I haven't figured out what to call it...\n> \n> I think this would be a sensible change and will help new users get\n> started with git-svn.  \n> \n> > Also, something that can wrap (git commit && git svn dcommit) into one\n> > step would be nice.\n> \n> For my workflow, that wouldn't be all that useful.  I find that I\n> accumulate a few commits locally and then send them all to svn.  For\n> this workflow, what would be useful is if dcommit could understand a\n> command like:\n> \n>     git svn dcommit remotes/git-svn..HEAD~2\n> \n> Sometimes I realize I should have sent a stack of commits to svn, but\n> now have some newer commits that aren't quite ready on the head of my\n> branch.  \n> \n> While the workaround is easy (create a new branch and dcommit from\n> it), I think there is a usability argument in that when one\n> sees an example like dcommit foo..bar, one expects all\n> the other magic to work.  I feel for this and accidentally committed a\n> few commits I didn't want to send.  If nothing else, perhaps git-svn\n> could error out and say, \"hey, I don't do that\".\n\nAded to my ever-growing git-svn todo list.   Patches welcome :)\n\n-- \n"},{"id":"298685","messageId":"7vd571yccv.fsf@assigned-by-dhcp.cox.net","threadId":"43303","inReplyTo":"20061203013955.GD1369@localdomain","subject":"Re: [PATCH 2/3] git-svn: documentation updates","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-12-03T01:52:48Z","receivedAt":"2006-12-03T01:52:48Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Eric Wong <normalperson@yhbt.net> writes:\n\n> Both push and pull are git/bk/hg(?)-specific terms; most SVN users are\n> not accustomed to them.  Using 'pull' with git-svn has already been\n> discouraged for a while (since the introduction of dcommit); and\n> having a 'push' without a 'pull' would be very confusing.\n\nI am not sure how 'push' side should be integrated, but I wish\npeople could simply update a branch that is managed by foreign\nSCM interfaces such as git-svn and git-cvsimport with 'git fetch'\nby saying that the remote URL points at a non-git \"repository\"\nin remotes/ (or corresponding config).\n\ngit-cvsimport builds the git objects from the changeset without\nusing the working tree, and it would be very natural and simple\nto integrate it into 'git fetch', pretending as if it is just a\nfunny transport.\n\nIf the interface uses the working tree to update the state from\nforeign SCM, then integrating with git-fetch would be\ninpractical.  I guess git-svn works that way?\n"},{"id":"295392","messageId":"20061203021244.GA30316@hand.yhbt.net","threadId":"43303","inReplyTo":"7vd571yccv.fsf@assigned-by-dhcp.cox.net","subject":"Re: [PATCH 2/3] git-svn: documentation updates","fromName":"Eric Wong","fromEmail":"normalperson@yhbt.net","sentAt":"2006-12-03T02:12:44Z","receivedAt":"2006-12-03T02:12:44Z","isPatch":true,"sender":{"key":"e@80x24.org","avatar":null},"body":"Junio C Hamano <junkio@cox.net> wrote:\n> Eric Wong <normalperson@yhbt.net> writes:\n> \n> > Both push and pull are git/bk/hg(?)-specific terms; most SVN users are\n> > not accustomed to them.  Using 'pull' with git-svn has already been\n> > discouraged for a while (since the introduction of dcommit); and\n> > having a 'push' without a 'pull' would be very confusing.\n> \n> I am not sure how 'push' side should be integrated, but I wish\n> people could simply update a branch that is managed by foreign\n> SCM interfaces such as git-svn and git-cvsimport with 'git fetch'\n> by saying that the remote URL points at a non-git \"repository\"\n> in remotes/ (or corresponding config).\n\nAck on being able to use 'git fetch'.\n\n> git-cvsimport builds the git objects from the changeset without\n> using the working tree, and it would be very natural and simple\n> to integrate it into 'git fetch', pretending as if it is just a\n> funny transport.\n> \n> If the interface uses the working tree to update the state from\n> foreign SCM, then integrating with git-fetch would be\n> inpractical.  I guess git-svn works that way?\n\ngit-svn only needs a working tree (hidden away in .git/svn/ and the user\nshould never see it) when it uses the command-line svn client.  If the\nSVN:: libraries are available, then git-svn just uses an alternative\nindex like cvsimport.\n\n-- \n"}]}