代码拉取完成,页面将自动刷新
#!/bin/bash
# Written by Nishant Srivastava
# Call as
# ./get_packages.sh
echo " ‣ Updating packages..."
# Iterate over each sub-directory inside the current directory
for DIR in ./*;
do
# Check if pubspec.yaml file exists inside the $DIR directory
# If it does then it is a Flutter project
if [ -f "$DIR/pubspec.yaml" ]; then
# Navigate into the sub directory
cd "$DIR"
# Run `flutter packages get` command inside the sub-directory i.e Flutter project
flutter packages get | grep "FAILED"
# Print the name of the sub directory when done
echo "$DIR" | awk -F'/' '{print $2}' | xargs -I{} echo " ↪️ {} ✔️"
# Go back to parent directory
cd ../
fi
done
echo " ✔️ Done."
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。