Posts

Showing posts from October, 2020

The fourth pull request for Release0.2

Image
This time I find a project which has twenty contributors using advanced search with label "good first issue" in GitHub. The project is written with React and is a website of  House of Geeks .  There is an issue about missing the title in the Communities page when customers  visit the community component via navbar. After understanding the issue, I fork the repo and download the file into my local host. Then I create a branch for the issue. No title page When I look at the code, I find the problem in the Community component. The author indeed writes the title for this page. But he puts the code in the wrong place and has the wrong CSS code. I  quickly fix them and test the website in my local host. It works well. Communities page with title At last, I push these changes to my GitHub and pull my request to the author.  This month is a wonderful month for me. I learn what is the open source project and how to contribute to them. I can't imagine it before. Now I know there

Practice git rebase in Lab5

Image
 This week we start to how to use git rebase in open source project. Git rebase is used to rewrite git history and make your project  a bit of a clean-up.   In the lab5, I will try to promote my test link project to be more concise. Fist of all, I split my index.js file into two separated files, index.js file and read-file.js file. The read-file.js file will include all of the logic to read a file. After completing the changes, I try to execute the project and it works well. Second, I modify the code about showing the version of the project to make it more readable. After modifying the code, I test the code well and make a commit. Third, I change the code about showing the help information. Then, I test the code and make a commit. After completing above steps, I use git rebase master -i command to  squash everything into a single commit. Then, the three commits are combined into one commit. I also use git commit --amend command to change the combined commit message better. At last, I

The third pull request for Release0.2

Image
 This time I try to search for an issue which is about a new topic for me.  After looking around from GitHub, I find an interesting issue from  screen-recorder  repo. The project can be implemented to show the window, but there is an error message " Uncaught TypeError: Cannot destructure property 'dialog' of 'remote' as it is undefined.   ". In order to analyze the error, I fork the repo and download all of the files. I find the variable dialog comes from the variable remote and the remote comes from the electron dependency. Next, I try to figure out what "electron" is.  Electron is an open-source software framework developed and maintained by GitHub. It allows for the development of desktop GUI applications using web technologies: it combines the Chromium rendering engine and the Node.js runtime. When studying the document of Electron, I see an example of dialog. Dialog example Comparing the usage of dialog from the author, I think the error was ca

The second pull request for Release0.2

Image
 Now, it is the second week for my Release0.2 assignment of OSD600 course. I plan to practice a new pull request using git and GitHub.  First of all, I try to search for a suitable issue from open source projects. In this time, I search for the issues with the limitations of "good first issue" and "JavaScript" through advanced search in GitHub. Then I find an issue about combining the data to a separated file fro m a  repo . Now all of the needed data is in the main index.js file. But the main file will be clunky when the data is too much. So I decide to store all of the test data to a separated js file. I create a new branch named issue-24 for the flowing changes. After storing the data to a single file, I exports these variables. Then, the main index.js file can use them. When I complete all of the changes, I try to test if it works well. Test At last, I commit the changes and push them to my forked repo. Then I pull a request to the author to check.

Practice git remote and git merge in lab4

Image
 This week I am practicing using git remote and git merge through adding a new feature to the project another classmate completed. The steps are as following. creating branches to work on new features and fix bugs working on code changes in another project you didn't write using  git remote  and sharing commits with  git push ,  git pull , and  git fetch using  git merge  and doing practice merges fixing merge conflicts First of all, I choose a repo in Realease0.1 submissions list . The repo was created by my classmate,  Alexander Hugh. I filed an issue and forked the repo.  Second, I clone the repo to my local host and create a branch named issue-17 to add a new feature. The new feature is about adding the ignore URL patterns to  to exclude URLs from our check based on a URL pattern file. I push the new changes to the fork repo when I fix the new feature.                                                          Not Ignore URL Output                                              

Hacktoberfest pull request 1

Image
I will try to practice how to use pull request to fix issues within open source programs in release0.2 of OSD600 course. This month I am planning to pull 4 requests step by step from easy to difficult. I hope to improve my ability to fix issues of open source programs through this practice.  First of all, I try to search for some issues in GitHub. I select a simple issue for my first pull request. When I search for "add .editorconfig", There are a lot of issues about it. I can clarify them by programming languages.                                                                           Search for issues Obviously, I need to understand what is editorconfig when I c hoose this subject.  EditorConfig helps maintain consistent coding styles for multiple developers working on the same project across various editors and IDEs. I think most of programs should include this file. In this way, it can keep you code readable even if other developers pull requests to promote your code. 

Study git merge in lab3

Image
  In this week we are studying to manage multiple simultaneous changes. After modifying these files, we will use git merge to combine the changes. It is wonderful for us to collaborate with other people to contribute to the same open source project   using git merge.   I start to practice how to use git merge in my lab3 work. I need to add two new features to my link checker repos named testLink .    First of all, I create an issue #8 in my testLink repos of GitHub. Then, I create a new branch named issue-8 to add the environment variable feature which is used to make sure the program honors the CLICOLOR environment variable using “git checkout -b issue-8” command. I implement this feature in the issue-8 branch.   Second, I create an issue #9 in my testLink repos of GitHub. Then, I create a new branch named issue-9 to add the json flag which is used to causes the program to output JSON using “git checkout -b issue-8” command. I implement this feature in the issue-9 branch.   After co

Pull requests

This week we are discussing Hacktoberfest which means everyone who is interested in programming can help drive growth of open source and make positive contributions to an ever-growing community. In this way we do not only share our code GitHub, we also contribute to any GitHub-hosted repositories through pulling requests. There are some important steps. forking and cloning a project in GitHub creating branches to work on new features and fix bugs working on the code you, trying to maintain the original style and not break things creating pull requests collaborating with other developers on GitHub updating your pull requests to include fixes for review comments Following above steps, I work on Zongjin Jiang’s project-checkurl tool which is a command-line tool and can test the status of a URL. When I look at and test the file, I find that the printed version feature is static. First of all, I build a branch for my work after cloning the code. Then I create an issue and a pull request o