A commande line interface

vnext
Paul Schneider 7 years ago
parent 6b3302568f
commit fdb1c550e3
12 changed files with 14401 additions and 633 deletions

@ -0,0 +1,57 @@
using System;
using System.Runtime.Versioning;
using Microsoft.Extensions.PlatformAbstractions;
namespace cli_2
{
public class ApplicationEnvironment : IApplicationEnvironment
{
internal ApplicationEnvironment( FrameworkName targetFramework, string appRootDir )
{
this.RuntimeFramework = targetFramework;
ApplicationBasePath = appRootDir;
}
public string ApplicationBasePath
{
get; set;
}
public string ApplicationName
{
get; set;
}
public string ApplicationVersion
{
get; set;
}
public string Configuration
{
get; set;
}
public FrameworkName RuntimeFramework
{
get; set;
}
public string Version
{
get
{
throw new NotImplementedException();
}
}
public object GetData(string name)
{
throw new NotImplementedException();
}
public void SetData(string name, object value)
{
throw new NotImplementedException();
}
}
}

@ -0,0 +1,22 @@
using System.Threading.Tasks;
using Microsoft.AspNet.Builder;
using Microsoft.AspNet.Hosting;
using Microsoft.AspNet.Http;
public class InteractiveConsoleMiddleWare
{
public InteractiveConsoleMiddleWare(RequestDelegate next)
{
_next = next;
}
readonly RequestDelegate _next;
public async Task Invoke(HttpContext context, IHostingEnvironment hostingEnviroment)
{
//do something
System.Console.WriteLine("kjhnlkhkl");
await _next.Invoke(context);
}
}

