asp.net-mvc - git 和 ASP MVC

标签 asp.net-mvc git gitignore

有人知道关于使用 gitASP.NET MVC 设置新项目的好文章吗?

只是想知道要包含什么和忽略以及如何部署。

最佳答案

Gitignore

您询问了要忽略的内容——这是我对 ASP.NET MVC 项目的默认 .gitignore:

###################
# compiled source #
###################
*.com
*.class
*.dll
*.exe
*.pdb
*.dll.config
*.cache
*.suo
# Include dlls if they’re in the NuGet packages directory
!/packages/*/lib/*.dll
!/packages/*/lib/*/*.dll
# Include dlls if they're in the CommonReferences directory
!*CommonReferences/*.dll
####################
# VS Upgrade stuff #
####################
UpgradeLog.XML
_UpgradeReport_Files/
###############
# Directories #
###############
bin/
obj/
TestResults/
###################
# Web publish log #
###################
*.Publish.xml
#############
# Resharper #
#############
/_ReSharper.*
*.ReSharper.*
############
# Packages #
############
# it’s better to unpack these files and commit the raw source
# git has its own built in compression methods
*.7z
*.dmg
*.gz
*.iso
*.jar
*.rar
*.tar
*.zip
######################
# Logs and databases #
######################
*.log
*.sqlite
# OS generated files #
######################
.DS_Store?
ehthumbs.db
Icon?
Thumbs.db

设置新项目

要获得有关设置新项目的帮助,我会安装 msysgit因为你很可能在 Windows 上查看 learn.github了解如何开始使用 git。 当然是高手(双向飞碟)suggests you do most everything from the console ——我倾向于同意他的观点。恕我直言,Git 更容易。如果你想要一个方便的 git 引用,请查看 git reference .

部署

正如其他人已经提到的——查看 AppHarbor用于部署。这些人的目标是成为“ASP.NET 的 Heroku”。

关于asp.net-mvc - git 和 ASP MVC,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/639647/

相关文章:

javascript - 单击复选框后如何调用 Controller 方法?

javascript - 动态添加字段输入不存储值并传递给 Controller

git - 为什么 git branch 没有显示一个分支?

git - github 上的 pull 请求 - 显示从 master 重新提交的提交

regex - 如何替换 Git 历史中的单词并正确调试相关问题?

asp.net-mvc - 缩小的脚本仅在MVC4 BundleConfig中

mysql - 在 MVC Entity Framework 6 的 Controller 中使用存储的 MySQL 过程从多个表获取结果

git - 如何在 .gitignore 中获得等效于 .hgignore 的正则表达式 ^var/(?!\log|.dummy) 和 ^var/log/(?!\.dummy) ?

reactjs - touch .gitignore 不创建文件

Gitignore 星号代字号