I am creating my own private pod. I have complete all step. But in last step when we call
pod trunk push AffleChat_msy1.podspec
We got error like
[!] Source code for your Pod was not accessible to CocoaPods Trunk. Is
it a private repo or behind a username/password on http?
I think what you are searching for is:
pod repo push [REPO_NAME] [POD_NAME].podspec
Before, you should consider that you need to tag your current version:
git tag ‘1.0.1’
Also pushing that tag.
git push --tags`
The --tags command pushes all tags, even unwanted. Push just one tag by: How to only push a specific tag to remote?
git push origin 1.0.1
See this medium article to get a good overview about how to update private pods.
Related
I have a private spec repo,such as MXNetworkSpec,when i use this command "pod repo push MXNetworkSpec MXNetwork.podspec",git can not push this MXNetwork.podspec to remote master,it shows that Everything up-to-date. what should i do ?
Recently, I found a problem in a public cocoapod, and I was impatient to wait for the fix. Good thing, too, because it took about 4 weeks to get my PR accepted.
So, my solution was to fork the public pod. I'm already using a private repo for some of my company's private pods, so I modified my forked podspec file, and did a pod repo push to my local repo.
In my podfile, I modified the "pod" line like so:
pod 'PublicPod', :git => "https://github.com/MyCompany/ForkedPublicPod.git
Recently, my PR was accepted, so I removed the "git" dependency on the "PublicPod" line, telling Cocoapods to use the "normal" pod, instead of my private pod (or so I thought). However, I'm being told that cocoapods has Found multiple declarations for 'PublicPod'.
So, I don't need my forked pod to be active anymore, but I do have other private pods, so I can't just removed the source line from my Podfile.
I just want to forget about my private pod, and have it just not be seen or available anymore.
When I faced the similar problem. I haven't found any command to do this via pods, so I completed this task manually. I removed my local pod the next way:
Remove folder with all podspecs from my private pod. I think, this is the main step because no podspecs - no pod.
Run pod repo update [repo_name] to stay your local cached repo synced with remote repo.
Since I don't need my current sources for the removed pod, I delete them too.
I use tags for pod versioning, so I remove all tags connected to my pod
Additionally you can clean pod cache (to be ensure, that you really use remote pod) with pod cache clean <pod_name> --all. Be careful, if you miss pod_name, this command will clear all your cache (all pods)!
I suppose, the first two steps are enough. But I wanted to completely remove the private pod.
I'm having trouble pushing an update to a pod (Audiobus).
"pod trunk push" seems to successfully validate (downloads the git repository, builds, etc), but then drops out with a 403 Forbidden error when doing a POST to /api/v1/pods with the podspec content, along with the message:
"Source code for your Pod was not accessible to CocoaPods Trunk. Is it a private repo or behind a username/password on http?"
I have verified that I'm registered ("pod trunk me" shows I am logged in with correct email address, an owner of the pod).
The repository once required HTTP authentication, but after seeing the above error, I disabled auth. I've verified that there's now open access to the git repository by cloning the repository from a separate, unauthenticated machine (git clone https://developer.audiob.us/download/SDK.git test --single-branch --depth 1 --branch 2.2).
Is this a bug in trunk.cocoapods.org? What am I missing?
Cheers in advance,
Michael
Make sure to make your repo commit tag name the same version name you have on your package podspec file.
I'm surprised by this also, this has been running for a few weeks now and this is the first time a problem has come up. When I run the command locally I don't see a problem. I don't know if you've edited the question, but I had a reference to https://developer.audiob.us/download/SDK.git/?url=download/SDK.git which didn't work with the git ls-remote. Perhaps it doesn't redirect like git clone does?
Any one who may come upon this issue but the other answer does not help. Make sure you have the correct branch in your podspec. Having the incorrect branch will also cause this error to occur.
I have a repo on github. I want to publish it as cocoa pod. I tried hard but couldn't find any frank tutorial.
http://guides.cocoapods.org/making/specs-and-specs-repo.html
teaches how to create spec file and how to update your existing pod , but doesn't tell how to create a new one.
while following https://github.com/CocoaPods/CocoaPods/wiki/Creating-and-maintaining-a-pod , tutorial, i am facing errors after executing "$ pod push master" command, it says,
Pushing the `master' repo
remote: Permission to CocoaPods/Specs.git denied to HarshitDaftary.
fatal: unable to access 'https://github.com/CocoaPods/Specs.git/': The requested URL returned error: 403
Kindly help me.
You are apparently not (yet) a contributor to the CocoaPods/Specs.git repository. To add your pod to the public list you will need to fork that repo, push to that fork, and submit a pull request to have your addition merged into the upstream repository. See the "If you do not have push access to CocoaPods/Specs" section on http://guides.cocoapods.org/making/specs-and-specs-repo.html
Some time ago I found some code in one Github repo. I downloaded it (did not fork it), started upgrading it and when I was happy with the result, I used Heroku as a host. So now the code lives on my computer and Heroku. How could I push it to my Github account, but also give the original author of the project some credit for it (showing on my Github that I actually forked it)?
Okay, so I actually figured it out already!
First, create a new repository on github, let's name it github-project.
git clone git#heroku.com:<heroku-project>.git
cd <heroku-project>
git remote rm origin
git remote add github https://github.com/<github-username>/<github-project>
git pull github master
Now you'll probably see some conflicts. If you want to preserve all your changes, just add them all.
git add .
git commit -m "some message"
git push github master
This is quite simple:
Create an empty repository on GitHub, let's call it github-project
Clone from Heroku, let's call it heroku-project
Add a remote for github
Push to GitHub
The commands to perform these steps:
git clone git#heroku.com:heroku-project.git
cd heroku-project
git remote add github https://github.com/github-username/github-project
git push -u github master
That's it!
Note: if you already created the GitHub project with a README file in it, then it is NOT empty anymore, and the last push will be refused. In that case you can force the push, effectively overwriting the project on GitHub, by using the --force flag, for example:
git push -u github master --force