@ -1,124 +1,108 @@
using System;
using System.Diagnostics;
using System.Threading.Tasks;
using Microsoft.AspNet.Hosting;
using Microsoft.AspNet.Identity;
using Microsoft.Extensions.CommandLineUtils;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using Microsoft.AspNet.Builder;
using System.Runtime.Versioning;
using Microsoft.AspNet.Builder.Internal;
using Yavsc.Services;
using Google.Apis.Util.Store;
using cli_2;
using Microsoft.Extensions.PlatformAbstractions;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.AspNet.Hosting;
using Yavsc.Models;
using Microsoft.AspNet.Identity.EntityFramework;
using Microsoft.Extensions.OptionsModel;
using Microsoft.AspNet.Hosting.Builder;
namespace cli
{
using Yavsc;
using Microsoft.AspNet.Hosting.Internal;
public class Program
{
private readonly EventLog _log =
new EventLog("Application") { Source = "Application" };
private IServiceProvider serviceProvider;
private static Startup startup;
public Program()
{
ConfigureServices(new ServiceCollection());
}
public static void Main(string[] args)
{
var prog = new Program();
// Program.exe <-g|--greeting|-$ <greeting>> [name <fullname>]
// [-?|-h|--help] [-u|--uppercase]
CommandLineApplication commandLineApplication =
new CommandLineApplication(throwOnUnexpectedArg: false);
CommandArgument names = null;
commandLineApplication.Command("name",
(target) =>
names = target.Argument(
"fullname",
"Enter the full name of the person to be greeted.",
multipleValues: true));
CommandOption greeting = commandLineApplication.Option(
"-$|-g |--greeting <greeting>",
"The greeting to display. The greeting supports"
+ " a format string where {fullname} will be "
+ "substituted with the full name.",
CommandOptionType.SingleValue);
CommandOption envNameOption = commandLineApplication.Option(
"-e |--environment <environment>","The environment to run against.",CommandOptionType.SingleValue);
CommandOption uppercase = commandLineApplication.Option(
"-u | --uppercase", "Display the greeting in uppercase.",
CommandOptionType.NoValue);
commandLineApplication.HelpOption("-? | -h | --help");
commandLineApplication.OnExecute(() =>
{
string greetingString = "Hello!";
string environmentName = "Production";
if (greeting.HasValue())
private void ConfigureServices(IServiceCollection services, string environmentName="Development")
{
string greetingStringTemplate = greeting.Value();
IHostingEnvironment hosting = new HostingEnvironment{ EnvironmentName = environmentName };
services.AddLogging();
var fullname = string.Join(" ", commandLineApplication.RemainingArguments);
greetingString = greetingStringTemplate.Replace("{fullname}", fullname);
}
if (envNameOption.HasValue()){
environmentName = envNameOption.Value();
}
Greet(greetingString, environmentName);
return 0;
});
commandLineApplication.Execute(args);
}
services.AddOptions();
private static void Greet(
string greeting, string environmentName)
{
Console.WriteLine(greeting);
IServiceCollection services = new ServiceCollection();
// Startup.cs finally :)
//EntryPoint.Main(new string[] {});
// Add application services.
services.AddTransient<IEmailSender, MessageSender>();
services.AddTransient<IGoogleCloudMessageSender, MessageSender>();
services.AddTransient<IBillingService, BillingService>();
services.AddTransient<IDataStore, FileDataStore>( (sp) => new FileDataStore("googledatastore",false) );
services.AddTransient<ICalendarManager, CalendarManager>();
IHostingEnvironment hosting = new HostingEnvironment{ EnvironmentName = environmentName };
// TODO for SMS: services.AddTransient<ISmsSender, AuthMessageSender>();
services.AddLocalization(options =>
{
options.ResourcesPath = "Resources";
});
services.AddIdentity<ApplicationUser,IdentityRole>();
var basePath = AppDomain.CurrentDomain.BaseDirectory;
// FIXME null ref var appName = AppDomain.CurrentDomain.ApplicationIdentity.FullName;
// var rtdcontext = new System.Runtime.DesignerServices.WindowsRuntimeDesignerContext (new string { "." }, "nonname");
// hosting.Initialize("approot", config);
// ApplicationHostContext apphostcontext = new ApplicationHostContext ();
IServiceProvider serviceProvider = services.BuildServiceProvider();
IApplicationBuilder iappbuilder = new ApplicationBuilder(serviceProvider);
iappbuilder.ApplicationServices = serviceProvider;
serviceProvider = services.BuildServiceProvider();
var projectRoot = "/home/paul/workspace/yavsc/Yavsc";
hosting.Initialize (projectRoot, null);
Startup startup = new Startup(hosting, PlatformServices.Default.Application);
var targetFramework = new FrameworkName ("dnx",new Version(4,5,1));
//
//
ApplicationEnvironment appEnv = new ApplicationEnvironment(targetFramework, projectRoot);
//configure console logging
serviceProvider
// needs a logger factory ...
var loggerFactory = serviceProvider
.GetService<ILoggerFactory>()
.AddConsole(LogLevel.Debug);
var logger = serviceProvider.GetService<ILoggerFactory>()
.CreateLogger<Program>();
startup = new Startup (hosting, appEnv);
startup.ConfigureServices(services);
logger.LogDebug("Logger is working!");
// Get Service and call method
var userManager = serviceProvider.GetService<UserManager<ApplicationUser> >();
var emailSender = serviceProvider.GetService<IEmailSender>();
foreach (var user in userManager?.Users)
{
Task.Run(async () =>
await emailSender.SendEmailAsync(Startup.SiteSetup, Startup.SmtpSettup, Startup.SiteSetup.Owner.Name, Startup.SiteSetup.Owner.EMail,
$"[{Startup.SiteSetup.Title}] Rappel de votre inscription ({user.UserName})", $"{user.Id}/{user.UserName}/{user.Email}"));
ApplicationBuilderFactory applicationBuilderFactory
= new ApplicationBuilderFactory(serviceProvider);
var builder = applicationBuilderFactory.CreateBuilder(null);
IOptions<SiteSettings> siteSettings = serviceProvider.GetService(typeof(IOptions<SiteSettings>)) as IOptions<SiteSettings>;
IOptions<SmtpSettings> smtpSettings = serviceProvider.GetService(typeof(IOptions<SmtpSettings>)) as IOptions<SmtpSettings>;
startup.Configure(builder,siteSettings,smtpSettings);
}
public static void Main(string[] args)
{
Console.WriteLine($"Hello world!" );
foreach (var str in args) {
Console.WriteLine($"*> {str}");
}
startup.Main(args);
}
}
}

@ -1,117 +0,0 @@
using System;
using System.Diagnostics;
using System.Threading.Tasks;
using Microsoft.AspNet.Hosting;
using Microsoft.AspNet.Hosting.Server;
using Microsoft.AspNet.Identity;
using Microsoft.Extensions.CommandLineUtils;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using Microsoft.Extensions.PlatformAbstractions;
using Microsoft.Framework.Runtime;
using Yavsc.Models;
using Yavsc.Services;
namespace cli
{
public class Program
{
private readonly EventLog _log =
new EventLog("Application") { Source = "Application" };
private readonly IServiceProvider _serviceProvider;
private static Program instance;
public Program()
{
instance = this;
var installer = new System.ServiceProcess.ServiceInstaller();
Console.WriteLine(installer.ServiceName);
}
public static void Main(string[] args)
{
var prog = new Program();
// Program.exe <-g|--greeting|-$ <greeting>> [name <fullname>]
// [-?|-h|--help] [-u|--uppercase]
CommandLineApplication commandLineApplication =
new CommandLineApplication(throwOnUnexpectedArg: false);
CommandArgument names = null;
commandLineApplication.Command("name",
(target) =>
names = target.Argument(
"fullname",
"Enter the full name of the person to be greeted.",
multipleValues: true));
CommandOption greeting = commandLineApplication.Option(
"-$|-g |--greeting <greeting>",
"The greeting to display. The greeting supports"
+ " a format string where {fullname} will be "
+ "substituted with the full name.",
CommandOptionType.SingleValue);
CommandOption envNameOption = commandLineApplication.Option(
"-e |--environment <environment>","The environment to run against.",CommandOptionType.SingleValue);
CommandOption uppercase = commandLineApplication.Option(
"-u | --uppercase", "Display the greeting in uppercase.",
CommandOptionType.NoValue);
commandLineApplication.HelpOption("-? | -h | --help");
commandLineApplication.OnExecute(() =>
{
string greetingString = "Hello!";
string environmentName = "Production";
if (greeting.HasValue())
{
string greetingStringTemplate = greeting.Value();
var fullname = string.Join(" ", commandLineApplication.RemainingArguments);
greetingString = greetingStringTemplate.Replace("{fullname}", fullname);
}
if (envNameOption.HasValue()){
environmentName = envNameOption.Value();
}
Greet(greetingString, environmentName);
return 0;
});
commandLineApplication.Execute(args);
}
private static void Greet(
string greeting, string environmentName)
{
Console.WriteLine(greeting);
IServiceCollection services = new ServiceCollection();
// Startup.cs finally :)
IHostingEnvironment hosting = new HostingEnvironment{ EnvironmentName = environmentName };
Startup startup = new Startup(hosting, PlatformServices.Default.Application);
startup.ConfigureServices(services);
IServiceProvider serviceProvider = services.BuildServiceProvider();
//configure console logging
serviceProvider
.GetService<ILoggerFactory>()
.AddConsole(LogLevel.Debug);
var logger = serviceProvider.GetService<ILoggerFactory>()
.CreateLogger<Program>();
logger.LogDebug("Logger is working!");
// Get Service and call method
var userManager = serviceProvider.GetService<UserManager<ApplicationUser> >();
var emailSender = serviceProvider.GetService<IEmailSender>();
foreach (var user in userManager.Users)
{
Task.Run(async () =>
await emailSender.SendEmailAsync(Startup.SiteSetup, Startup.SmtpSettup, Startup.SiteSetup.Owner.Name, Startup.SiteSetup.Owner.EMail,
$"[{Startup.SiteSetup.Title}] Rappel de votre inscription ({user.UserName})", $"{user.Id}/{user.UserName}/{user.Email}"));
}
}
}
}

@ -1,27 +0,0 @@
using System.Reflection;
using System.Runtime.CompilerServices;
// Information about this assembly is defined by the following attributes.
// Change them to the values specific to your project.
[assembly: AssemblyTitle ("cli")]
[assembly: AssemblyDescription ("")]
[assembly: AssemblyConfiguration ("")]
[assembly: AssemblyCompany ("")]
[assembly: AssemblyProduct ("")]
[assembly: AssemblyCopyright ("Paul Schneider")]
[assembly: AssemblyTrademark ("")]
[assembly: AssemblyCulture ("")]
// The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}".
// The form "{Major}.{Minor}.*" will automatically update the build and revision,
// and "{Major}.{Minor}.{Build}.*" will update just the revision.
[assembly: AssemblyVersion ("1.0.*")]
// The following attributes are used to specify the signing key for the assembly,
// if desired. See the Mono documentation for more information about signing.
//[assembly: AssemblyDelaySign(false)]
//[assembly: AssemblyKeyFile("")]

@ -3,32 +3,71 @@ using Microsoft.AspNet.Hosting;
using Microsoft.Data.Entity;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.OptionsModel;
using Microsoft.Framework.Configuration;
using Newtonsoft.Json;
using Yavsc;
using Yavsc.Models;
using Yavsc.Auth;
using Microsoft.AspNet.Identity.EntityFramework;
using Microsoft.AspNet.Identity;
using Microsoft.Extensions.Configuration;
using Microsoft.AspNet.Identity.EntityFramework;
using Microsoft.Extensions.PlatformAbstractions;
using System;
using System.Threading;
using Yavsc.Server.Helpers;
namespace cli
public class Startup
{
public class Startup
private RequestDelegate app;
public Startup(string hostingFullName, IConfigurationRoot configuration, string connectionString)
{
this.HostingFullName = hostingFullName;
this.Configuration = configuration;
this.ConnectionString = connectionString;
}
public string HostingFullName { get; private set; }
public static SiteSettings SiteSetup { get; private set; }
public static SmtpSettings SmtpSettup { get; private set; }
public IConfigurationRoot Configuration { get; set; }
public string ConnectionString { get; private set; }
public static MonoDataProtectionProvider ProtectionProvider { get; private set; }
public static IdentityOptions AppIdentityOptions { get; private set; }
public Startup(IHostingEnvironment env, IApplicationEnvironment appEnv)
{
var devtag = env.IsDevelopment() ? "D" : "";
var prodtag = env.IsProduction() ? "P" : "";
var stagetag = env.IsStaging() ? "S" : "";
var builder = new ConfigurationBuilder()
.AddJsonFile("appsettings.json")
.AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true);
builder.AddEnvironmentVariables();
HostingFullName = $" [{env.EnvironmentName}:{prodtag}{devtag}{stagetag}]";
// Set up configuration sources.
if (env.IsDevelopment())
{
// For more details on using the user secret store see http://go.microsoft.com/fwlink/?LinkID=532709
// builder.AddUserSecrets();
}
Configuration = builder.Build();
ConnectionString = Configuration["Data:DefaultConnection:ConnectionString"];
}
// Use this method to add services to the container.
public void ConfigureServices(IServiceCollection services)
{
System.Console.WriteLine("Configuring services ...");
var siteSettings = Configuration.GetSection("Site");
services.Configure<SiteSettings>(siteSettings);
var smtpSettings = Configuration.GetSection("Smtp");
services.Configure<SmtpSettings>(smtpSettings);
services.AddEntityFramework()
.AddNpgsql()
.AddDbContext<ApplicationDbContext>(options => options.UseNpgsql(Configuration["Data:DefaultConnection:ConnectionString"]))
@ -39,48 +78,100 @@ namespace cli
});
services.AddOptions();
services.Configure<SiteSettings>((o)=> JsonConvert.PopulateObject(Configuration["Site"],o));
services.Configure<SmtpSettings>((o)=> JsonConvert.PopulateObject(Configuration["Smtp"],o));
ProtectionProvider = new MonoDataProtectionProvider(Configuration["Site:Title"]); ;
services.AddInstance<MonoDataProtectionProvider>
(ProtectionProvider);
services.Configure<SiteSettings>((o) => JsonConvert.PopulateObject(Configuration["Site"], o));
services.Configure<SmtpSettings>((o) => JsonConvert.PopulateObject(Configuration["Smtp"], o));
services.AddIdentity<ApplicationUser, IdentityRole>(
option =>
{
option.User.AllowedUserNameCharacters += " ";
option.User.RequireUniqueEmail = true;
// option.Cookies.ApplicationCookieAuthenticationScheme = Constants.ApplicationAuthenticationSheme;
option.Cookies.ApplicationCookie.LoginPath = "/signin";
// option.Cookies.ApplicationCookie.AuthenticationScheme = Constants.ApplicationAuthenticationSheme;
/*
option.Cookies.ApplicationCookie.DataProtectionProvider = protector;
option.Cookies.ApplicationCookie.LoginPath = new PathString(Constants.LoginPath.Substring(1));
option.Cookies.ApplicationCookie.AccessDeniedPath = new PathString(Constants.AccessDeniedPath.Substring(1));
option.Cookies.ApplicationCookie.AutomaticAuthenticate = true;
option.Cookies.ApplicationCookie.AuthenticationScheme = Constants.ApplicationAuthenticationSheme;
option.Cookies.ApplicationCookieAuthenticationScheme = Constants.ApplicationAuthenticationSheme;
option.Cookies.TwoFactorRememberMeCookie.ExpireTimeSpan = TimeSpan.FromDays(30);
option.Cookies.TwoFactorRememberMeCookie.DataProtectionProvider = protector;
option.Cookies.ExternalCookieAuthenticationScheme = Constants.ExternalAuthenticationSheme;
option.Cookies.ExternalCookie.AutomaticAuthenticate = true;
option.Cookies.ExternalCookie.AuthenticationScheme = Constants.ExternalAuthenticationSheme;
option.Cookies.ExternalCookie.DataProtectionProvider = protector;
*/
}
).AddEntityFrameworkStores<ApplicationDbContext>()
.AddTokenProvider<EmailTokenProvider<ApplicationUser>>(Yavsc.Constants.DefaultFactor)
// .AddTokenProvider<UserTokenProvider>(Constants.DefaultFactor)
// .AddTokenProvider<UserTokenProvider>(Constants.SMSFactor)
// .AddTokenProvider<UserTokenProvider>(Constants.EMailFactor)
// .AddTokenProvider<UserTokenProvider>(Constants.AppFactor)
// .AddDefaultTokenProviders()
;
}
// Use this method to configure the HTTP request pipeline.
public void Configure(IApplicationBuilder app, IOptions<SiteSettings> siteSettingsOptions, IOptions<SmtpSettings> smtpSettingsOptions)
public void Configure(IApplicationBuilder builder, IOptions<SiteSettings> siteSettingsOptions, IOptions<SmtpSettings> smtpSettingsOptions)
{
System.Console.WriteLine("Configuring application ...");
app = builder.UseIdentity().UseMiddleware<InteractiveConsoleMiddleWare>().Build();
SiteSetup = siteSettingsOptions.Value;
SmtpSettup = smtpSettingsOptions.Value;
DbHelpers.ConnectionString = Configuration["Data:DefaultConnection:ConnectionString"];
}
public Startup(IHostingEnvironment env, IApplicationBuilder app)
public void Main(string[] args)
{
var devtag = env.IsDevelopment()?"D":"";
var prodtag = env.IsProduction()?"P":"";
var stagetag = env.IsStaging()?"S":"";
var dbContext = new ApplicationDbContext();
foreach (var user in dbContext.Users) {
Console.WriteLine($"UserName/{user.UserName} FullName/{user.FullName} Email/{user.Email} ");
} /**/
HostingFullName = $" [{env.EnvironmentName}:{prodtag}{devtag}{stagetag}]";
// Set up configuration sources.
var builder = new ConfigurationBuilder()
.AddJsonFile("appsettings.json")
.AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true);
}
if (env.IsDevelopment())
}
internal class TerminalHost
{
private Action<char> _inputDelegate;
public TerminalHost()
{
// For more details on using the user secret store see http://go.microsoft.com/fwlink/?LinkID=532709
// builder.AddUserSecrets();
// Initializes the first delegate to be invoked in the chain.
_inputDelegate = Console.Write;
}
Configuration = builder.Build();
ConnectionString = Configuration["Data:DefaultConnection:ConnectionString"];
internal void Start()
{
CancellationTokenSource tokenSource = new CancellationTokenSource();
while (!tokenSource.IsCancellationRequested) {
ConsoleKeyInfo keyInfo = Console.ReadKey();
_inputDelegate(keyInfo.KeyChar);
}
}
/// <summary>
/// Adds the middleware to the invocation chain.
/// </summary>
/// <param name="middleware"> The middleware to be invoked. </param>
/// <remarks>
/// The middleware function takes an instance of delegate that was previously invoked as an input and returns the currently invoked delegate instance as an output.
/// </remarks>
internal void Use(Func<Action<char>, Action<char>> middleware)
{
// Keeps a reference to the currently invoked delegate instance.
_inputDelegate = middleware(_inputDelegate);
}
}

