Hadronization in semi-inclusive deep-inelastic scattering on nuclei