flake-utils icon indicating copy to clipboard operation
flake-utils copied to clipboard

ref: simplify flattenTree

Open blaggacao opened this issue 3 years ago • 3 comments

People have been complaining about the readability of the code. In particular, the former flattenTreeSystem which might have ultimately lead to its abandonment instead of its fixing in the particular context it was abandoned.

Do a decisive preemptive strike, here.

blaggacao avatar Apr 11 '21 17:04 blaggacao

I think we should get rid of flattenTree. It's not providing a lot of value, except using packages instead of legacyPackages.

zimbatm avatar Apr 12 '21 09:04 zimbatm

I think the name-spacing by "/" can proove useful in itself and sets a good precedent. I have a sense it will be useful to export self.overlays with a flat keyspace that requires to include a composed key out of name + some other concept(s).

Though, the isDerivation check, as (now) assumed by filterPackages, maybe is in a dead spot, indeed, and could be removed cheaply.

blaggacao avatar Apr 12 '21 15:04 blaggacao

I guess it doesn't hurt to keep it.

zimbatm avatar Apr 12 '21 18:04 zimbatm

Closing as flattenTree is stable, and I don't want to touch it too much

zimbatm avatar Apr 09 '23 10:04 zimbatm