Showing posts with label git. Show all posts
Showing posts with label git. Show all posts

Thursday, October 3, 2013

How to Exclude Folders From Git Gui on Windows

On the main Folder of your project create new file and name it .gitignore, This file will be read by git gui every time and all statemens will taken in account for Not tracking files or folders.

If you want to exclude a folder called "bin" , write a new line in this file "gitignore" like this:

bin/

here the bin folder located in the main folder will be excluded, if the folder you want to exclude is a subfolder,then you need to write :

bin/subfolder/

Ok, after that you have to order Git to remove cached file and remember what you have done here.
from the command line "cmd.exe" , write the following:

c:\project\git rm -r --cached .

//Don't forget the dot in the end of the command line.

then : run the following command:

c:\project\ git add .


Now any chenges made to the folder you specified in gitignore file will not be tracked.




Tuesday, June 25, 2013

Laravel-4 Tutorial-2 : Installation on Windows

The process of installation is clear and direct on windows and require 3 steps to do that : first , downloading the required packages, install them and check the path .

Downloading :
As I said in tutorial-1 , three main programs must be installed on your system Php,Composer And Git, Of course php will be installed with Apache server and mysql as a standard package (I use Wamp Server).

Download the Composer and Install it Just run the installation program , Then go to and download Git
Don't forget to choose the "Add to system Path" option when asked for .

Next check your installatio by running these commands from the command line :
C:\php --version
C:\composer --version
C:\git --version.
if it is ok and you will get a message of each program version.
Now you are ready to install Laravel-4 and begin creating your project.

Install  Laravel-4 using composer:
From the folder that you want to create laravel project in run the following command from command line:

composer create-project laravel/laravel 

The composer will connect to the git repository  and download the laravel
framework and all its components and their dependent packages.
even the Application key will be produces automatically by the installer. No need to do anything else just start configuring you application.

Monday, June 24, 2013

Laravel-4 Tutorial-1 : Things to know before Start developing on Windows

You Need To Install Composer And Git in order to work with  Laravel-4 and Packages Installation.
Three Folders must be added to your path    composer, php and  git.


Composer and Laravel

People on Laravel Project Didn't want to produce a strange php framework that don't know anything about the other Packages on the internet and that will enforce the developer to create his own version of every thing he needs to develop an application. instead the developer can benefit from other developers and can inject their standard packages into his project without the need to start from zero point again.
So,Composer  is just a utility that will help developers to install other packages into their project . That's it.

From Composer Site Documentation :

Composer is not a package manager. Yes, it deals with "packages" or libraries, but it manages them on a per-project basis, installing them in a directory (e.g. vendor) inside your project. By default it will never install anything globally. Thus, it is a dependency manager.

Also,  We need Composer to install the framework that we need like Laravel, Why we need composer .

You will get this error:

failed to open stream: Unable to find the socket transport
 "ssl" - did you forget to enable it when you configured PHP?

When try to install any package using composer and you didn't enable openssl extension

You will get this error :

'git' is not recognized as an internal or external command,  operable program or batch file.

When you try to run composer to install a packages that reside on git repository,That means the git program is not installed or is not added to your PATH.


Why do we need Git :

From Composer Site Documentation :
"To install packages from sources instead of simple zip archives, you will need git, svn or hg depending on how the package is version-controlled. "

-> For Tutorial-2