DEV Community

Gabor Szabo
Gabor Szabo

Posted on

Fixing code and documentation, setting up CI - Sending Pull-Requests

This was the 6th session of the the Open Source Developer Course (OSDC) that I started to teach at the end of January. (We have a weekly session, but we had to skip several weeks in the middle).

This time instead of having a grand presentation we worked on a Perl library (module) that was failing its tests. Here are my notes about what we have accomplished during the session.

The changes we made were not huge, but I believe a little improvement every day by many people can lead to a lot of value to the whole open source ecosystem and through that to the world.

Pull-Requests

The workflow

During the session we first cloned the already forked repository, but I think it is better to clone the original repository and add the forked repository using git remote add fork URL so this is what I described here.

  • Clone the original repository
git clone git@github.com:reneeb/Types-RENEEB.git
Enter fullscreen mode Exit fullscreen mode
  • Create a fork of the repository via GitHub UI.

  • Setup a new git remote to point to the forked repository:

git remote add fork git@github.com:yewtc/Types-RENEEB.git
Enter fullscreen mode Exit fullscreen mode
  • Create a branch to prepare a pull-request
git checkout -b BRANCH
  make changes
git add .
git commit -m "..."
git push --set-upstream fork BRANCH
Enter fullscreen mode Exit fullscreen mode
  • Send the pull-request from the GitHub UI

  • Integrate the progress of original repository to our local clone

git checkout master
git pull origin master
Enter fullscreen mode Exit fullscreen mode
  • Once the Pull-request was accepted we could delete the branch locally and remotely
git branch -d BRANCH
git push -d origin BRANCH
Enter fullscreen mode Exit fullscreen mode
  • We created Test coverage report of the Types-RENEEB pacakge. It was not too interesting as everything was 100%.
cpanm Dist::Zilla::App::Command::cover

dzil cover
Enter fullscreen mode Exit fullscreen mode

Another Pull-Request

Plans

In the upcoming sessions we plan to work on more projects. Set up local development environments and configure GitHub Action workflows for projects require a database or access to some external system.

We will also find packages where the test coverage report is not 100% to understand that better.

Top comments (0)

Some comments have been hidden by the post's author - find out more