Xcode 10.2.1 Command PhaseScriptExecution failed w

2020-02-06 02:05发布

问题:

Showing Recent Messages:-1: mkdir -p /Users/spritzindia/Library/Developer/Xcode/DerivedData/Contigo-atftiouzrdopcmcpprphpilawwzm/Build/Products/Debug-iphonesimulator/Contigo.app/Frameworks

Showing Recent Messages:-1: rsync --delete -av --filter P .*.?????? --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "/Users/pothi/Library/Developer/Xcode/DerivedData/Contigo-atftiouzrdopcmcpprphpilawwzm/Build/Products/Debug-iphonesimulator/IQKeyboardManagerSwift/IQKeyboardManagerSwift.framework" "/Users/pothi/Library/Developer/Xcode/DerivedData/Contigo-atftiouzrdopcmcpprphpilawwzm/Build/Products/Debug-iphonesimulator/Contigo.app/Frameworks"

Command PhaseScriptExecution failed with a nonzero exit code

I deleted derived data. i have tried :

keychain access -> right click on login -> lock & unlock again -> clear Xcode project

Restarted machine, no use

How do I resolve "Command PhaseScriptExecution failed with a nonzero exit code" error when trying to archive project.

And I am using those librarys

pod 'IQKeyboardManagerSwift'
pod 'SDWebImage', '~> 4.0'
pod 'KRPullLoader'
pod 'Paytm-Payments'

回答1:

Go to

Keychain Access -> Right-click on login -> Lock & unlock again -> Clean Xcode project ->Make build again



回答2:

Xcode -> File -> Workspace Setting... -> change Build System to Legacy Build System.

Thats it. Have Fun



回答3:

Try the below:

  1. pod deintegrate
  2. pod install
  3. XCode Clean build


回答4:

I had a similar error

/{path to project root}/Pods/Target Support Files/Pods-{project name}/Pods-{project name}-frameworks.sh: Permission denied
Command PhaseScriptExecution failed with a nonzero exit code

In my case I had received a zip of a repo that included the Pods folder. It turns out that at some point between it being originally created and sent to me, the *.sh files in Pods/Target Support Files/Pods-{PROJECT}/ had all lost their execute permissions. Giving those files +x was the solution



回答5:

I was able to resolve this error by remove file in Pods -> Targets Support Files -> Pods-AppName -> Pods-AppName-frameworks.sh. After removing that file again install pod using command pod install.

OR.

Try this:

-> quit xcode -> install pod(again) -> start xcode



回答6:

If you came here due to env: node: No such file or directory. Check this other answer: https://stackoverflow.com/a/50419734/8290290



回答7:

Go to Targets-> and delete the run script.Again