Truncate file at front

前端 未结 7 850
耶瑟儿~
耶瑟儿~ 2020-12-09 09:48

A problem I was working on recently got me to wishing that I could lop off the front of a file. Kind of like a “truncate at front,” if you will. Truncating a file at the bac

相关标签:
7条回答
  • 2020-12-09 10:32

    I think there's a bit of a chicken-and-egg problem in there: because filesystems have not supported this kind of behavior efficiently, people haven't written programs to use it, and because people haven't written programs to use it, there's little incentive for filesystems to support it.

    You could always write your own filesystem to do this, or maybe modify an existing one (although filesystems used "in the wild" are probably pretty complicated, you might have an easier time starting from scratch). If people find it useful enough it might catch on ;-)

    0 讨论(0)
提交回复
热议问题