Laravel 5.7 Installation Issue - laravel

I'm trying to install laravel 5.7 by using this command
> composer create-project --prefer-dist laravel/laravel new_project dev-develop
But it's reflecting following error, also i disabled antivirus and firewall.
Installing laravel/laravel (dev-develop
b0651d2467f1428eadc505e1b3b4f5678611927c)
- Installing laravel/laravel (dev-develop develop): Loading from cache Created project in new_project
#php -r "file_exists('.env') || copy('.env.example', '.env');" Loading composer repositories with package information Updating
dependencies (including require-dev) Package operations: 71 installs,
0 updates, 0 removals
- Installing vlucas/phpdotenv (v2.5.1): Downloading (failed) Downloading (failed) Downloading (failed) Failed to download
vlucas/phpdotenv from dist: The
"https://api.github.com/repos/vlucas/phpdotenv/zipball/8abb4f9aa89ddea9d52112c65bbe8d0125e2fa8e"
file could not be downloaded : SSL operation failed with code 1.
OpenSSL Error messages: error:1416F086:SSL
routines:tls_process_server_certificate:certificate verify failed
Failed to enable crypto failed to open stream: operation failed
Now trying to download from source
- Installing vlucas/phpdotenv (v2.5.1): Cloning 8abb4f9aa8
[RuntimeException] Failed to clone
https://github.com/vlucas/phpdotenv.git via https,ssh protocols,
aborting.
- https,ssh://github.com/vlucas/phpdotenv.git
Cloning into 'D:\xamppro\htdocs\neologicx.com\new_project\vendor\vlucas\phpdotenv'...
fatal: I don't handle protocol 'https,ssh'
create-project [-s|--stability STABILITY] [--prefer-source]
[--prefer-dist] [--repository REPOSITORY] [--repository-url
REPOSITORY-URL] [--dev] [--no-dev] [--no-custom-installers]
[--no-scripts] [--no
-progress] [--no-secure-http] [--keep-vcs] [--no-install] [--ignore-platform-reqs] [--] [] [] []
OpenSSL Installed
and enabled

Okay, my problem resolved by removing '%temp%' files from windows.
After that i got content-length mismatch problem resolved from this Composer Content-Length Mismatch
And then again i tried this "composer create-project laravel/laravel laravelproject1" it worked.
Thanks Alot everyone.

composer global require "laravel/installer"
--
laravel new myProject
Run these commands in order and you should be fine.
If you prefer to use the composer create project command, then run this:
composer create-project --prefer-dist laravel/laravel blog

try composer clear-cache then composer self-update

Please try this.
install laravel 5.7:
composer create-project laravel/laravel laravelproject1

Related

composer laravel install: “http://packagist.org” file could not be downloaded

I want to install laravel through composer with :
$ composer create-project --prefer-dist laravel/laravel DemoTest
but every time i do that composer shows a message:
[Composer\Downloader\TransportException] The
"http://packagist.org/p/provider-2013%244440cd3f9b7aec0de3e4f3486e61b7e348d74d03a0bd6a61b5b8a514e105
2c4d.json" file could not be downloaded: failed to open stream: HTTP
request failed!
Can you try
composer clear-cache
then
composer -vvv
after that try running the install command for laravel, it worked for me though

Failed to install laravel

I was installing laravel framework by composer in visual studio code.
composer create-project laravel/laravel ems
but it failed to install the laravel.
here is the message
$ composer create-project laravel/laravel ems
Installing laravel/laravel (v5.5.0)
- Installing laravel/laravel (v5.5.0): Downloading (failed)
Downloading (failed)
Downloading (failed) Failed to download laravel/laravel from dist: The "https://api.github.com/repos/laravel/laravel
/zipball/a6c68c24c9938beef0128c3288502b8fbdf8e93d" file could not be downloaded: failed to open stream: A connection at
tempt failed because the connected party did not properly respond after a period of time, or established connection fai
led because connected host has failed to respond.
Now trying to download from source
- Installing laravel/laravel (v5.5.0): Cloning a6c68c24c9 from cache
[RuntimeException]
Failed to clone https://github.com/laravel/laravel.git via https, ssh protocols, aborting.
- https://github.com/laravel/laravel.git
Cloning into 'C:\xampp\htdocs\ems'...
fatal: unable to access 'https://github.com/laravel/laravel.git/': Failed to connect to github.com port 443: Tim
ed out
- git#github.com:laravel/laravel.git
Cloning into 'C:\xampp\htdocs\ems'...
ssh: connect to host github.com port 22: Connection timed out
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
create-project [-s|--stability STABILITY] [--prefer-source] [--prefer-dist] [--repository REPOSITORY] [--repository-url
REPOSITORY-URL] [--dev] [--no-dev] [--no-custom-installers] [--no-scripts] [--no-progress] [--no-secure-http] [--keep-
vcs] [--no-install] [--ignore-platform-reqs] [--] [] [] []
I think you miss something "--prefer-dist"
composer create-project --prefer-dist laravel/laravel projectName
look at the documentation https://laravel.com/docs/5.5

Error updating Symfony on Composer

