> craftspeople take their jigs with them from job to job

Except for software gigs the software typically belongs to the customer so you'd need to rewrite it every time...

Depends. With all the web agencies I've made, the only code that belonged to customers was the actual website part. Any of the "jigs" that we made for our workflow was not part of that.

And contractually, any code I made was my employer's if I made it during office hours. Some even made a claim for code I would've written that during my employ that would be "competitive". Luckily, there was a massive difference in what I would do in my own time versus what they did.

Depends. If you are a contractor, like most craftspeople, your tools are your own.

My contracts always state I own tools created or byproducts of the work that don't end up in the work.

Only if you are self employed, otherwise it belongs to the agency.

Again: it depends. It is all about how the contract is written.

I never seen any other kind of contract, on my 50ys.

I'm curious how does it work, you handover the tools you wrote, .bashrc/.zshrc, etc?

When I'm hired in a company (not contract), they wipe the harddrive when I leave (well, I also do it before I hand it over sometimes). So they don't get the tools (I take them with myself, it would be a waste to loose them)

You're definitely right for most agencies; most will let you use it in a portfolio or something, but not necessarily retain the rights to the work.

Some agencies do, however; it's dependent on the contract specifics.