From: jocloud Date: Thu, 21 May 2020 07:37:46 +0000 (+0000) Subject: published directory change X-Git-Url: https://git.insang.kr/gitweb/?a=commitdiff_plain;h=a15e6e32400c1a38dcc6a6a213e846da16f3ff7d;p=ZipProject.git published directory change --- diff --git a/ZipProject/Models/LanguagePack.cs b/ZipProject/Models/LanguagePack.cs index 3e01bc7..9549928 100644 --- a/ZipProject/Models/LanguagePack.cs +++ b/ZipProject/Models/LanguagePack.cs @@ -1,4 +1,4 @@ -using System; +using System; using System.IO; using Newtonsoft.Json; @@ -7,7 +7,12 @@ namespace ZipProject.Models { public static string GetText (string lang, string id) { - string path = Environment.CurrentDirectory + "/wwwroot/Language/" + lang + ".json"; + #if !DEBUG + string path = Environment.CurrentDirectory + "release/netcoreapp2.1/publish/wwwroot/Language/" + lang + ".json"; + #else + string path = Environment.CurrentDirectory + "/wwwroot/Language/" + lang + ".json"; + #endif + string json = File.OpenText (path).ReadToEnd (); dynamic result = JsonConvert.DeserializeObject (json); diff --git a/ZipProject/ZipProject.csproj b/ZipProject/ZipProject.csproj index 2f066d1..7c6c8a1 100644 --- a/ZipProject/ZipProject.csproj +++ b/ZipProject/ZipProject.csproj @@ -2,7 +2,7 @@ netcoreapp2.1 - + diff --git a/buildrelease b/buildrelease index 6db154d..c92721a 100755 --- a/buildrelease +++ b/buildrelease @@ -1,2 +1,3 @@ + cd ZipProject -dotnet publish --configuration Release +dotnet publish --configuration ../../../nicezip/release