Factored-out file path construction.