public static void LoadSettings()
{
try
{
SafeSetString("gitdir", x => GitCommand = x);
SafeSetString("gitbindir", x => GitBinDir = x);
SafeSetInt("maxcommits", x => MaxCommits = x);
SafeSetInt("authorImageCacheDays", x => AuthorImageCacheDays = x);
SafeSetInt("authorimagesize", x => AuthorImageSize = x);
GetEncoding();
try
{
SafeSetHtmlColor("diffaddedcolor", x => DiffAddedColor = x);
SafeSetHtmlColor("diffremovedcolor", x => DiffRemovedColor = x);
SafeSetHtmlColor("diffaddedextracolor", x => DiffAddedExtraColor = x);
SafeSetHtmlColor("diffremovedextracolor", x => DiffRemovedExtraColor = x);
SafeSetHtmlColor("diffsectioncolor", x => DiffSectionColor = x);
SafeSetHtmlColor("tagcolor", x => TagColor = x);
SafeSetHtmlColor("graphcolor", x => GraphColor = x);
SafeSetHtmlColor("branchcolor", x => BranchColor = x);
SafeSetHtmlColor("remotebranchcolor", x => RemoteBranchColor = x);
SafeSetHtmlColor("othertagcolor", x => OtherTagColor = x);
SafeSetBool("multicolorbranches", x => MulticolorBranches = x);
SafeSetBool("branchborders", x => BranchBorders = x);
SafeSetBool("stripedbanchchange", x => StripedBranchChange = x);
}
catch (Exception ex)
{
Trace.WriteLine(ex.Message);
}
SafeSetString("translation", x => Translation = x);
SafeSetString("pullmerge", x => PullMerge = x);
SafeSetString("gitssh", GitCommands.SetSsh);
SafeSetString("plink", x => Plink = x);
SafeSetString("puttygen", x => Puttygen = x);
SafeSetString("pageant", x => Pageant = x);
SafeSetString("dictionary", x => Dictionary = x);
SafeSetString("smtp", x => Smtp = x);
SafeSetBool("showauthorgravatar", x => ShowAuthorGravatar = x);
SafeSetBool("userprofilehomedir", x => UserProfileHomeDir = x);
SafeSetString("customhomedir", x => CustomHomeDir = x);
SafeSetBool("closeCommitDialogAfterCommit", x => CloseCommitDialogAfterCommit = x);
SafeSetBool("pushAfterCommit", x => PushAfterCommit = x);
SafeSetBool("markIllFormedLinesInCommitMsg", x => MarkIllFormedLinesInCommitMsg = x);
SafeSetBool("followrenamesinfilehistory", x => FollowRenamesInFileHistory = x);
SafeSetBool("autostash", x => AutoStash = x);
SafeSetString("iconcolor", x => IconColor = x);
SafeSetBool("relativedate", x => RelativeDate = x);
SafeSetBool("usefastchecks", x => UseFastChecks = x);
SafeSetBool("showgitcommandline", x => ShowGitCommandLine = x);
SafeSetBool("showrevisiongraph", x => ShowRevisionGraph = x);
SafeSetBool("showauthordate", x => ShowAuthorDate = x);
SafeSetBool("closeprocessdialog", x => CloseProcessDialog = x);
SafeSetBool("showallbranches", x => ShowCurrentBranchOnly = !x);
SafeSetBool("branchfilterenabled", x => BranchFilterEnabled = x);
SafeSetBool("orderrevisiongraphbydate", x => OrderRevisionByDate = x);
SafeSetBool("commitinfoshowcontainedinbranches", x => CommitInfoShowContainedInBranches = x);
SafeSetBool("commitinfoshowcontainedintags", x => CommitInfoShowContainedInTags = x);
SafeSetInt("revisionGridQuickSearchTimeout", x => RevisionGridQuickSearchTimeout = x);
SafeSetBool("showgitstatusinbrowsetoolbar", x => ShowGitStatusInBrowseToolbar = x);
SafeSetString("lastcommitmessage", x => LastCommitMessage = x);
SafeSetBool("showerrorswhenstagingfiles", x => ShowErrorsWhenStagingFiles = x);
SafeSetBool("revisiongraphdrawnonrelativesgray", x => RevisionGraphDrawNonRelativesGray = x);
SafeSetString("history", Repositories.DeserializeHistoryFromXml);
SafeSetString("repositories", Repositories.DeserializeRepositories);
}
catch (Exception ex)
{
Trace.WriteLine(ex.Message);
}
}