The latest Derailleur chains you should save the pieces removed to shorten the chain when it was replaced , and a few quick Links.
older chain designs where the pins did not have to be so short as to be flush with the outer side plate,
could be repaired with a spare are link of same chain or shortened , with the chain tool ..
No longer after the push to pack in more speeds in a limited cassette driver space ..
How many 'Speeds' you packin?