add util function index_of
initialize buffers and view properly
add core_file module