git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v2 10/11] vcs-svn,svn-fe: add --incremental option

From
Jonathan Nieder <jrnieder@gmail.com>
Date
Jul 25, 2011, 21:35 UTC
Message-ID
<20110725213526.GB8708@elie.dc0b.debconf.org>
In-Reply-To
<1310559673-5026-11-git-send-email-divanorama@gmail.com>
Dmitry Ivankov wrote:
Show 7 quoted lines
> This option is to make svn-fe write commits on top of the existing ref
> instead of overwriting it. More precise, the first commit's parent is
> set to be :(first_revision_in_current_dump - 1) mark.
>
> Prerequisite is to (re)use import marks (from previous imports). It is
> safe to use this option on a svn dump that starts with r0/r1. The svn
> dump itself should be incremental too.

In other words, this allows running svn-fe to resume a partial import or to resume an import after the remote repository has added more history. Hoorah!

[...]
Show 5 quoted lines
> +	try_dump_ext "--incremental" "" "--export-marks=./marks" emptyprop.dump &&
> +	test_line_count = 2 ./marks &&
> +
> +	try_dump_ext "--incremental" "" "--import-marks=./marks --export-marks=./marks" moreempty.dump &&
> +	test_line_count = 3 ./marks &&

It should be possible to avoid this extra argument by making "reinit_git" remove the marks file and using something like

	git fast-import --import-marks-if-exists=marks --export-marks=marks
Show 9 quoted lines
> --- a/test-svn-fe.c
> +++ b/test-svn-fe.c
> @@ -22,6 +22,9 @@ static struct option test_svnfe_options[] = {
>  	OPT_SET_INT('d', NULL, &d, "test apply_delta", 1),
>  	OPT_STRING(0, "ref", &args.ref, "dst_ref",
>  		"write to dst_ref instead of refs/heads/master"),
> +	OPT_BIT(0, "incremental", &args.incremental,
> +		"resume export, requires marks and incremental dump",
> +		1),
Why OPT_BIT?

Hope that helps, Jonathan

Previous: Dmitry IvankovNext: Dmitry Ivankov
Message 20 of 24 in “vcs-svn,svn-fe add a couple of options”
  1. 00/11 vcs-svn,svn-fe add a couple of optionsDmitry Ivankov, Jul 13, 2011
  2. 01/11 svn-fe: add man target to MakefileDmitry Ivankov, Jul 13, 2011
  3. Jonathan NiederJul 24, 2011
  4. 02/11 test-svn-fe: use parse-optionsDmitry Ivankov, Jul 13, 2011
  5. Jonathan NiederJul 24, 2011
  6. 03/11 svn-fe: add EXTLIBS needed for parse-optionsDmitry Ivankov, Jul 13, 2011
  7. Jonathan NiederJul 24, 2011
  8. 04/11 svn-fe: add usage and unpositional arguments versionsDmitry Ivankov, Jul 13, 2011
  9. Jonathan NiederJul 24, 2011
  10. 05/11 vcs-svn: move url parameter from _read to _initDmitry Ivankov, Jul 13, 2011
  11. Jonathan NiederJul 24, 2011
  12. 06/11 vcs-svn: move commit parameters logic to svndump.cDmitry Ivankov, Jul 13, 2011
  13. Jonathan NiederJul 24, 2011
  14. 07/11 vcs-svn,svn-fe: allow to specify dump destination refDmitry Ivankov, Jul 13, 2011
  15. Jonathan NiederJul 25, 2011
  16. 08/11 vcs-svn,svn-fe: convert REPORT_FILENO to an optionDmitry Ivankov, Jul 13, 2011
  17. Jonathan NiederJul 25, 2011
  18. 09/11 vcs-svn,svn-fe: allow to disable 'progress' linesDmitry Ivankov, Jul 13, 2011
  19. 10/11 vcs-svn,svn-fe: add --incremental optionDmitry Ivankov, Jul 13, 2011
  20. Jonathan NiederJul 25, 2011
  21. 11/11 vcs-svn,svn-fe: add an option to write svnrev notesDmitry Ivankov, Jul 13, 2011
  22. Jonathan NiederJul 25, 2011
  23. Dmitry IvankovJul 28, 2011
  24. Jonathan NiederJul 28, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.