@ -1,78 +0,0 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Threading.Tasks;
namespace YaDaemon
{
public class YaTaskScheduler : TaskScheduler
{
List<Task> _tasks;
protected override IEnumerable<Task> GetScheduledTasks()
{
return _tasks;
}
protected override void QueueTask(Task task)
{
_tasks.Add(task);
}
protected override bool TryExecuteTaskInline(Task task, bool taskWasPreviouslyQueued)
{
task.Start();
task.Wait();
return task.IsCompleted;
}
}
public class YaDaemon: IDisposable
{
private readonly EventLog _log =
new EventLog("Application") { Source = "Application" };
async void MainLoop(string[] args)
{
}
async Task StartAsync(string[] args)
{
await Task.Run(() => {
OnStart(args);
} );
}
protected void OnContinue()
{
}
protected void OnShutdown()
{
}
protected void OnStart(string[] args)
{
_log.WriteEntry("Test from YaDaemon.", EventLogEntryType.Information, 1);
_log.WriteEntry("YaDaemon started.");
Console.WriteLine("YaDaemon started");
}
protected void OnStop()
{
_log.WriteEntry("YaDaemon stopped.");
Console.WriteLine("YaDaemon stopped");
}
public void Dispose()
{
}
}
}

@ -35,5 +35,10 @@
"Host": "localhost",
"Port": 25,
"EnableSSL": false
},
"Data": {
"DefaultConnection": {
"ConnectionString": "Server=localhost;Port=5432;Database=YavscDev;Username=yavscdev;Password=admin;"
}
}
}

