Remove nix store objects of old derivation build processes

When building a derivation, I am not proficient enough to get it right on the first try. For me it is a matter of trial and error.
During this, I gather a lot of nix store objects which I do not required nor want after I got my working derivation.
What is the best way to clean up the nix store?

For example, this is the nix store of a recent derivation I built:

-r--r--r--  1 root root  11M 1970-01-01 01:00 0rsfw0rjpvi65fs87p2iwxv442y78v1x-master-pdf-editor-5.8.20-qt5.x86_64.deb
dr-xr-xr-x  5 root root 4.0K 1970-01-01 01:00 1cj2wqiyyyjbizhy6sd4xv6l1larndvc-master-pdf-editor-5.8.20
-rw-------  1 root root    0 2024-06-24 13:03 2kgwxbsizcwrzrr36a26c46k3k9crayi-master-pdf-editor-5.8.20.lock
-r--r--r--  1 root root 382K 1970-01-01 01:00 3dy9msafv60g1zrd2p8nsvb6rahwpklc-2.39-master.patch
-r--r--r--  1 root root 2.7K 1970-01-01 01:00 6jdx15y79kqllznp33zx67xgrx1mq434-master-pdf-editor-5.8.20.drv
-r--r--r--  1 root root  11M 1970-01-01 01:00 b9jcm9s6qyr4izfqkkxfwxf37mix4qrk-master-pdf-editor-5.8.20-qt5.x86_64.deb
-r--r--r--  1 root root 2.7K 1970-01-01 01:00 csvdv88aify51jm4gj47rz8wlycrz4d8-master-pdf-editor-5.8.20.drv
-r--r--r--  1 root root 2.9K 1970-01-01 01:00 f5g52gyfm20kzjddmaxysf4qidlwax92-master-pdf-editor-5.8.20-qt5.x86_64.deb.drv
-r--r--r--  1 root root 2.8K 1970-01-01 01:00 fw0488l22a2bkgshh1cc2jgi7rkgy7mg-master-pdf-editor-5.8.20.drv
-r--r--r--  1 root root 2.8K 1970-01-01 01:00 k0x9qc20nn3r2r1p5rqxh4glz7jmkj2q-master-pdf-editor-5.8.20.drv
-rw-------  1 root root    0 2024-06-24 13:36 lmp29iym1slfajxnfzfjr6p6nvyzha3a-master-pdf-editor-5.8.20.lock
-rw-------  1 root root    0 2024-06-24 13:00 madg8hmi882przaj38ji9hs31wpahz0k-master-pdf-editor-5.8.20-qt5.x86_64.deb.lock
-r--r--r--  1 root root 2.8K 1970-01-01 01:00 nhhb1150zgwnjixl1lcp0dkzibaa5vcr-master-pdf-editor-5.8.20.drv
-r--r--r--  1 root root 3.1K 1970-01-01 01:00 nwz9n4mnhpg39fgr5y9157rjrph12dzi-master-pdf-editor-5.8.20.drv
-rw-------  1 root root    0 2024-06-24 13:45 q9krbsqq2cqls5avs440id7c1cshax1l-master-pdf-editor-5.8.20.lock
-r--r--r--  1 root root 3.0K 1970-01-01 01:00 s2agm7y43xakmdzsyx6zsbv2ycad8zrc-master-pdf-editor-5.8.20.drv
-r--r--r--  1 root root 9.2K 1970-01-01 01:00 sjr79wy0v8lj5zxjpszg2jsgfs3m0yws-2.37-master.patch.gz
-r--r--r--  1 root root 2.8K 1970-01-01 01:00 wir02x6dhbfzkzliybbpp735wbx5nhwh-master-pdf-editor-5.8.20.drv
-r--r--r--  1 root root 2.8K 1970-01-01 01:00 xjc2vs1safixkk6rhv75xrraxlx08nak-master-pdf-editor-5.8.20-qt5.x86_64.deb.drv

The directory 1cj2wqiyyyjbizhy6sd4xv6l1larndvc-master-pdf-editor-5.8.20 contains the working derivation and i manually deleted all other directories with nix-store --delete.

I am not sure which of these other objects I can safely delete to clean up the nix store without breaking anything.

Why not nix-store --gc or nix-collect-garbage?