During inflation, gold tends to hold/increase its value.
During the deflation of the Great Depression when commodities sufffered great deflation, only govt bonds, gold and land/homes held their value. Gold increased, actually. But homeowners had to wait many years to get their money back...