# Composer is installing from the cache even tho the cache has been cleared

**URL:** <https://travis-ci.community/t/composer-is-installing-from-the-cache-even-tho-the-cache-has-been-cleared/9231>\
**Category:** PHP\
**Created:** [July 3, 2020, 11:00pm UTC](https://travis-ci.community/t/composer-is-installing-from-the-cache-even-tho-the-cache-has-been-cleared/9231 "2020-07-03T23:00:25Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![terrafrost](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/terrafrost/32/4824_2.png) [@terrafrost](https://travis-ci.community/u/terrafrost)\
**Post date:** [July 3, 2020, 11:00pm UTC](https://travis-ci.community/t/composer-is-installing-from-the-cache-even-tho-the-cache-has-been-cleared/9231/1 "2020-07-03T23:00:25Z")

</div>

I’m trying to install a Composer package on Travis CI. In my .travis.yml file I have the following two commands:

```auto
composer clear-cache
composer install

```

Here’s the output of those commands:

```auto
$ composer clear-cache
Cache directory does not exist (cache-vcs-dir): 
Clearing cache (cache-repo-dir): /home/travis/.cache/composer/repo
Clearing cache (cache-files-dir): /home/travis/.cache/composer/files
Clearing cache (cache-dir): /home/travis/.cache/composer
All caches cleared.
The command "composer clear-cache" exited with 0.
71.10s$ composer install
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 3 installs, 0 updates, 0 removals
  - Installing paragonie/random_compat (v2.0.18): Downloading (100%)
  - Installing paragonie/constant_time_encoding (v1.x-dev 2132f0f): Cloning 2132f0f293 from cache
  - Installing phpseclib/phpseclib (3.0.x-dev 844d7ab): Cloning 844d7ab539 from cache

```

Here’s my composer.json:

```auto
{
    "repositories": [
        {
            "type": "vcs",
            "url": "https://github.com/terrafrost/phpseclib"
        }
    ],
    "require": {
        "phpseclib/phpseclib": "3.0.x-dev"
    },
    "minimum-stability": "dev"
}

```

I have some additional commits in my fork of phpseclib that aren’t in the 3.0 branch of [https://github.com/phpseclib/phpseclib](https://github.com/phpseclib/phpseclib) but Travis CI’s Composer install keeps on installing from the latest commit in the 3.0 branch of [https://github.com/phpseclib/phpseclib](https://github.com/phpseclib/phpseclib) and not the one in my fork ([https://github.com/terrafrost/phpseclib](https://github.com/terrafrost/phpseclib)). Any ideas?
