some basic file functions accomplished