zoukankan      html  css  js  c++  java
  • # asp.net core 1.0 项目结构

    1.环境

    开发:VS2015

    平台:window 7

    2.解决方案级别结构

    创建一个ASP.NET 5 Template Empty项目:

    src:存放项目(projects)

    global.json:全局配置

    
    {
    
      "projects": [ "src", "test" ],
    
      "sdk": {
    
        "version": "1.0.0-rc1-update1",
    
      }}
    
    

    可以通过F12查看Json的定义(http://json-schema.org/draft-04/schema#):

    
    {
    
     "title": "JSON schema for the ASP.NET global configuration files",
    
     "$schema": "http://json-schema.org/draft-04/schema#",
    
     "type": "object",
    
     "additionalProperties": true,
    
     "required": [ "projects" ],
    
     "properties": {
    
     "projects": {
    
     "type": "array",
    
     "description": "A list of project folders relative to this file.",
    
     "items": {
    
     "type": "string"
    
     }
    
     },
    
     "packages": {
    
     "type": "string",
    
     "description": "The location to store packages"
    
     },
    
     "sdk": {
    
     "type": "object",
    
     "description": "Specify information about the SDK.",
    
     "properties": {
    
     "version": {
    
     "type": "string",
    
     "description": "The version of the SDK to use."
    
     },
    
     "architecture": {
    
     "enum": [ "x64", "x86" ],
    
     "description": "Specify which processor architecture to target."
    
     },
    
     "runtime": {
    
     "enum": [ "clr", "coreclr" ],
    
     "description": "Chose which runtime to target."
    
     }
    
     }
    
     }
    
     }
    
    }
    
    
    1. projects:A list of project folders relative to this file.

    2. sdk:Specify information about the SDK.

      sdk.version:The version of the SDK to use.

      sdk.architecture:Specify which processor architecture to target.

      sdk.runtime:Chose which runtime to target.

    3. packages:The location to store packages

    3.项目级别结构

    Properties/launchSettings.json (仅 Windows 平台有)

    wwwroot:wwwroot就是运行时网站的根目录(可以在 project.json 内重置)

    wwwrootweb.config

    project.json:(项目核心配置文件,项目依赖、工具、构建选项、运行时选项、发布选项等)

    project.lock.json (运行过 dnu restore 生成)

    Dockerfile (Windows 平台没有)

    {your-project-name}.xproj (仅 Windows 平台有)

    Startup.cs

  • 相关阅读:
    初始化Winsock库
    memset与初始化
    老板不在,嚣张的正则
    教研室的下午,取快递的一天
    教研室的夜晚
    真不知道起什么名字了
    任性就是没长大咯
    难得起得早,难得周六上班
    工欲学其语,必先装软件
    151008-JS初级完成,PHP入门(变量常量等)-没假放了
  • 原文地址:https://www.cnblogs.com/pengzhen/p/5753526.html
Copyright © 2011-2022 走看看