Skip to main content

Install Cakephp with Composer on Linux

How to Install Cakephp with Composer on Linux System

Here is the complete tutorial for how to install cakephp letest version with composer on linux system.

If you dont have install composer then first you should install composer

To install composer run the following commands one by one-

php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"

php -r "if (hash_file('SHA384', 'composer-setup.php') === '55d6ead61b29c7bdee5cccfb50076874187bd9f21f65d8991d46ec5cc90518f447387fb9f76ebae1fbbacf329e583e30') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"

php composer-setup.php

php -r "unlink('composer-setup.php');"

OR you can install composer with curl by using this command
curl -sS https://getcomposer.org/installer | php


these commands will download the latest composer.phar in the current directory. The 4 lines above will, in order:

    > Download the installer to the current directory
    > Verify the installer
    > Run installer
    > Remove installer

After installation now we need to move composer.phar file into our project directory

Here our project folder name is caketest.
To move composer.phar into our project directory run the following command
 
mv composer.phar /opt/lampp/htdocs/caketest



Now change directory and target the project directory where our composer.phar file exist

To change directory run the following command
 

cd  /opt/lampp/htdocs/caketest/



Now we can install cakephp letest version by runnig the following command
 
 php composer.phar create-project --prefer-dist cakephp/app my_app_name



 After this console will show
 


 user@user /opt/lampp/htdocs/caketest $ php composer.phar create-project --prefer-dist cakephp/app my_app_name

Installing cakephp/app (3.3.6)

  - Installing cakephp/app (3.3.6) Downloading: 100%         

Created project in my_app_name

Loading composer repositories with package information

Updating dependencies (including require-dev)

Package operations: 36 installs, 0 updates, 0 removals

  - Installing aura/installer-default (1.0.0) Downloading: 100%         

  - Installing cakephp/plugin-installer (0.0.15) Downloading: 100%         

  - Installing mobiledetect/mobiledetectlib (2.8.24) Downloading: 100%         

  - Installing psr/http-message (1.0.1) Downloading: 100%         

  - Installing zendframework/zend-diactoros (1.3.10) Downloading: 100%         

  - Installing aura/intl (1.1.1) Downloading: 100%         

  - Installing cakephp/chronos (1.0.4) Downloading: 100%         

  - Installing psr/log (1.0.2) Downloading: 100%         

  - Installing cakephp/cakephp (3.3.14) Downloading: 100%         

  - Installing symfony/yaml (v3.2.3) Downloading: 100%         

  - Installing symfony/debug (v3.2.3) Downloading: 100%         

  - Installing symfony/polyfill-mbstring (v1.3.0) Downloading: 100%         

  - Installing symfony/console (v3.2.3) Downloading: 100%         

  - Installing symfony/filesystem (v3.2.3) Downloading: 100%         

  - Installing symfony/config (v3.2.3) Downloading: 100%         

  - Installing robmorgan/phinx (v0.6.5) Downloading: 100%         

  - Installing cakephp/migrations (1.6.7) Downloading: 100%         

  - Installing jakub-onderka/php-console-color (0.1) Downloading: 100%         

  - Installing jakub-onderka/php-console-highlighter (v0.3.2) Downloading: 100%         

  - Installing dnoegel/php-xdg-base-dir (0.1) Downloading: 100%         

  - Installing nikic/php-parser (v3.0.4) Downloading: 100%         

  - Installing symfony/var-dumper (v3.2.3) Downloading: 100%         

  - Installing psy/psysh (v0.8.1) Downloading: 100%         

  - Installing jdorn/sql-formatter (v1.2.17) Downloading: 100%         

  - Installing symfony/process (v3.2.3) Downloading: 100%         

  - Installing symfony/finder (v3.2.3) Downloading: 100%         

  - Installing seld/phar-utils (1.0.1) Downloading: 100%         

  - Installing seld/jsonlint (1.5.0) Downloading: 100%         

  - Installing seld/cli-prompt (1.0.2) Downloading: 100%         

  - Installing justinrainbow/json-schema (4.1.0) Downloading: 100%         

  - Installing composer/spdx-licenses (1.1.5) Downloading: 100%         

  - Installing composer/semver (1.4.2) Downloading: 100%         

  - Installing composer/ca-bundle (1.0.6) Downloading: Connecting...

 Downloading: 100%         

  - Installing composer/composer (1.3.2) Downloading: 100%         

  - Installing cakephp/debug_kit (3.8.0) Downloading: 100%         

  - Installing cakephp/bake (1.2.14) Downloading: 100%         

