LightSwitch 项目:要签入哪些文件,要忽略哪些文件?

发布于 2024-11-30 08:14:51 字数 104 浏览 2 评论 0原文

在 LightSwitch 应用程序中,我应该忽略哪些文件和文件夹而不将其保留在源代码管理中?

(我正在使用 Git,我想知道要在 .gitignore 文件中放入什么内容。)

In a LightSwitch application, what files and folders should I ignore and not keep in source control?

(I'm using Git, and I'm wondering what to put in the .gitignore file.)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

独夜无伴 2024-12-07 08:14:51

来自我关于这个问题的文章(包括一些DevExpress 等的额外内容):

*.lsproj.user
ServiceConfiguration.cscfg
*/_Pvt_Extensions/*
*/GeneratedArtifacts/*
*.csproj.user
*.vbproj.user
*/[Oo]bj/*
*/[Bb]in/*
*.suo
*DXCore.Solution
[Tt]humbs.db 
*.user
*.bak.* 
*.bak 
*.[Cc]ache
*/[Pp]ublish/*
*.vssscc
*.vs10x
*/[Dd]otfuscated/*
[Dd]otfuscated/*
*.vsp
[Nn][Dd]epend[Oo]ut/*
*.licx
*.docstates
*.cscfg
*.csdef

From my article on this very question (includes some extra's for DevExpress and so on):

*.lsproj.user
ServiceConfiguration.cscfg
*/_Pvt_Extensions/*
*/GeneratedArtifacts/*
*.csproj.user
*.vbproj.user
*/[Oo]bj/*
*/[Bb]in/*
*.suo
*DXCore.Solution
[Tt]humbs.db 
*.user
*.bak.* 
*.bak 
*.[Cc]ache
*/[Pp]ublish/*
*.vssscc
*.vs10x
*/[Dd]otfuscated/*
[Dd]otfuscated/*
*.vsp
[Nn][Dd]epend[Oo]ut/*
*.licx
*.docstates
*.cscfg
*.csdef
妳是的陽光 2024-12-07 08:14:51

我相信这是源代码控制中不需要的内容的全面列表。

_Pvt_扩展\
bin\调试
bin\发布
客户端\bin
客户端\obj
客户端生成\bin
客户端生成\obj
常见\bin
通用\obj
服务器\bin
服务器\obj
服务器生成\bin
ServerGenerate\obj

不确定 gitignore 语法,但在 Mercurial 中我的 .hgignore 包含:

*/[Oo]bj/*  
*/[Bb]in/*  
*.suo  
*.lsproj.user  
*/_Pvt_Extensions/*  
*/GeneratedArtifacts/*  

I believe this is a comprehensive list of what isn't needed in source control.

_Pvt_Extensions\
bin\Debug
bin\Release
Client\bin
Client\obj
ClientGenerated\bin
ClientGenerated\obj
Common\bin
Common\obj
Server\bin
Server\obj
ServerGenerated\bin
ServerGenerated\obj

Not sure about git ignore syntax but in Mercurial my .hgignore contains:

*/[Oo]bj/*  
*/[Bb]in/*  
*.suo  
*.lsproj.user  
*/_Pvt_Extensions/*  
*/GeneratedArtifacts/*  
绝不服输 2024-12-07 08:14:51

@罗伯特·麦克莱恩 谢谢!

我还应该补充一点,.gitignore 似乎无法在 Windows 上运行。因此,我将排除项放在 .git/info/exclude 中 [.git 是本地存储库工作目录中的隐藏文件夹]

注意:/info/exclude 规则不会与存储库一起提交,因此不会与其他人共享。

这是 Robert 文件的 git 版本:

# ignore for Lightswitch
*.lsproj.user
ServiceConfiguration.cscfg
_Pvt_Extensions/
GeneratedArtifacts/

# ignore for Visual Studio
*.csproj.user
*.vbproj.user
[Oo]bj/
[Bb]in/
*.suo

*DXCore.Solution
[Tt]humbs.db 
*.user
*.bak.* 
*.bak 
*.[Cc]ache
[Pp]ublish/
*.vssscc
*.vs10x
[Dd]otfuscated/
[Dd]otfuscated/
*.vsp
[Nn][Dd]epend[Oo]ut/
*.licx
*.docstates
*.cscfg
*.csdef

@Robert Maclean Thanks!

I should also add that .gitignore does not seem to work from windows. So instead I put the exclusions in .git/info/exclude [.git is a hidden folder in your local repository working directory]

Note: The /info/exclude rules are not committed with the repo so they are not shared with others.

Here is the git version of Robert's file:

# ignore for Lightswitch
*.lsproj.user
ServiceConfiguration.cscfg
_Pvt_Extensions/
GeneratedArtifacts/

# ignore for Visual Studio
*.csproj.user
*.vbproj.user
[Oo]bj/
[Bb]in/
*.suo

*DXCore.Solution
[Tt]humbs.db 
*.user
*.bak.* 
*.bak 
*.[Cc]ache
[Pp]ublish/
*.vssscc
*.vs10x
[Dd]otfuscated/
[Dd]otfuscated/
*.vsp
[Nn][Dd]epend[Oo]ut/
*.licx
*.docstates
*.cscfg
*.csdef
韵柒 2024-12-07 08:14:51

如果要发布到 Windows Azure,请务必将 azureconfig.txt 添加到忽略列表(git 中的 .gitignore 文件)。 azureconfig.txt 文件包含非常敏感的 Azure 帐户信息。

If you will be publishing to Windows Azure, be sure to add azureconfig.txt to the ignore list (.gitignore file in git). The azureconfig.txt file contains very sensitive Azure account information.

柠檬心 2024-12-07 08:14:51

就源代码控制而言,您可以安全地“忽略”ClientGenerate & ServerGenerate 文件夹,因为每次构建项目时它们都会重新生成。

As far as source control goes, you can safely "ignore" the ClientGenerated & ServerGenerated folders, as they'll be re-generated each time you build your project.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文