Releasing my open source project.

krinskumar

Krinskumar Vaghasia

Posted on November 22, 2024

Releasing my open source project.

This week we will be releasing out open source project into the wild so that other developer can use it with their package manager as opposed to having to download our github project manually every time we release a new update.

My code was on javascript whose dependencies were managed by npm, so I decided to push my package onto npm. Firstly I decided to groom my package by making changes in my package.json file, fields like name and description.

The release process was very intuitive, I just had to login myself using into npm inside my terminal using npm adduser and run npm publish --access public. The first time I ran this command, it did not work, gave me a cryptic error that I dont have permission to push??!!. Turns out that there exists a package name scrappy already, so I changed my name to scrappy-cli. This time the publish worked.

I installed this globally and tried to run it, annnnd, it did not work, the command scrappy-cli was not recognized. I did a lot of digging that found out that the command name is extracted from the bin attribute in the package.json. I forgot to change it to scrappy-cli from just scrappy. I made the change and found out that we can test our command line before pushing using npm link. My command line was working fine with npm link, So I pushed it and this time when I downloaded it globally, it worked!!.

I made a new npm command that would push my changes onto github as a new tag and publish on npm, this is what the command looks like "patch-release": "npm version patch && npm publish && git push --follow-tags".

User testing.

My tool is very intuitive and easy to use. I asked my friend to use my tool and he was able to get it running just using the docs. It did take some time to figure out the setup process of the api keys for LLM..

If you want to use scrappy-cli you can just run npm i -g scrappy-cli and follow the docs.

💖 💪 🙅 🚩
krinskumar
Krinskumar Vaghasia

Posted on November 22, 2024

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related