If you destroy your rear derailleur or hanger in a crash, one way of getting home under your own steam is to convert your bike to an impromptu singlespeed. This is much simpler on a hardtail than it is on a full suspension bike, as the chain length on most suspension bikes changes throughout the shock stroke. If you have to shorten the chain on a full suspension bike, then make sure you take account of the chain growth by compressing the shock as much as you can and watching to see whether or not the chain length you’ve chosen is long enough to accommodate it.
The first task is choosing a suitable gear. This is dependent on chainline as well as your fitness, and the best chance for success lies in choosing the middle chainring and the middle cassette sprocket (usually the third or fourth). Choose a random place in the chain and use the chain tool to separate the chain, as shown on page 32. Remember to leave the rivet sticking out of the back of the chain if you’re going to be using it to rejoin the chain. Unthread the chain from the rear derailleur and re-route it to pass through the front derailleur, around the chainring of choice and then around the cassette sprocket of choice, bypassing the broken rear derailleur altogether if it’s still on the frame. Match up the ends of the chain and work out how many links you need to remove to make the chain short enough. Finding the perfect spot can be tricky but it’s better to have the chain slightly too slack than too tight, as an overly tight chain is more likely to snap again.
Rejoin the chain, using the instructions on page 33. You will have to ride carefully to keep the chain in place without the tension provided by the rear derailleur. Be as smooth as you can, keep up an even pressure on the pedals and don’t be tempted to stand up and pedal as the jerky motion this entails is more likely to unseat the chain. Remember to save the section of chain you removed you’ll need to refit it to the chain once you’ve replaced the broken derailleur. Chains and cassettes wear together, with the chain stretching at the same rate as it erodes the teeth on the sprockets, which usually means you have to replace both cassette and chain at the same time unless they’re both reasonably new.
Route the chain around a suitable sprocket, bypassing the rear derailleur
We can’t remember seeing many emergency bicycle repairs in movies, but we can recommend the ziptie repair from Two Seconds. The film is about a woman downhiller who quits racing. She packs her bike up and sets up to build a new life, but when she tries to put her bike back together, she finds she’s lost the smallest sprocket from her cassette. We’re not sure why she had to take her cassette off the wheel to ship it, but after some pondering she replaces the missing sprocket with a ziptie. The ziptie neatly holds the other sprockets in place, allowing her to refit the lockring. In a short scene that must have been highly appreciated by a small section of the audience, she carefully readjusts the high end-stop screw to prevent the chain from shifting onto the missing sprocket. Top movie, and full marks for imaginative use of zipties.
Source : BIKE MAINTENANCE TIPS, TRICKS & TECHNIQUES