Over the past couple of weeks, I've been working on cli-ssg, which is a command line tool to generate a website using
.md files. A lot of changes had accumulated, and this was the perfect time to create an official release
cli-ssg was sitting at v
0.1, I used npm-version to bump it up:
npm version major
This changed the version in
Then, I updated the
README.md and proceeded to create a
git tag using:
git tag -a v1.0.0 -m "Release 1.0"
At this point, I pushed my changes to GitHub but to my surprise the tags would not show up. After some digging, I realized that tags need to be pushed explicitly, so I used:
git push --tags origin
Before one can publish a package to
npm, you need to create an account and sign into npm using
Since I already had this setup, I proceeded to publish my package using npm-publish:
cli-ssg to the public registry and I could now view it on
While, everything looked great online, I wanted to ensure that users could install it through
npm and the functionality worked as expected. And after some testing, as expected, everything works!
To use the package, users can now simply type:
npm i cli-ssg
npm installs it, the users can use all the features, for example:
cli-ssg -i "sample_input_file.md"
More examples can be found in our docs!