2017-09-13 120 views
1

我成功安裝了composer和xampp with PHP version 7.1.8但我無法下載文件,每當我運行命令時我每次都得到[InvalidArgumentException]錯誤,我不知道如何下載所有需要的文件或解決這個問題。無法從GitHub下載依賴關係文件

下面是完整的錯誤

C:\xampp\htdocs\test>composer require Majestcx/OpenLoad-Downloader 

    [InvalidArgumentException] 
    Could not find package Majestcx/OpenLoad-Downloader at any version for your minimum-stability (stable). Check the p 
    ackage spelling or your minimum-stability 

require [--dev] [--prefer-source] [--prefer-dist] [--no-progress] [--no-suggest] [--no-update] [--no-scripts] [--update-no-dev] [--update-with-dependencies] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--] [<packages>]... 
+0

它將與'composer require Majestcx/OpenLoad-Downloader「一起下載4. *」'它不工作的原因是,沒有發佈https://github.com/Majestcx/OpenLoad-Downloader/releases –

+0

@SahilGulati謝謝你的回答我嘗試過但仍然失敗'在任何版本中都找不到所需的軟件包majestcx/openload-downloader,軟件包名稱中可能有拼寫錯誤.'你能幫我進一步嗎 – Rtra

+0

@SahilGulati if它工作在你的最後可以分享我所有的zip文件下載的文件? – Rtra

回答

1

你應該提供一個有效的穩定版本是這樣

composer require Majestcx/OpenLoad-Downloader "4.*" instead of composer require Majestcx/OpenLoad-Downloader

但目前的情況是Majestcx/OpenLoad-Downloader沒有可用Majestcx/OpenLoad-Downloader/releases

你可以發佈做一個想法: Majestcx/OpenLoad-Downloader是依賴於一些外部庫php-phantomjs

所以,你可以不喜歡它:

1. Create a folder lets MyProject

2. In that directory install php-phantomjs with this composer require jonnyw/php-phantomjs

3. git clone https://github.com/Majestcx/OpenLoad-Downloader

更新:按照討論你都拿到

Fatal error: Uncaught JonnyW\PhantomJs\Exception\ProcedureFailedException

併爲客戶比如,你可以做這樣的用於設定路徑到你的phantomjs.exe

$client->getEngine()->setPath(dirname(FILE).'/bin/phantomjs.exe'); 

Reference解決此異常的鏈接。

+1

完美運作 – Rtra