threads / discuss / 61311

fast-import interface issues

Subject: fast-import interface issues

## tl;dr

One message between Apr 11, 2024 and Apr 11, 2024.

replies: 0people: 1as markdown or json

Elliott Mitchell· Apr 11, 2024, 22:18 UTC · lore

I've ended up trying to use `git fast-import` for a task and have ended up observing issues with the current interface.

First item, why is there no -0 option? Due to any string being a valid filename, most Unix utilities have evolved a -0 option (sometimes other characters). `find -print0`, `xargs -0`, `grep -z`, `grep -Z`, `tar -T --null`. Yet there is no `git fast-import -0`. I suspect this could work better with unusual filenames.

Second, forced use of quotes for 'ls' SP <path> LF seems a poor choice. Using the empty string as a dataref or the mark of the WIP commit seem better choices. In particular 'ls' SP SP <path> \0 could be readily distinguished from a sha1 or other existing data references.

Third, why is 'cat-blob' limited to blob data? `cat-file --batch` isn't limited to blobs, so why is `fast-import`'s equivalent so limited?

Alas, I'm already involved in too many things at once and cannot hope to implement these myself. Yet they do seem obvious limitations in what `git fast-import` can be used for.

-- 
(\___(\___(\______          --=> 8-) EHM <=--          ______/)___/)___/)
 \BS (    |         ehem+sigmsg@m5p.com  PGP 87145445         |    )   /
  \_CS\   |  _____  -O #include <stddisclaimer.h> O-   _____  |   /  _/
8A19\___\_|_/58D2 7E3D DDF4 7BA6 <-PGP-> 41D1 B375 37D0 8714\_|_/___/5445

← back to recent threads