writing externals