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.)
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.)
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
[Bb]in/
. Your pattern */[Bb]in/*
doesn't work for me (using Git on Windows). –
Hocuspocus 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/*
@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
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.
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.
_Pvt_Extensions
? –
Dorsal © 2022 - 2024 — McMap. All rights reserved.