write to file from sinatra