@ -1,240 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{E7C9D6BF-54DC-4E18-8F25-C4BD4BE71ACC}</ProjectGuid>
<OutputType>Exe</OutputType>
<RootNamespace>cli</RootNamespace>
<AssemblyName>cli</AssemblyName>
<TargetFrameworkVersion>v4.5.1</TargetFrameworkVersion>
<ProductVersion>8.0.30703</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug</OutputPath>
<DefineConstants>DEBUG;</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Externalconsole>true</Externalconsole>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>full</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release</OutputPath>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Externalconsole>true</Externalconsole>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="Newtonsoft.Json">
<HintPath>..\packages\Newtonsoft.Json.9.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.SignalR.Client">
<HintPath>..\packages\Microsoft.AspNet.SignalR.Client.2.2.1\lib\net45\Microsoft.AspNet.SignalR.Client.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Web.Infrastructure">
<HintPath>..\packages\Microsoft.Web.Infrastructure.1.0.0.0\lib\net40\Microsoft.Web.Infrastructure.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Configuration.UserSecrets">
<HintPath>..\packages\Microsoft.Extensions.Configuration.UserSecrets.1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Configuration.UserSecrets.dll</HintPath>
</Reference>
<Reference Include="EntityFramework.Commands">
<HintPath>..\packages\EntityFramework.Commands.7.0.0-rc1-final\lib\net451\EntityFramework.Commands.dll</HintPath>
</Reference>
<Reference Include="Microsoft.CodeAnalysis.CSharp">
<HintPath>..\..\..\..\..\srv\www\dnx\runtimes\dnx-mono.1.0.0-rc1-update2\bin\Microsoft.CodeAnalysis.CSharp.dll</HintPath>
</Reference>
<Reference Include="Microsoft.CodeAnalysis">
<HintPath>..\..\..\..\..\srv\www\dnx\runtimes\dnx-mono.1.0.0-rc1-update2\bin\Microsoft.CodeAnalysis.dll</HintPath>
</Reference>
<Reference Include="System.Collections.Immutable">
<HintPath>..\..\..\..\..\srv\www\dnx\runtimes\dnx-mono.1.0.0-rc1-update2\bin\System.Collections.Immutable.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Hosting">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Hosting\1.0.0-rc1-final\lib\net451\Microsoft.AspNet.Hosting.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Identity">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Identity\3.0.0-rc1-final\lib\net451\Microsoft.AspNet.Identity.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Framework.ConfigurationModel">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Framework.ConfigurationModel\1.0.0-beta4\lib\net45\Microsoft.Framework.ConfigurationModel.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Framework.Configuration.Json">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Framework.Configuration.Json\1.0.0-beta8\lib\net45\Microsoft.Framework.Configuration.Json.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.OptionsModel">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.OptionsModel\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.OptionsModel.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.CodeGeneration.EntityFramework">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.CodeGeneration.EntityFramework\1.0.0-rc1-final\lib\dnx451\Microsoft.Extensions.CodeGeneration.EntityFramework.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Localization">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Localization\1.0.0-rc1-final\lib\net451\Microsoft.AspNet.Localization.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Primitives">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.Primitives\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Primitives.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Identity.EntityFramework">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Identity.EntityFramework\3.0.0-rc1-final\lib\net451\Microsoft.AspNet.Identity.EntityFramework.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Http.Extensions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Http.Extensions\1.0.0-rc1-final\lib\net451\Microsoft.AspNet.Http.Extensions.dll</HintPath>
</Reference>
<Reference Include="EntityFramework7.Npgsql.Design">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\EntityFramework7.Npgsql.Design\3.1.0-rc1-5\lib\net451\EntityFramework7.Npgsql.Design.dll</HintPath>
</Reference>
<Reference Include="EntityFramework7.Npgsql">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\EntityFramework7.Npgsql\3.1.0-rc1-3\lib\net451\EntityFramework7.Npgsql.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Diagnostics.Entity">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Diagnostics.Entity\7.0.0-rc1-final\lib\net451\Microsoft.AspNet.Diagnostics.Entity.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Configuration.EnvironmentVariables">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.Configuration.EnvironmentVariables\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Configuration.EnvironmentVariables.dll</HintPath>
</Reference>
<Reference Include="EntityFramework.Relational">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\EntityFramework.Relational\7.0.0-rc1-final\lib\net451\EntityFramework.Relational.dll</HintPath>
</Reference>
<Reference Include="EntityFramework.Core">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\EntityFramework.Core\7.0.0-rc1-final\lib\net451\EntityFramework.Core.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Mvc.Localization">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Mvc.Localization\6.0.0-rc1-final\lib\net451\Microsoft.AspNet.Mvc.Localization.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Localization">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.Localization\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Localization.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Framework.Configuration.Abstractions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Framework.Configuration.Abstractions\1.0.0-beta8\lib\net45\Microsoft.Framework.Configuration.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Hosting.Abstractions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Hosting.Abstractions\1.0.0-rc1-final\lib\net451\Microsoft.AspNet.Hosting.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Mvc.Abstractions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Mvc.Abstractions\6.0.0-rc1-final\lib\net451\Microsoft.AspNet.Mvc.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Http">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Http\1.0.0-rc1-final\lib\net451\Microsoft.AspNet.Http.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.IISPlatformHandler">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.IISPlatformHandler\1.0.0-rc1-final\lib\net451\Microsoft.AspNet.IISPlatformHandler.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Configuration.Abstractions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.Configuration.Abstractions\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Configuration.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Framework.Configuration">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Framework.Configuration\1.0.0-beta8\lib\net45\Microsoft.Framework.Configuration.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Http.Abstractions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.Http.Abstractions\1.0.0-rc1-final\lib\net451\Microsoft.AspNet.Http.Abstractions.dll</HintPath>
</Reference>
<Reference Include="System.Data" />
<Reference Include="System.Core" />
<Reference Include="System.Design" />
<Reference Include="System.ComponentModel.DataAnnotations" />
<Reference Include="System.ComponentModel.Composition" />
<Reference Include="Microsoft.Extensions.DependencyInjection.Abstractions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.DependencyInjection.Abstractions\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.DependencyInjection.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.DependencyInjection">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.DependencyInjection\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.DependencyInjection.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Logging">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.Logging\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Logging.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Logging.Console">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.Logging.Console\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Logging.Console.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Logging.Abstractions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.Logging.Abstractions\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Logging.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Logging.Debug">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.Logging.Debug\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Logging.Debug.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.FileProviders.Abstractions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.FileProviders.Abstractions\1.0.0-rc1-final\lib\net451\Microsoft.AspNet.FileProviders.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Configuration.FileExtensions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.Configuration.FileExtensions\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Configuration.FileExtensions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.FileProviders.Physical">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.AspNet.FileProviders.Physical\1.0.0-rc1-final\lib\net451\Microsoft.AspNet.FileProviders.Physical.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Configuration">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Extensions.Configuration\1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Configuration.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Framework.Configuration.FileExtensions">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\Microsoft.Framework.Configuration.FileExtensions\1.0.0-beta8\lib\net45\Microsoft.Framework.Configuration.FileExtensions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Caching.Abstractions">
<HintPath>packages\Microsoft.Extensions.Caching.Abstractions.1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Caching.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Caching.Memory">
<HintPath>packages\Microsoft.Extensions.Caching.Memory.1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Caching.Memory.dll</HintPath>
</Reference>
<Reference Include="Remotion.Linq">
<HintPath>packages\Remotion.Linq.2.0.1\lib\net45\Remotion.Linq.dll</HintPath>
</Reference>
<Reference Include="System.Diagnostics.DiagnosticSource">
<HintPath>..\..\..\..\..\srv\www\dnx\packages\System.Diagnostics.DiagnosticSource\4.0.0-beta-23516\lib\portable-net45+win8+wp8+wpa81\System.Diagnostics.DiagnosticSource.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Localization.Abstractions">
<HintPath>packages\Microsoft.Extensions.Localization.Abstractions.1.0.0-rc1-final\lib\net451\Microsoft.Extensions.Localization.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.Authentication.Cookies">
<HintPath>packages\Microsoft.AspNet.Authentication.Cookies.1.0.0-rc1-final\lib\net451\Microsoft.AspNet.Authentication.Cookies.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.DataProtection">
<HintPath>packages\Microsoft.AspNet.DataProtection.1.0.0-rc1-final\lib\net451\Microsoft.AspNet.DataProtection.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNet.DataProtection.Abstractions">
<HintPath>packages\Microsoft.AspNet.DataProtection.Abstractions.1.0.0-rc1-final\lib\net451\Microsoft.AspNet.DataProtection.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Owin">
<HintPath>packages\Owin.1.0\lib\net40\Owin.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Owin">
<HintPath>packages\Microsoft.Owin.4.0.0\lib\net451\Microsoft.Owin.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Dnx.DesignTimeHost">
<HintPath>..\..\..\..\..\srv\www\dnx\runtimes\dnx-mono.1.0.0-rc1-update2\bin\lib\Microsoft.Dnx.DesignTimeHost\Microsoft.Dnx.DesignTimeHost.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Dnx">
<HintPath>..\..\..\..\..\srv\www\dnx\runtimes\dnx-mono.1.0.0-rc1-update2\bin\Microsoft.Dnx.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Dnx.Host.Mono">
<HintPath>..\..\..\..\..\srv\www\dnx\runtimes\dnx-mono.1.0.0-rc1-update2\bin\Microsoft.Dnx.Host.Mono.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.CommandLineUtils">
<HintPath>packages\Microsoft.Extensions.CommandLineUtils.1.1.1\lib\net451\Microsoft.Extensions.CommandLineUtils.dll</HintPath>
</Reference>
<Reference Include="Yavsc.Abstract">
<HintPath>packages\Yavsc.Abstract.1.0.5-rc7\lib\portable-net45+win8+wp8+wpa81+Xamarin.Mac+MonoAndroid10+MonoTouch10+Xamarin.iOS10\Yavsc.Abstract.dll</HintPath>
</Reference>
<Reference Include="Yavsc.Server">
<HintPath>packages\Yavsc.Server.1.0.1-rc1\lib\portable-net45+win8+wp8+wpa81+Xamarin.Mac+MonoAndroid10+MonoTouch10+Xamarin.iOS10\Yavsc.Server.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Startup.cs" />
</ItemGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<ItemGroup>
<None Include="packages.config" />
<None Include="appsettings.Development.json">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
<None Include="appsettings.json">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
</ItemGroup>
</Project>

