Should I add other files to git except .cpp? - c++

When I created a C++ console project in Visual Studio, I found that besides .cpp files, I had other files like .sln, .vcxproj, .filters, .user.
Should I add them to Git repo?

You can download a .gitignore for Visual Studio. It will make sure only what's necessary to open and work on the project would be tracked, the rest would be ignored.
You can download one from here:
https://github.com/github/gitignore/blob/master/VisualStudio.gitignore

Related

Pushing source files to bitbucket in visual studio

I would like to know how to push .cpp files and .h files in visual studio 2017. whenever I do a commit i push the solution and everything in the build folder. I just want to be able to push .cpp files and header files whenever i edit them. Im using windows 10 but I do recall on linux, using vim, the task was simpler, because i used the command line.
Add a .gitignore to your root of this solution with following contents:
build
This should ignore all the files and folders within you build directory.
I think the best thing to do is just to learn the command line syntax on windows with Git bash. Most online help is given with the command line syntax in mind.

What files from Visual Studio 2017 Project/Solution should be in a SVN ignore?

I'm working on a solution (C#) with 3 projects in it (one library and two applications) and I wonder what is the bare minimum of files you need to commit to be able to pull off a fresh solution and get it to work right away?
Obviously all source files, *.sln, *.csproj are needed and not the obj folder or bin folder (unless I want to keep a working copy of the compiled files).
But do I need to commit the:
Properties folder
.vs folder
*.resx
*.config
I have Googled it but all I found was a list of the file types, but no explanation of what files where critical to make the solution/project load and compile.
[EDIT]
It has been suggested that this is the same question as: Should I add the Visual Studio 2015 .vs folder to source control?
The question is not related to only the .vs folder, but to all project/solution files.
Though SVN and Git are different Version Control System, I think the files that should be excluded in the Version Control System should be similar. This file is a ignore file for Git (an .gitignore), but should be work as it should in SVN Version Control Systems.
https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
This file is often used in various places like Github Destktop, or the Github Site itself.

Force Eclipse SVN to check files changed outside Eclipse

I am working on a project containing java and c++ files. The java files are edited in Eclipse, and c++ files in Visual Studio. I use SVN on Eclipse to commit changed files into repository. There is no problem with files edited in Eclipse itself, however, the files edited outside Eclipse are not recognized as changed (outgoing) unless I open them in Eclipse. Is there a way to force Eclipse to check all the files for changes, so that I do not need to keep track of changed c++ files myself?
Use the "refresh" command on the folder containing the changed files.

Netbeans ignoring files

In Netbeans when I create a new C++ project from existing sources only the Makefile appears to be under Git version control. The other files (.h, .cpp) all appear to be ignored (grayed out) when viewing from the Projects or Files windows in Netbeans.
How do I make these files tracked?
I have already tried the right-click unignore option.
I do not have a .gitignore file at this point.
You can ignore files in git in other ways than using the .gitignore.
In project folder check the file .git/info/exclude - you can exclude files which yu don't want to keep in .gitignore (which is usually shared with other coders)
You can also ignore files on a global level. Check the settings of Netbeans - it might have a global ignore list used by git.

How do you include LuaPlus into your project?

I downloaded the visual2008 file from here(http://luaplus.org/projects/luaplus/files), but I don't know how to add it to my project. It's not like the other libraries where I just had to add the include directory to my Visual Studio folder and the bin to my system32 or project folder. There are no header files either. I'm using Visual Studio 2010 professional.
I remember downloading LuaPlus for the first time and thinking the same thing--"Where are the headers?" What you'll want to do is just clone the repository located on GitHub and use that to build LuaPlus yourself. The author helpfully included batch files to create different project files (incl. VS2010). You can then use the project files to build LuaPlus and you'll naturally also have the headers & source files as well. I don't recall if it included Lua's source already or if you have to do it yourself manually (this only takes a minute to do, however).