I cloned a git project, then run composer update command, I got this error message on composer:
- Installing symfony/symfony (v2.2.4)
Downloading: 100%
[UnexpectedValueException]
'E:\Sites\myapp-api\vendor/symfony/symfony/268ac81f41a8a73a56ef570d9e7980
27.4' is not a zip archive.
update [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--lock]
[--no-custom-installers] [--no-scripts] [--no-progress] [-v|vv|vvv|--verbose] [
-o|--optimize-autoloader] [packages1] ... [packagesN]
I tried to delete composer.lock and run composer update command again, still return the same error.
I also try to run composer update symfony/symfony, and with --prefer-dist but still return the same error message 'is not a zip archive'.
How to solve this problem?
I try and try again, and now there are 3 ites of downloading symfony/symfony
- Installing symfony/symfony (v2.2.4)
Downloading: 100%
- Installing symfony/symfony (v2.2.4)
Downloading: 100%
- Installing symfony/symfony (v2.2.4)
Downloading: 100%
[UnexpectedValueException]
'E:\Sites\trainme-api\vendor/symfony/symfony/698bb2e6e680e6c886eb5c70f5d93e
97.4' is not a zip archive.
I had silimar issue. Clearing composer cache helped.
Look here: https://github.com/composer/composer/issues/1242
If You are using linux composer cache should be in: ~/.composer/
You can clear it with backup with this command:
mv ~/.composer/cache ~/.composer/cache.bak
Update
Check cache-dir param in your composer.json
http://getcomposer.org/doc/04-schema.md#config
cache-dir: Defaults to $home/cache on unix systems and C:\Users\\AppData\Local\Composer on Windows. Stores all the caches used by composer. See also COMPOSER_HOME.
UPDATE:
You can find cache dir with command (thanks to #Permana):
php composer.phar config cache-dir

Installing laravel 4 via composer?

I have composer installed and openSSL extension enable in PHP but I still get the error (I restarted wamp twice)
Afflicto#Afflicto-PC /cygdrive/e/wamp/www/wirezapp2
$ composer create-project laravel/laravel wirezapp --prefer-dist
Installing laravel/laravel (v4.0.5)
- Installing laravel/laravel (v4.0.5)
Downloading: 100%
Downloading: 100%
Downloading: 100%
[Composer\Downloader\TransportException]
The "http://nodeload.github.com/laravel/laravel/zip/v4.0.5" file could not
be downloaded: failed to open stream: Unable to find the socket transport "
ssl" - did you forget to enable it when you configured PHP?
create-project [-s|--stability="..."] [--prefer-source] [--prefer-dist] [--repository-
url="..."] [--dev] [--no-dev] [--no-custom-installers] [--no-scripts] [--no-progress]
[-- keep-vcs] [package] [directory] [version]
Figured it out:
The php.ini in wamp is different than that used by apache/wamp, so I had to enable the open ssl extension via php.ini found in wamp/bin/php/php5.4.3/php.ini

Symfony 2.1-x / Composer ErrorException with DoctrineBundle

* Update: the issue could be resolved by reducing the Directory depth *
I've tried to install the latest Symfony version (2.1.6, 2.1.5, 2.1.x-dev) via the recommended way using composer but it always fails with the same error:
C:\Users\made\eclipse-workspace\template-compiler\template-compiler\lib\server\symfony\vendor\doctrine\doctrine-bundle\Doctrine\Bundle\DoctrineBundle\b05c336283dc24eb535a50f89ce9d91c.0 - Das Handle ist ung¬tig.
Searching gave me no further clues until now and i would like to avoid having to create everything from scratch. I tried the self-udpate feature of composer and all of the mentioned versions above but the installation still fails. I'm using the git Bash on Win7 with PHP 5.3.8 but I also tried PHP 5.4.10
Complete Output:
C:\Users\made\eclipse-workspace\template-compiler\template-compiler\lib\server>C:\Users\made\AppData\Roaming\Composer\bin\composer
create-project symfony/framework-standard-edition symfony 2.1.6
Installing symfony/framework-standard-edition (v2.1.6)
- Installing symfony/framework-standard-edition (v2.1.6)
Loading from cache
Created project in symfony
Loading composer repositories with package information
Installing dependencies from lock file
- Installing doctrine/common (2.3.0)
Loading from cache
- Installing doctrine/dbal (2.3.1)
Loading from cache
- Installing twig/twig (v1.11.1)
Loading from cache
- Installing symfony/symfony (v2.1.6)
Loading from cache
- Installing doctrine/doctrine-bundle (v1.0.0)
Downloading: 100%
C:\Users\made\eclipse-workspace\template-compiler\template-compiler\lib\server\symfony\vendor\doctrine\doctrine-bundle\Doctrine\Bu
ndle\DoctrineBundle\5338efeb67b3e71765a5179fbadb1633.0 - Das Handle ist ungültig.
[ErrorException]
ZipArchive::extractTo(C:\Users\made\eclipse-workspace\template-compiler\template-compiler\lib\server\symfony\vendor/doctrine/
doctrine-bundle/Doctrine/Bundle/DoctrineBundle/DoctrineBundle-1.0.0\Tests\DependencyInjection\Fixtures\Bundles\Vendor\Annotat
ionsBundle/AnnotationsBundle.php): failed to open stream: Invalid argument
create-project [-s|--stability="..."] [--prefer-source] [--prefer-dist] [--repository-url="..."] [--dev] [--no-custom-installers]
[--no-scripts] [--no-progress] [--keep-vcs] package [directory] [version]
C:\Users\made\eclipse-workspace\template-compiler\template-compiler\lib\server>
the issue could be resolved by reducing the Directory depth
PS: now i have the rep score to solve this...

Resources