MECCA, Saudi Arabia, Feb 8 (Reuters) - Rival Palestinian factions agreed at crisis talks in Saudi Arabia on Thursday on the formation of a unity government, an official said. "We have agreed to form a national unity government. The agreement will be signed very soon," Palestinian ambassador to Saudi Arabia Jamal al-Shobaki told Reuters. The Islamist group Hamas, which won the last Palestinian elections, and Palestinian President Mahmoud Abbas's Fatah faction earlier agreed on the distribution of key cabinet posts.