aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Core
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2016-11-11 00:23:15 -0500
committerLuke Pulverenti <luke.pulverenti@gmail.com>2016-11-11 00:23:15 -0500
commit5bb864a0c4e0d38db10a4c844a9ace1a46ac7b4b (patch)
treebfd0234c751225f4778531723c23a2d2001170a1 /Emby.Server.Core
parentd55535fe43b99fe25fce0c2a035be849b920fbe9 (diff)
move class to new core project
Diffstat (limited to 'Emby.Server.Core')
-rw-r--r--Emby.Server.Core/Emby.Server.Core.xproj7
-rw-r--r--Emby.Server.Core/StartupOptions.cs28
-rw-r--r--Emby.Server.Core/project.json10
3 files changed, 39 insertions, 6 deletions
diff --git a/Emby.Server.Core/Emby.Server.Core.xproj b/Emby.Server.Core/Emby.Server.Core.xproj
index f7f252dfba..704e84d266 100644
--- a/Emby.Server.Core/Emby.Server.Core.xproj
+++ b/Emby.Server.Core/Emby.Server.Core.xproj
@@ -4,7 +4,6 @@
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">14.0</VisualStudioVersion>
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
</PropertyGroup>
-
<Import Project="$(VSToolsPath)\DotNet\Microsoft.DotNet.Props" Condition="'$(VSToolsPath)' != ''" />
<PropertyGroup Label="Globals">
<ProjectGuid>65aa7d67-8059-40cd-91f1-16d02687226c</ProjectGuid>
@@ -13,9 +12,11 @@
<OutputPath Condition="'$(OutputPath)'=='' ">.\bin\</OutputPath>
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
</PropertyGroup>
-
<PropertyGroup>
<SchemaVersion>2.0</SchemaVersion>
</PropertyGroup>
+ <ItemGroup>
+ <ProjectReference Include="..\MediaBrowser.Model\MediaBrowser.Model.csproj" />
+ </ItemGroup>
<Import Project="$(VSToolsPath)\DotNet\Microsoft.DotNet.targets" Condition="'$(VSToolsPath)' != ''" />
-</Project>
+</Project> \ No newline at end of file
diff --git a/Emby.Server.Core/StartupOptions.cs b/Emby.Server.Core/StartupOptions.cs
new file mode 100644
index 0000000000..5da42394d5
--- /dev/null
+++ b/Emby.Server.Core/StartupOptions.cs
@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+
+namespace Emby.Server.Core
+{
+ public class StartupOptions
+ {
+ private readonly List<string> _options = Environment.GetCommandLineArgs().ToList();
+
+ public bool ContainsOption(string option)
+ {
+ return _options.Contains(option, StringComparer.OrdinalIgnoreCase);
+ }
+
+ public string GetOption(string name)
+ {
+ var index = _options.IndexOf(name);
+
+ if (index != -1)
+ {
+ return _options.ElementAtOrDefault(index + 1);
+ }
+
+ return null;
+ }
+ }
+}
diff --git a/Emby.Server.Core/project.json b/Emby.Server.Core/project.json
index 94ca05af05..678026745d 100644
--- a/Emby.Server.Core/project.json
+++ b/Emby.Server.Core/project.json
@@ -1,4 +1,4 @@
-{
+{
"version": "1.0.0-*",
"dependencies": {
@@ -11,14 +11,18 @@
},
"dependencies": {
-
+ "MediaBrowser.Model": {
+ "target": "project"
+ }
}
},
"netstandard1.6": {
"imports": "dnxcore50",
"dependencies": {
"NETStandard.Library": "1.6.0",
-
+ "MediaBrowser.Model": {
+ "target": "project"
+ }
}
}
}