Create podspec file, add pod support, support pod import

Create podspec file, add pod support, support pod import

I have been boring in the past few months, and I post some of the past things here to share with you, hoping to have some meager help to everyone

Create a podspec file and add a detailed process for pod support

1. First cd to the root directory of the local project

2. The command to create a .podspec file is as follows:

pod spec create SStipsAndHUD

3. Open the .podspec file with a text editor to edit the corresponding content, as shown in the figure below:

4. Save after editing, you need to verify whether this file is available, podspec file does not allow any WarningorError,验证的命令如下:

pod lib lint

When SStipsAndHUD passed validation appears, the verification is passed

5. The tag that needs to be specified in the podspec file, after completing the above operations, tag the project. Two commands need to be executed:

git tag -m"first release SStipsAndHUD with podspec" "0.0.1"

git push --tags

6. Push the .podspec file to the Cocoapod official website library through the command. The command is as follows (this process may take a little longer):

pod trunk push SStipsAndHUD.podspec

7. It is best to update the local pod library command as follows:

pod repo update

This is the end, now you can import and use it in your other projects through cocoapod.

The following are two related links (others):

https://blog.csdn.net/u010828718/article/details/81138157

https://blog.csdn.net/w_shuiping/article/details/80606277

 

 

Guess you like

Origin blog.csdn.net/sss1507089/article/details/113186512