# Git 

### Start a new repository and publish it to GitHub
##### create a new directory, and initialize it with git-specific functions
git init my-repo

##### change into the `my-repo` directory
cd my-repo

##### create the first file in the project
touch README.md

##### git isn't aware of the file, stage it
git add README.md

##### take a snapshot of the staging area
git commit -m "add README to initial commit"

##### provide the path for the repository you created on github
git remote add origin https://github.com/YOUR-USERNAME/YOUR-REPOSITORY.git

##### push changes to github
git push --set-upstream origin main

# Contribute to an existing branch on GitHub
##### assumption: a project called `repo` already exists on the machine, and a new branch has been pushed to GitHub.com since the last time changes were made locally

##### change into the `repo` directory
cd repo

##### update all remote tracking branches, and the currently checked out branch
git pull

##### change into the existing branch called `feature-a`
git checkout feature-a

##### make changes, for example, edit `file1.md` using the text editor

##### stage the changed file
git add file1.md

##### take a snapshot of the staging area
git commit -m "edit file1"

##### push changes to github
git push

# Remove the files from the index (not the actual files in the working copy)
$ git rm -r --cached .

##### Add these removals to the Staging Area...
$ git add .

##### ...and commit them!
$ git commit -m "Clean up ignored files"



# CodeIgniter 4 Framework
## Important Change with index.php

`index.php` is no longer in the root of the project! It has been moved inside the *public* folder,
for better security and separation of components.

This means that you should configure your web server to "point" to your project's *public* folder, and
not to the project root. A better practice would be to configure a virtual host to point there. A poor practice would be to point your web server to the project root and expect to enter *public/...*, as the rest of your logic and the
framework are exposed.

**Please** read the user guide for a better explanation of how CI4 works!
The user guide updating and deployment is a bit awkward at the moment, but we are working on it!

## Server Requirements

PHP version 7.2 or higher is required, with the following extensions installed: 

- [intl](http://php.net/manual/en/intl.requirements.php)
- [libcurl](http://php.net/manual/en/curl.requirements.php) if you plan to use the HTTP\CURLRequest library

Additionally, make sure that the following extensions are enabled in your PHP:

- json (enabled by default - don't turn it off)
- [mbstring](http://php.net/manual/en/mbstring.installation.php)
- [mysqlnd](http://php.net/manual/en/mysqlnd.install.php)
- xml (enabled by default - don't turn it off)
