Does anyone know where the term "getting the sack" comes from?

I imagine it’s something from the industrial/pre-industrial period, but if anyone knows I’d be interested.

No cite at present, but I believe it is from the French- being given your sack to take your tools away with you. Will check for sources.

Pjen has it.

The Phrase Finder for “Get the sack”

Thanks daffyduck I had just come back to start searching for cites.