I installed SQLite into my WPF project via Nuget. Then added the entire project to a remote repo. Then I cloned the project on another machine, and had a broken build.
x64\SQLite.Interop.dll was missing.
I'm puzzled why Git didn't include one file from my project. I checked the repo on BitBucket and confirmed it is not there. Git status reports nothing to commit, working directory clean
It added the x86 version, but not the x64 version, I can't imagine why.
(project)\x64\SQLite.Interop.dll Git ignored this file!
(project)\x86\SQLite.Interop.dll
You might want to check the .gitignore file at the root of the repo. If it contains for example x64, it would ignore this file.
There would be two main possibilities then:
edit this file to fit your need
or force this file to be added; ie: git add -f x64/SQLite.Interop.dll
However, committing binary files is often frowned upon. It's true in particular if you want to keep up to date with the latest package, hence if you plan to commit new versions of the dlls on a regular basis.
You might rather want to consider Nuget package restore feature. Basically the idea is that you commit a config file, and the client will automatically download the corresponding packages.
Related
I am setting up am Angular.js project from scratch. And I would like to keep it on Github inside a repository.
I have a simple question but I couldn't find a comprehensive answer for it. After establishing the project basic scaffold, and installing some node modules with NPM, there are many libraries, node-modules and etc in project structure. Also there are files of the framework for example Sails framework. Since a developer can install them by running npm install, which files should I push into the repository? Which ones don't need to be pushed?
The problem is, Source tree shows all new files as not staged, and I am confused which one I should exclude, which I should commit.
From personal experience, 2 types of files can be ignored in git
3rd party libraries, which can be installed using npm/bower etc.
Generated files, like css generated from less, minified js files, etc.
which files should I push into the repository?
Any files related to your application that contain business logic, routing, or other files that you've added to the project that are required for your app to run.
Which ones don't need to be pushed?
You should add node_modules to your .gitignore file. In almost all scenarios it would be unnecessary to include installed packages because your package.json maintains a list of packages to install when calling npm install.
If you're not sure about where to start with a .gitignore file, this is the defacto Node.js .gitignore file that is generated by GitHub & many popular IDE's. Just add that file to your project folder and git will automatically detect it, you should include your .gitignore as part of your repository files.
Additionally, if you're using Bower for front-end package management, you should add your bower.json to your repository and add the bower_components directory to your .gitignore.
We are developing a project built with yeoman angular generator. Now appears the need of "puppetize" it for deployment.
Obviusly the machine serving client part should be provided with a compiled (minimified, optimized) version of the angular project. But I have no idea if we should store it on our bitbucket repo -for example on the master branch when tagging a new release-
I couldn't find any post about this practice and I could use some help.
There are some facts about angular minified version:
It is uglificated and minificated, so code is unreadable and hard to change.
It demands compilation with tool like gruntjs, which takes some time to build each time.
It works on server, but when you choose to deploy non minificated, revisioned version, you can have other problems during adding new versions to same repo - scripts have same name and are cached in browser and possible other problems.
You decided to deploy compiled version to a client machine.
If you are using version control like git. you can add to repo a folder with compiled version, so your repository have sources and dist in same folder. Possibly you have also backend code, sometimes in backend code you can add compiled version to host on server. It's better to have all code and builds in one repo, so you can do this with one command.
In my case, i wrote scripts in java, to copy builded folder to another folder. We use also Visual Studio for backend, so i wrote script adding new filenames to .cs file, so it can be visible by continous integration tool.
Going to a final, create new branch in git from release master branch. It is useful to have copy of your partial work.
I don't know how often you have releases, but you can solve it by having branches in git.
So your branches can look like this:
master
release1
release2
...
Assuming you are doing development on master and copying new versions to releases.
I want to make the system updates based on composer
With updating dependencies no special problems, but how to update the root package, it is not clear
I'm trying to understand the code composer and so far without success
I think a root project put into dependencies and leave only the bare minimum
or download the project archive from the github and manually remake it
Maybe someone faced with such a task
I don't think there is any way to update the main project.
This is when you've, say, installed a project with composer create-project proj/name . * or similar? Running composer update of course updates the dependencies, but nothing exists to update the project itself.
One way to do it might be as you say, and make the root project nothing but a composer.json file that lists the dependencies, and move the project to operate as a dependency. Bit of a change to the structure though, so this mightn't be possible.
You'll have to use git to do this. This is currently not possible using composer. I was faced with the same problem.
Publish your project on github (or another service)
Install git on the server
Clone the project from git (using git clone git#github.com:whatever folder-name) onto your server wherever you want your root folder located
Whenever you need to update the root project, open a git command window from the root project directory, and run git pull origin v1.0.1. This will essentially patch the project files from the tag you specify.
I've had a look at one or two similar questions on Stack Overflow, but they don't address what I am looking for exactly, unless I've missed it somewhere.
What I have is my own repo that contains custom boilerplate code. In my repo I'd like to include files from various other remote repo's (not my own). Thus when I'm ready to work on a new project, I can clone my repo, get my boilerplate code, as well as the files from the various other repo's I usually go to manually and download from. This way preferably the up to date versions are pulled as opposed to just copying these files into my own repo and having to update them every time there is a revision.
Is this possible to do simply using Git/GitHub?
Submodule is the way to include other repos.
And you now can define a submodule to follow a branch (git 1.8.2+), which means this will bring you the latest commits of said branch.
git submodule update --remote
I do that in my compileEverything GitHub repo, where I include the latest from Semantic-UI master branch.
That is because my .gitmodules looks like:
[submodule "Semantic-UI"]
path = Semantic-UI
url = https://github.com/jlukic/Semantic-UI
branch = master
I'm not particularly looking to include an entire repo/branch but just a select few files within one.
Example: Normalize.css Still possible to do?
No. It is best to:
include the full repo through a submodule (since the submodule pointer itself hardly takes any place in your repo)
keep in the parent repo symlinks to the files you need from that submodule.
That way, you see:
the files you want (symlinked to the same files from the subrepo)
the subrepo reference, that you can update at will.
I changed source of DotNetnuke (a little!) and I want to package an install version of my new DotNetNuke.
How Can I do this?
p.s: I know It's not recommended to change the source but I have no another option
(Telerik calendar do not support my date format and I have to replace it with another calendar !)
Thanks in advance
Answer depends on what you have changed, but the simplest way is to deliver patch that should be installed after normal dnn installation. For example, if you have only changed dll, you can ask to follow normal dnn setup instructions and finally relpace dll. If it's more than on file, you can review how dnn upgrade package is built. It follows same folder structure and places only changed files. So if you have couple of dlls changed in bin, the will be placed in bin folder, and if you have changed some ascx file it should be placed in same path by creating same folder hierarchy.
You can also create a package that can be installed to deploy your changes but for smaller set of files it will be complecated.
Let me know if you need more help.
You can package any change into a DNN install package by including the compiled files along with a DNN Manifest file. This can then be installed via the Extensions page. A manifest file is an Xml file which controls where the contents of an install zip are installed. You can make it as simple or as complicated as you need. You can also include xml merge statements to make changes to the web.config file upon install and uninstall. See the wiki for reference : http://www.dotnetnuke.com/Resources/Wiki/Page/Manifests.aspx
Incidentally, you may have been able to deliver your modified telerik source as a separate provider, and configure it via the web.config, thus saving you from modifying the source code. To do something like that, you would build your own module, and plug it in and replace the standard Telerik references.