Open DazWilkin opened 6 years ago
https://github.com/IBM-Blockchain/ibm-container-service/blob/ff63248a583c4e548181d347d02fe3fe63b644ee/cs-offerings/scripts/create/create_channel.sh#L32
Script attempts to replace non-existent references to %PEER_MSPID% in ${KUBECONFIG_FOLDER}/create_channel.yaml.base.
%PEER_MSPID%
${KUBECONFIG_FOLDER}/create_channel.yaml.base
Recommend: -- Remove redundant sed expression -- Consider replacing -e with --expression= for additional clarity
-e
--expression=
sed \ -e "s/%CHANNEL_NAME%/${CHANNEL_NAME}/g" \ -e "s/%PEER_MSPID%/${PEER_MSPID}/g" \ ${KUBECONFIG_FOLDER}/create_channel.yaml.base > ${KUBECONFIG_FOLDER}/create_channel.yaml
Becomes:
sed \ --expression="s/%CHANNEL_NAME%/${CHANNEL_NAME}/g" \ ${KUBECONFIG_FOLDER}/create_channel.yaml.base > ${KUBECONFIG_FOLDER}/create_channel.yaml
https://github.com/IBM-Blockchain/ibm-container-service/blob/ff63248a583c4e548181d347d02fe3fe63b644ee/cs-offerings/scripts/create/create_channel.sh#L32
Script attempts to replace non-existent references to
%PEER_MSPID%
in${KUBECONFIG_FOLDER}/create_channel.yaml.base
.Recommend: -- Remove redundant sed expression -- Consider replacing
-e
with--expression=
for additional clarityBecomes: