Galaxies are disc shaped because they are gas rich and dynamically young. Stars are also gas rich but they are dynamically old so they have had time to rid themselves of their discs. Young protostars (which are dynamically young) are surrounded by proto-stellar discs. The reason many young gas rich objects are disc shaped has to do the fact that circular orbits are compatible with no orbit crossing, hence no shocks. In some sense, many young astronomical objects are disc shaped because they contain(ed) gas which can radiate away non circular motion.
But a disc is not the most likely state of a gravitational system: given time, torquing, instabilities or viscous processes it will tend towards a more likely compact state, where mass flows inwards and angular momentum outwards. This is why proto-stellar discs become stars. Galaxies on the other hand have not had time to turn themselves into gigantic black holes, or been given the opportunity to do so via torquing with their environment.
When two gas poor disc galaxies collide they produce an elliptical which is not disc like. When two gas rich disc galaxies collide they produce a disc like galaxy with a bulge.