cakephp/app suggests installing markstory/asset_compress (An asset compression plugin which provides file concatenation and a flexible filter system for preprocessing and minification.)

cakephp/app suggests installing phpunit/phpunit (Allows automated tests to be run without system-wide install.)

cakephp/app suggests installing cakephp/cakephp-codesniffer (Allows to check the code against the coding standards used in CakePHP.)

symfony/console suggests installing symfony/event-dispatcher ()

symfony/var-dumper suggests installing ext-symfony_debug ()

psy/psysh suggests installing ext-readline (Enables support for arrow-key history navigation, and showing and manipulating command history.)

psy/psysh suggests installing ext-pdo-sqlite (The doc command requires SQLite to work.)

psy/psysh suggests installing hoa/console (A pure PHP readline implementation. You'll want this if your PHP install doesn't already support readline or libedit.)

cakephp/debug_kit suggests installing ext-sqlite (DebugKit needs to store panel data in a database. SQLite is simple and easy to use.)

Writing lock file

Generating autoload files

> Cake\Composer\Installer\PluginInstaller::postAutoloadDump

> App\Console\Installer::postInstall

Created `config/app.php` file

Set Folder Permissions ? (Default to Y) [Y,n]? y

Permissions set on /opt/lampp/htdocs/caketest/my_app_name/tmp/cache

Permissions set on /opt/lampp/htdocs/caketest/my_app_name/tmp/cache/models

Permissions set on /opt/lampp/htdocs/caketest/my_app_name/tmp/cache/persistent

Permissions set on /opt/lampp/htdocs/caketest/my_app_name/tmp/cache/views

Permissions set on /opt/lampp/htdocs/caketest/my_app_name/tmp/sessions

Permissions set on /opt/lampp/htdocs/caketest/my_app_name/tmp/tests

Permissions set on /opt/lampp/htdocs/caketest/my_app_name/tmp

Permissions set on /opt/lampp/htdocs/caketest/my_app_name/logs

Updated Security.salt value in config/app.php

Comments

Popular posts from this blog

Run and compile sass scss file to css using node

  Today we learn how to use scss and generate css using node  or Run and compile sass scss file to css using node   So please follow simple  steps :-   Today we will create a project that can read scss file and generates css with it  Note: Make sure you have installed node in your system. If you want to help to install node js based on your system then check our other tutorial or check node js official website. Now create a blank folder and open  terminal(linux) or cmd(windows) and navigate to your current project folder by using cd command Now run below command npm init after enter it will ask you some package info that you can fill according to you or just keep enter until it finished. The above command will generate package.json file Now  we will install npm module that will convert our scss to css Run below command: npm install node-sass So we have installed node-sass package . Now open package.json file in your...

How to retrieve Facebook Likes, share , comment Counts

function facebook_count($url){     // Query in FQL     $fql  = "SELECT share_count, like_count, comment_count ";     $fql .= " FROM link_stat WHERE url = '$url'";     $fqlURL = "https://api.facebook.com/method/fql.query?format=json&query=" . urlencode($fql);     // Facebook Response is in JSON     $response = file_get_contents($fqlURL);     return json_decode($response); } $fb = facebook_count('https://www.facebook.com/BahutHoGyiPadhai'); // facebook share count echo $fb[0]->share_count;  echo "like"; // facebook like count echo $fb[0]->like_count ; echo "comment"; // facebook comment count echo $fb[0]->comment_count;  ?>

Solution-windows 'expo' is not recognized as an internal or external command

Solution for expo is not recognized as an internal or external command,operable program or batch file in Windows 10 Sometimes expo will not work globally mostly in windows 10, If you are facing same issue then follow the below Steps 1) Click on windows button and search for  " Environment variables"  and click on "Edit the system environment variables" 2) Now you will see a popup like below screen. Then you need to click on Environment Variables. (Please see highlight part in below image)     3)Then click on new button that i have highlighted in below image 4. Then a popup will open and you need to fill details like below mentioned Variable Name :Path Variable Value: %USERPROFILE%\AppData\Roaming\npm Here we are creating a new path variable and passing location of npm.   Now Click on OK and close all the terminal windows and open new CMD or terminal and type Expo . Great now you can access expo from any...