J'ai un problème lors de la configuration de ORM Propel.
Je prépare mon environnement sur Vagrant avec PHP 7.1 suivant ce fichier disposition:/usr/bin/env: 'php': aucun fichier ou répertoire de ce type
# Install software
add-apt-repository ppa:ondrej/php
apt update
apt install python-software-properties
apt update
apt install -y apache2
apt install -y php
apt install -y php-mcrypt
apt install -y php-mysql
apt install -y php-curl
apt install -y php-cli
apt install -y php-xml
apt install -y libapache2-mod-php
apt install -y mc
# install composer, configure Apache and create database
service apache2 restart
/etc/init.d/mysql restart
Actuellement je veux installer Propel ORM. J'ai ajouté Propel au compositeur, installé, et maintenant je tape (par SSH Vagrant) /var/www/application/Vendors/bin/propel init
mais malheureusement j'obtiens l'erreur:
/usr/bin/env: �php\r’: No such file or directory
Que puis-je faire pour le résoudre?
EDIT: fichier que je cours (pas modifié, installé via Composer):
#!/usr/bin/env sh
dir=$(d=${0%[/\\]*}; cd "$d"; cd "../propel/propel/bin" && pwd)
# See if we are running in Cygwin by checking for cygpath program
if command -v 'cygpath' >/dev/null 2>&1; then
# Cygwin paths start with /cygdrive/ which will break windows PHP,
# so we need to translate the dir path to windows format. However
# we could be using cygwin PHP which does not require this, so we
# test if the path to PHP starts with /cygdrive/ rather than /usr/bin
if [[ $(which php) == /cygdrive/* ]]; then
dir=$(cygpath -m "$dir");
fi
fi
dir=$(echo $dir | sed 's/ /\ /g')
"${dir}/propel" "[email protected]"
Vous pouvez vérifier le fichier que vous exécutez en premier: le fichier contient littéralement ces caractères amusants. – zerkms
Il n'est pas approprié de répéter les informations d'étiquette dans votre titre. Le système d'étiquettes fonctionne très bien ici et n'a pas besoin de votre aide. –
@Dapi Bienvenue à SO Dapi. Ajoutez toujours de nouvelles informations sur votre question directement dans votre question en la modifiant - et non en ajoutant des commentaires. Cela permettra aux futurs lecteurs d'accéder à toutes les informations nécessaires sans avoir à passer au peigne fin les commentaires. S'il vous plaît modifier votre question et supprimer votre commentaire. – mickmackusa