In an electric mixer, cream together the butter and sugars. Scrape the sides of the bowl as you go. Add in the egg, vanilla extract, and almond extract.
Add in the flour ½ a cup at at time, mixing just enough between additions to combine the ingredients. Sprinkle in the salt while the mixer is on low.
Once batter is combined, take out of bowl and using a food scale, split the batter into 2 equal parts. Add red food coloring to one half and begin kneeding the dough to help disperse the red food coloring throughout. You may want to wear latex gloves for this part so your hands don't turn red.
Scoop the dough with a cookie scoop and separate into individual servings. This will make the rolling and twisting of the cookie quicker.
Take one scoop of each color and roll into 3-4 inch rolls. Set them side-by-side and begin gently twisting them around each other like a rope.
Pinch the ends together after twisting is completed and curve one end to make the candy cane shape. Place on a parchment paper lined baking sheet and bake at 375°F for 7-8 minutes, or until the edges are slightly brown.
Let cool completely and serve immediately, or store in an airtight container.