xcode4 template format question - templates

xcode4 uses new format for project templates (xctemplate). With existing templates I was able to get everything I needed except adding a file into the project without copying it. I need all the projects created from my template to use shared resource, so I could update all projects at once updating just one file. Thanks!

Did you try hard link to the file from your template directory?

Related

Suggestions on how to build a library that can be used in many of my applications

In the past I have created a jar file that contained many "helper functions" that I used and made common to many different applications. I felt this was important as anytime I used my "helper" jar file in any new applications or when making changes to any existing ones, the latest and most up to date version of my "helper" jar was always used. It was developed separately and had it's own version control.
I'm looking to do something similar with C/C++
At the moment I have a collection of headers, doing something similar to my "helper" jar in java but finding it cumbersome managing changes, ensuring the most up to date collections are used. So for example, if I made some changes to these "helper" headers, I need to copy them into each project and rebuild.
If we take the below as an example of what I do in Java;
and the below is the structure that I'd like to do something similar with in C++;
I'd like some way of keeping my_includes separate so that any changes I made to my_includes are automatically included in any existing or new applications, in the way Utilities.jar is in the above Java example
I accept that I cant build a library or such as it won't then be as portable, right?
I suspect I'm missing something quite obvious, just not to me.
All helpful comments appreciated, thanks in advance...
At first you could create a library from your utilitis.cpp and all include files independently and add this library to any project. I just provide URL for sample generate the static and shared library.
Create static and shared library (GCC)
And then you can add custom include files to any project in c++ just need to add the specific directories to your include Path in compile time base your platform or if you use cmake you can edit the "include_directories". And also you should link the generated library to your project as described in provided URL.

Visual Studio - How to create and use a template?

I have got the SFML library, for graphics etc for C++. Is there a way to save a template with its settings, and then create a new project with that template? This would much easier, instead of linking up the library and all the files every time. I have tried creating a template, but when I open it, there is no code. Thanks

Errors in Generated Files for WinRT XAML DirectX Universal App

I started a project from the DirectX and XAML template and made some small edits to the Direct3D-only portion of the project.
Now I get a number of errors in the xamltypeinfo.g.cpp file, stating that the Common::NavigationHelper class doesn't exist. Hovever I can validate that it's definitely a class included in the template, but it looks like whatever generated these files didn't include it.
I don't want to go messing around with generated files, and I haven't touched any of the XAML code at all in the template.
I created another project walking through the steps I had performed, and ran a diff on the two projects. The entire Common directory (and namespace, which included NavigationHelper) was unique to the original project.
I then remembered that at one point I had accidentally added a XAML page. I promptly removed it, which seems to have left these files included but they weren't included by another other file. Visual Studio still generated references to them, thus the errors.
It looks like if you add any XAML pages that require navigation, pulling them out is not as simple as removing the file. You must also remove the navigation infrastructure as well, by removing all references to the Common folder that were added to your project.

How to customize templates in vim-latex

I'm trying to use vim-latex, and as the existing templates are annoyingly simple and unsatisfactory, I'm trying to build some of my own. However, after composing my own templates and stored in "/ftplugin/latex-suite/templates", nothing happens. The software simply won't scan for new templates. Did I miss some steps to make it work?
I found out what's happening. If there's any one who ran into a similar problem, please check whether you have installed that plugin in your OS repo. I'm using fedora, and accidentally installed vim-latex from the repo, thus the place those templates are really located is
"/usr/share/vim/vimfiles/ftplugin/latex-suite/templates".
So either remove the add-on installed from the OS repo and reinstall it in "~/.vim/", or copy the templates to that folder is the solution to this problem.
I experienced the same problem using Xubuntu. There the template files are stored at /usr/share/vim/addons/ftplugin/latex-suite/templates/. But simply adding a new template file there won't create a new menu entry in gvim: you must also make a soft link from your new template file in the directory above to /var/lib/vim/addons/ftplugin/latex-suite/templates/your_new_template.tex

Retroactively apply Netbeans template

I have a project with a decent number of files, and but I've only now come to licensing it. I have my license template all set up, but none of the files in my project were built after this template was created. Is there a way to retroactively apply this header template to automatically give all the files in my project license headers?
Thanks!
Not with just Netbeans no, but maven-license-plugin should do exactly what you want.
Alternatively, you could use sed. (This what I ended up doing.)