@ -1,35 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="EntityFramework.Commands" version="7.0.0-rc1-final" targetFramework="net451" />
<package id="EntityFramework.Core" version="7.0.0-rc1-final" targetFramework="net451" />
<package id="EntityFramework.MicrosoftSqlServer" version="7.0.0-rc1-final" targetFramework="net451" />
<package id="EntityFramework.Relational" version="7.0.0-rc1-final" targetFramework="net451" />
<package id="EntityFramework7.Npgsql" version="3.1.0-rc1-3" targetFramework="net451" />
<package id="EntityFramework7.Npgsql.Design" version="3.1.0-rc1-5" targetFramework="net451" />
<package id="Microsoft.AspNet.Authentication.Cookies" version="1.0.0-rc1-final" targetFramework="net451" />
<package id="Microsoft.AspNet.DataProtection" version="1.0.0-rc1-final" targetFramework="net451" />
<package id="Microsoft.AspNet.DataProtection.Abstractions" version="1.0.0-rc1-final" targetFramework="net451" />
<package id="Microsoft.AspNet.Http.Abstractions" version="1.0.0-rc1-final" targetFramework="net451" />
<package id="Microsoft.AspNet.Mvc" version="5.2.4" targetFramework="net451" />
<package id="Microsoft.AspNet.Razor" version="3.2.4" targetFramework="net451" />
<package id="Microsoft.AspNet.SignalR.Client" version="2.2.1" targetFramework="net451" />
<package id="Microsoft.AspNet.WebPages" version="3.2.4" targetFramework="net451" />
<package id="Microsoft.Extensions.Caching.Abstractions" version="1.0.0-rc1-final" targetFramework="net451" />
<package id="Microsoft.Extensions.Caching.Memory" version="1.0.0-rc1-final" targetFramework="net451" />
<package id="Microsoft.Extensions.CommandLineUtils" version="1.1.1" targetFramework="net451" />
<package id="Microsoft.Extensions.Configuration.FileExtensions" version="1.0.0-rc1-final" targetFramework="net451" />
<package id="Microsoft.Extensions.Configuration.UserSecrets" version="1.0.0-rc1-final" targetFramework="net451" />
<package id="Microsoft.Extensions.DependencyInjection.Abstractions" version="1.0.0-rc1-final" targetFramework="net451" />
<package id="Microsoft.Extensions.Localization.Abstractions" version="1.0.0-rc1-final" targetFramework="net451" />
<package id="Microsoft.Extensions.Options" version="0.0.1-alpha" targetFramework="net451" />
<package id="Microsoft.Framework.Configuration.FileExtensions" version="1.0.0-beta8" targetFramework="net451" />
<package id="Microsoft.Owin" version="4.0.0" targetFramework="net451" />
<package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net451" />
<package id="Newtonsoft.Json" version="9.0.1" targetFramework="net451" />
<package id="Owin" version="1.0" targetFramework="net451" />
<package id="Remotion.Linq" version="2.0.1" targetFramework="net451" />
<package id="System.Diagnostics.DiagnosticSource" version="4.0.0-beta-23516" targetFramework="net45" />
<package id="Yavsc.Abstract" version="1.0.5-rc7" targetFramework="net451" />
<package id="Yavsc.Server" version="1.0.1-rc1" targetFramework="net451" />
</packages>

@ -0,0 +1,41 @@
{
"version": "1.0.0-*",
"commands": {
"run": "run"
},
"resource": "Resources/**/*.resx",
"buildOptions": {
"debugType": "full",
"emitEntryPoint": true,
"compile": {
"include": "*.cs",
"exclude": [
"contrib"
]
},
"embed": [
"Resources/**/*.resx"
]
},
"dependencies": {
"Yavsc.Server": {
"target": "project",
"type": "build"
},
"Microsoft.Framework.Configuration.Json": "1.0.0-beta8",
"Microsoft.Framework.ConfigurationModel.Json": "1.0.0-beta4",
"Microsoft.Extensions.Configuration.Json": "1.0.0-rc1-final",
"Microsoft.AspNet.IISPlatformHandler": "1.0.0-rc1-*",
"Microsoft.AspNet.Hosting": "1.0.0-rc1-*",
"Microsoft.Extensions.Logging.Console": "1.0.0-rc1-final",
"Microsoft.Extensions.DependencyInjection": "1.0.0-rc1-final"
},
"frameworks": {
"dnx451": {
},
"net451": {
"dependencies": {}
}
}
}

File diff suppressed because it is too large Load Diff
Loading…