lab 10 - Seneca-CDOT/topics-in-open-source-2022 GitHub Wiki

Lab 10

Due Date

Friday November 25 by Midnight.

Overview

This week we are looking at software releases and getting our code into the hands of users. GitHub is great for developers, but users don't want to have to clone and build your project to run it locally. We need to provide a release that can be easily installed and run.

This lab will help you learn to work with and set up the following:

  • general concepts and terminology of software releases
  • git tags
  • package managers
  • user testing

For this lab you will are asked to work on your own SSG project, but you're welcome to help each other as needed.

NOTE: this final lab provides fewer defined steps and requires more research on your part. This is partly due to the fact that different languages and platforms have different approaches and technologies (i.e., there isn't a simple answer to "how do I release my code?"), and partly as a way for me to test your skills as we wrap up our time together in the course. Remember that open source is fundamentally about community, and you can and should collaborate with your peers on a solution.

Step 1: Choose a Package and Release Method

Modern software releases rely on package managers and centralized package repositories. Each technology ecosystem has a slightly different way of doing it, but the concepts are the same:

  1. create a reproducible, automated build
  2. use some variant of semantic versioning to precisely identify and communicate the version
  3. use git and tags to log releases in project history
  4. add "package" file(s) of some kind, identifying dependencies and which files should be included
  5. upload to a central repository for shared hosting of the release

Depending on the language and ecosystem you are using, here are some recommended approaches to creating your release:

NOTE: If you need/want to use something other than these, that's also fine. Please speak with me to discuss your thinking. It's probably OK, but I want to help you avoid any problems.

Once you have made your choice, begin reading the docs for your chosen package format and registry.

Step 2: Implement Packaging Steps

Based on your research in step 1, begin to implement your release requirements. This may mean adding more to your build system, writing scripts, creating new files, moving existing files into a new structure, adding dependencies, etc.

As you work, keep track of everything you needed to do in order to setup the necessary requirements for your release. These steps, along with all your research and learning, should all go in your final blog post.

Step 3: Tag your Release

Refresh your memory about how git tags work. While we use branches to record our position in a moving line of development, tags allow us to fix a point in the past that we can easily revisit in the future. We want to be able to easily find the 1.0.0 version of our code, as well as the 1.0.1 version, and neither should ever change once we've made them.

Practice creating some tags. To begin, try creating an Annotated Tag for v0.9.0. Later, when you do your actual release, you can use v1.0.0.

When you are done creating tags on main you can use git push --follow-tags to push them to GitHub.

Step 4: Do a Release

Once you have your release process figured out, have setup your project to support your chosen package registry, and understand how to tag, it's time to do a release.

Create a v1.0.0 release of your project, and submit it to your chosen package registry. If you make a mistake, don't panic! Simply fix your mistake and do another release using a PATCH update (e.g., v1.0.1).

Do as many releases as you need to get this right.

Step 5: Update Your Docs

Now that your software can be used via a package registry, you need to update your README.md file to give full instructions on using your code. Re-read your README.md and update all the information about how to download and install your project from a user's perspective.

To do this, try setting up a new project that uses your code via the package registry. Make sure you are able to get it working locally using your instructions.

Once you are done, commit and push these changes to your origin.

Step 6: User Testing

Now it's time to see what happens when someone else tries to install and use your code via the package registry. Find someone who is willing to test your project. It can be someone in the course, or a friend not taking this course. I would recommend that you choose a fellow developer, though, so you don't have to explain the basics of using your chosen programming language, tools, or ecosystem.

Setup a call with your friend over MS Teams, Zoom, or some other communication platform and get them to share their screen with you. Now point them at your README.md file. Ask them to read the instructions and try to follow what they say. Also, ask them to narrate what they are doing as they do it so that you can take notes. Their goal is to use your project on their machine.

NOTE: try to observe but not guide them beyond what your README says. If the README is unclear, you can help them, but make notes about problems they encountered and corrections you need to make.

When they are done, ask them for feedback about the process and any things that they found difficult or missing. Make notes so you can update your README.

Step 7. Update Developer Docs to Include User Testing Feedback

Based on the feedback you got in the previous step, update your README so that it includes the necessary information a user would need to install and use your project. You may also find that you need to update your release to include files, dependencies, or otherwise modify what a user installs.

When you have updated your README, push it to GitHub.

Step 8. (Optional) Automate your Release Process with GitHub Actions

Just as you did with automating your tests, you can also automate your release process via GitHub Actions. Depending on your chosen package registry, research and implement the steps necessary to automate a new release whenever you push a new tag to your main branch.

Step 9: Write a Blog Post

When you have completed all of the required steps above, please write a detailed blog post. In your post, discuss the following:

  • Which release tool and package registry did you choose? Provide links to everything you mention.
  • What was the process for creating a release? Be detailed so that other developers could read your blog and get some idea how to do the same.
  • What did you learn while doing your release? Did you have any "aha!" moments or get stuck?
  • How much did you have to alter your code, files, build, etc. to use the chosen package format and registry?
  • How did the User Testing session with your partner go? Describe what it was like, where they got stuck, and how you corrected the problems.
  • How do users install and use your project now that it has been released? Provide links and some instructions.

Submission

When you have completed all the requirements above, please add your details to the table below.

Name Blog Post (URL) Your Release on the chosen Package Registry (URL)
Denes Adam Dolhay https://dev.to/dadolhay/osd600-lab10-4pe https://www.npmjs.com/package/@dadolhay/ssg
Maxim Nosov https://dev.to/mnosov622/software-release-using-npm-52l9 https://www.npmjs.com/package/simple-ssg1
Anshul Gandhi https://dev.to/anshul137/dps909-blog-lab-10-about-software-releases-4fjj https://www.npmjs.com/package/agandhi29_static_site_geneator
Neil An https://dev.to/neilan99/releasing-my-ssg-with-npm-1mnf https://www.npmjs.com/package/nan1-ssg
Ivan Gabrovsky https://blogforwebdevelopment.blogspot.com/2022/11/lab-10-blog.html https://www.npmjs.com/package/text-ssg-tool
Mario Leonardo https://dev.to/ririio/releasing-package-to-npm-2ina https://www.npmjs.com/package/ririio-ssg
Chen-Yuan Chu https://dev.to/cychu42/end-of-beginning-release-v100-48l0 https://www.npmjs.com/package/static-site-converter
Alexander Samaniego https://dev.to/alexsam29/lab-10-npm-package-release-3m8l https://www.npmjs.com/package/ssg-cli-tool
Piotr Drozd https://dev.to/pdr0zd/adding-my-ssg-to-pypi-5c65 https://pypi.org/project/pdrozd-ssg/
Chan Dinh (Oscar) Phu https://dev.to/lostbutton/software-release-via-npm-3j25 https://www.npmjs.com/package/button-ssg
Tong Liu https://dev.to/liutng/lab10-reflect-388n https://tommyliu.jfrog.io/artifactory/api/conan/tommy-conan-local (This link can only be accessed by conan)
Eakampreet Singh https://dev.to/eakam/rostgen-release-1-3oep https://crates.io/crates/rost_gen
Artem Tanyhin https://dev.to/devils2ndself/publishing-go-package-3hd3 https://pkg.go.dev/github.com/devils2ndself/SSGo
Wonkeun No https://dev.to/genne23v/release-openssg-to-maven-central-4k8m https://s01.oss.sonatype.org/content/repositories/releases/io/github/genne23v/open-ssg/
Rudy Chung https://dev.to/rudychung/osd600-lab-10-4165 https://gitlab.com/rudychung/SauSaGe/-/packages/11004579
Stefan Frunza https://dev.to/sfrunza13/my-first-release-4ea8 https://test.pypi.org/project/super-site-generator-package/1.0.7/
Gulnur Baimukhambetova https://dev.to/gulyapulya/how-to-publish-your-github-project-to-npm-52kd https://www.npmjs.com/package/ssgulnur
Tymur Levtsun https://dev.to/myrfion/izyum-goes-live-4a7m https://www.npmjs.com/package/izyum
Samina Rahman Purba work in progress https://test.pypi.org/project/rwar-ssg/
Taimoor Dawami https://dev.to/tdaw/introducing-siteit-v106-51p2 https://www.npmjs.com/package/siteit