[solved] How to publish a package forked from another one?



I want to publish a fixed version of an existing package (since the original hasn’t moved for a long time). I forked the repo, fixed the code. I chose a new name (the same, with -fix at the end, it doesn’t exist yet).

Now, when I want to publish, I get this error: Creating new version failed: Git tag not found

Actually I don’t know how to handle the version number: if I put 0.0.0 (what should be done when publishing a new package), then I guess apm publish minor will try to publish a 0.1.0, but it already exists in the tags.

I also tried to run apm publish --tag v0.13.3 to stick to the previous tags’ history, but to the same result.
How should I actually do?


If this may help, here is the repo I cannot publish:

In the meanwhile I have reset it as a new local repo, I have corrected some errors, there was still references to the name of the package it has been forked from, so I though maybe it could lead to conflicts. This didn’t solve the issue.

Also I have tried to remove all tags to start back from 0.0.0. No luck, still ends up with:

$ apm publish minor
(node:27833) DeprecationWarning: os.tmpDir() is deprecated. Use os.tmpdir() instead.
Preparing and tagging a new version ✓
Pushing v0.1.0 tag Enter passphrase for key '/home/nico/.ssh/id_rsa': 
Publishing symbols-tree-view-fix@v0.1.0 ✗
Creating new version failed: Git tag not found

What is wrong? Is this a bug? I have read somewhere else that it could be a problem when renaming a package, but here I cannot rename it back to the original, since… it’s the forked repo, so?

Also, this doesn’t work.


OK, so things were actually pretty messed up and confusing because I also want to publish another version of the package and I thought they were completely separated, but I was wrong.

So I had to tidy up the tags in the remote repo, but also I had to unpublish the package and fix the repo’s name in package.json (don’t know how I did mess up with this, I did fix it earlier but this got dismissed anyhow).

If anyone is looking for an answer about how to publish a forked “package”, one of the things to do is to check the tags and ensure the remote tags match the local ones (see the link mentioned in the previous post). To check remote tags on the github repo, it’s in source code > releases.