From ff3706e27d09d7a71f1371978dfa90940dc7900e Mon Sep 17 00:00:00 2001 From: Manh Pham Date: Thu, 19 Sep 2024 22:18:51 +0700 Subject: [PATCH] update --- project.yml | 4 ++++ scripts/brew/brew-cmd.sh | 2 +- scripts/brew/brew-install-package.sh | 2 +- scripts/brew/brew-install.sh | 2 +- scripts/common/generate.sh | 2 +- scripts/common/install.sh | 2 +- scripts/logs/debug.sh | 2 +- scripts/logs/error.sh | 2 +- scripts/logs/info.sh | 2 +- scripts/project/delete.sh | 2 +- scripts/project/firebase.sh | 2 +- scripts/project/linter.sh | 4 +--- scripts/project/swiftgen.sh | 2 +- scripts/project/unit-test.sh | 2 +- scripts/project/upload-testflight.sh | 2 +- scripts/slather/slather-cmd.sh | 2 +- scripts/slather/slather-run.sh | 2 +- 17 files changed, 20 insertions(+), 18 deletions(-) diff --git a/project.yml b/project.yml index f09deb34..7abadcc8 100644 --- a/project.yml +++ b/project.yml @@ -28,14 +28,18 @@ targets: CODE_SIGN_ENTITLEMENTS: Sources/Resources/MyApp.entitlements preBuildScripts: - name: "Generate" + shell: /bin/zsh script: scripts/project/swiftgen.sh postCompileScripts: - name: "Swiftlint" + shell: /bin/zsh script: scripts/project/linter.sh - name: "GoogleServiceInfo" + shell: /bin/zsh script: scripts/project/firebase.sh postBuildScripts: - name: "Crashlytics" + shell: /bin/zsh script: | "${PODS_ROOT}/FirebaseCrashlytics/run" inputFiles: diff --git a/scripts/brew/brew-cmd.sh b/scripts/brew/brew-cmd.sh index 6279be84..34336152 100755 --- a/scripts/brew/brew-cmd.sh +++ b/scripts/brew/brew-cmd.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh if ! [[ $BREW_CMD ]]; then diff --git a/scripts/brew/brew-install-package.sh b/scripts/brew/brew-install-package.sh index d13363de..433b7fb6 100755 --- a/scripts/brew/brew-install-package.sh +++ b/scripts/brew/brew-install-package.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh source $(cd $(dirname ${BASH_SOURCE:-$0}); pwd)/brew-install.sh diff --git a/scripts/brew/brew-install.sh b/scripts/brew/brew-install.sh index 7ed3ccf0..45c1a29a 100755 --- a/scripts/brew/brew-install.sh +++ b/scripts/brew/brew-install.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh source $(cd $(dirname ${BASH_SOURCE:-$0}); pwd)/brew-cmd.sh diff --git a/scripts/common/generate.sh b/scripts/common/generate.sh index fdba0ee0..93bd5fa5 100755 --- a/scripts/common/generate.sh +++ b/scripts/common/generate.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh # generate swiftgen rm -rf Sources/Resources/Generated/* diff --git a/scripts/common/install.sh b/scripts/common/install.sh index d9e3d88c..e9d41694 100755 --- a/scripts/common/install.sh +++ b/scripts/common/install.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh # install cocoapods if ! brew list cocoapods &> /dev/null diff --git a/scripts/logs/debug.sh b/scripts/logs/debug.sh index c7399d43..28373664 100755 --- a/scripts/logs/debug.sh +++ b/scripts/logs/debug.sh @@ -1,3 +1,3 @@ -#!/bin/sh +#!/bin/zsh printf "\033[36mDEBUG\033[0m: $*\n" \ No newline at end of file diff --git a/scripts/logs/error.sh b/scripts/logs/error.sh index 3de295d1..598b1a89 100755 --- a/scripts/logs/error.sh +++ b/scripts/logs/error.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh printf "\033[91mERROR\033[0m: $*\n" 1>&2 exit 1 diff --git a/scripts/logs/info.sh b/scripts/logs/info.sh index 7a0c19f2..b9c79573 100755 --- a/scripts/logs/info.sh +++ b/scripts/logs/info.sh @@ -1,3 +1,3 @@ -#!/bin/sh +#!/bin/zsh printf "\033[93mINFO\033[0m: $*\n" \ No newline at end of file diff --git a/scripts/project/delete.sh b/scripts/project/delete.sh index 1a759496..77e94bbd 100755 --- a/scripts/project/delete.sh +++ b/scripts/project/delete.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh rm -rf \ ./*.xcodeproj \ diff --git a/scripts/project/firebase.sh b/scripts/project/firebase.sh index 952307ca..2d51c1a4 100755 --- a/scripts/project/firebase.sh +++ b/scripts/project/firebase.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh PATH_TO_GOOGLE_PLISTS="${PROJECT_DIR}/Sources/Configs/GoogleServices" echo "warning: Copy file from $PATH_TO_GOOGLE_PLISTS in $CONFIGURATION to ${BUILT_PRODUCTS_DIR}/${PRODUCT_NAME}.app/GoogleService-Info.plist" diff --git a/scripts/project/linter.sh b/scripts/project/linter.sh index a1062541..37cf5ffa 100755 --- a/scripts/project/linter.sh +++ b/scripts/project/linter.sh @@ -1,6 +1,4 @@ -#!/bin/sh - -source ~/.zshrc +#!/bin/zsh sh $(cd $(dirname ${BASH_SOURCE:-$0}); pwd)/../logs/info.sh "warning: Run swiftlint" diff --git a/scripts/project/swiftgen.sh b/scripts/project/swiftgen.sh index b53af94f..335e6b00 100755 --- a/scripts/project/swiftgen.sh +++ b/scripts/project/swiftgen.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh source ~/.zshrc diff --git a/scripts/project/unit-test.sh b/scripts/project/unit-test.sh index 28b89f87..c8542fe1 100755 --- a/scripts/project/unit-test.sh +++ b/scripts/project/unit-test.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh if ! bundle exec fastlane version &> /dev/null then diff --git a/scripts/project/upload-testflight.sh b/scripts/project/upload-testflight.sh index aeb8b5ed..e76b57d9 100755 --- a/scripts/project/upload-testflight.sh +++ b/scripts/project/upload-testflight.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh source $(cd $(dirname ${BASH_SOURCE:-$0}); pwd)/../ruby/ruby-cmd.sh diff --git a/scripts/slather/slather-cmd.sh b/scripts/slather/slather-cmd.sh index ad15cf56..dbc4356e 100755 --- a/scripts/slather/slather-cmd.sh +++ b/scripts/slather/slather-cmd.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh if ! [[ $SLATHER_CMD ]]; then diff --git a/scripts/slather/slather-run.sh b/scripts/slather/slather-run.sh index 0dd78e76..af18c9da 100755 --- a/scripts/slather/slather-run.sh +++ b/scripts/slather/slather-run.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/zsh source $(cd $(dirname ${BASH_SOURCE:-$0}); pwd)/slather-cmd.sh