0
I’m trying to deploy a standard application to both AWS(Amazon Web Services) and Heroku, and both have reported phpunit errors inside the vendor folder.
After several searches (which already cost me about 6 hours) I finally found the error inside vendor/bin folder where virtually all files are corrupted.
These are the corrupted files:
They have the following mistakes:
Ex: vendor/bin/Dep
#!/usr/bin/env sh
dir=$(cd "${0%[/\\]*}" > /dev/null; cd "../deployer/deployer/bin" && pwd)
if [ -d /proc/cygdrive ]; then
case $(which php) in
$(readlink -n /proc/cygdrive)/*)
# We are in Cygwin using Windows php, so the path must be translated
dir=$(cygpath -m "$dir");
;;
esac
fi
"${dir}/dep" "$@"
Ex: vendor/bin/php-parse:
#!/usr/bin/env sh
dir=$(cd "${0%[/\\]*}" > /dev/null; cd "../nikic/php-parser/bin" && pwd)
if [ -d /proc/cygdrive ]; then
case $(which php) in
$(readlink -n /proc/cygdrive)/*)
# We are in Cygwin using Windows php, so the path must be translated
dir=$(cygpath -m "$dir");
;;
esac
fi
"${dir}/php-parse" "$@"
And some others too.
Any idea how to fix this?
It is interesting to delete Composer.lock as well.
– CypherPotato
I did exactly what you said, deleted the vendor, and also what Cypherpotato said and deleted Poser.lock, and it was still a mistake, so I read several gringo tutorials and I realized that the mistake was because some of the dependencies that were in require-dev were being needed in require, so I started putting one by one the dependencies of require-dev in require as they gave error, but that would take a long time so I copied and pasted everything, now I have another error, when I use "Heroku open", do not open the site, error appears "Could not access this site". Any idea ?
– Gavin
By the way, I’ve already set up Procfile.
– Gavin