Closed Nexus9w9 closed 10 months ago
Apparently this is a typo, here is the corrected compile_plugin function.
compile_plugin() {
for index in ${!PLUGIN_PATHS[@]}; do
export PHP_BINARY PHARYNX_PATH
export PLUGIN_PATH="${PLUGIN_PATHS[$index]}"
local COMPOSER=""
if [[ -f "${PLUGIN_PATH}/composer.json" ]]; then
COMPOSER="-c"
fi
"$PHP_BINARY" -dphar.readonly=0 "$PHARYNX_PATH" $COMPOSER -i "$PLUGIN_PATH" -p=plugins/pharynx-output-${index}.phar
if [[ ! -f "${PLUGIN_PATH}/composer.json" ]]; then
"$PHP_BINARY" -dphar.readonly=0 "$DIR"/bootstrap-plugin-dev.php plugins/pharynx-output-${index}.phar
fi
done
}
Please open a pull request if you find the correct option but I don't understand, why would you have two plugins with the same name?
I expressed myself wrongly. In fact, the problem lies in the way the for loop's index variable is being used, which results in all plugins having the same name. The variable used does not exist.
How to open a pull request for a file that is in a release?
@Nexus9w9 the file is in the repo under the plugin-dev directory
I've been trying to use the compilation option for my plugins using the ./start.sh option but I realize that when I indicate 2 directories or more, the plugin is overwritten by the other one because of their identical names.
How to reproduce the error:
Open ./start.sh and enter two paths, start ./start.sh and see that one plugin is replaced by the other because their names are the same.