From b0457580b587c0ef996d38675f38f458d93ac12c Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sat, 7 Jan 2012 00:19:44 -0800 Subject: [PATCH] Allow home path to be specified --- SparkleLib/SparkleConfig.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/SparkleLib/SparkleConfig.cs b/SparkleLib/SparkleConfig.cs index 77749156..c95a223c 100755 --- a/SparkleLib/SparkleConfig.cs +++ b/SparkleLib/SparkleConfig.cs @@ -37,8 +37,11 @@ namespace SparkleLib { public string HomePath { get { - return Environment.GetFolderPath (Environment.SpecialFolder.Personal); - } + if (GetConfigOption ("home_path") != null) + return GetConfigOption ("home_path"); + else + return Environment.GetFolderPath (Environment.SpecialFolder.Personal); + } } public string FoldersPath { @@ -105,6 +108,7 @@ namespace SparkleLib { } finally { Load (FullPath); + TmpPath = Path.Combine(FoldersPath, ".tmp"); } }