shrink (truncate) file from beginning on linux -


is possible in linux (and/or on other unix) 'shrink' file beginning? i'd use persistent queue (no existing implementation suits needs). end of file guess it's possible truncate().

yes, can use cut or tail remove portions of file.

cut -b 17- input_file
tail -c +17 input_file

this output contents of input_file starting @ 17th byte, removing first 16 bytes of file. note cut example add newline output.


Comments

Popular posts from this blog

linux - Mailx and Gmail nss config dir -

c# - Is it possible to remove an existing registration from Autofac container builder? -

php - Mysql PK and FK char(36) vs int(10) -