当前位置:网站首页>Contributed code to famous projects for the first time, a little nervous

Contributed code to famous projects for the first time, a little nervous

2022-06-24 16:52:00 Programmer fish skin

Hello everyone , I am the little brother of fish skin, ABA , You can also call me little Abba .

I am also very interested in programming , But it's still a little white . Come to my brother's house these days , I was thinking that brother Yupi would learn computer 、 Many devices , Will take me to play games or something . I didn't expect that I had just arrived at his house , Just ask me how my programming is going , Even want to pull me to type the code for a few days .

The first day , Brother Yupi asked me if I knew a man named GitHub Website . How could I not know , The largest open source platform in the world , You can find a lot of programs that are helpful for learning programming . He previously wrote an article on how to find high-quality projects :【 Hard core dry goods 】 How to find high quality programming projects efficiently ?, I read it carefully .

Then he asked me if I had ever participated in an open source project 、 Contribute code or something . I really haven't tried this , Although it has been GitHub View items from above , But I never thought about participating in the project . On the one hand, I am worried that I am not strong enough , I feel that those who can contribute code to open source projects are great gods ; On the other hand, I don't know how to contribute code to the project 、 Where to start .

Unexpectedly, the evil spirit of the fish skin smiled , say :“ It's not that hard to contribute code , Let me teach you !”

Finished , It is estimated that the whole holiday can only be coded .

But I didn't expect that , Under the guidance of brother Yupi , I soon learned how to contribute code to open source projects , And actually operated a wave !

I took some notes , Let's share with you , Help every programming student to participate in open source projects .

First time to participate in open source

I believe many students are like me , Discouraged from participating in open source projects , Mainly because of these two points :

  1. Don't know how to contribute code
  2. No suitable project participation found , Don't know what code to contribute

The following two methods are recommended , Solve these two problems separately .

How to contribute code

Actually ,GitHub There is an existing tutorial project on first-contributions, Bring a simple way for beginners to learn and participate in open source projects .

As the author of the project said , There is no better way to learn than to do it , therefore , This project is not a simple graphic tutorial 、 There is no complicated theoretical knowledge , More like an interesting manual , Step by step guide you to use GitHub Of Fork、Clone、 Branch 、 Submit code 、 Code release 、 Submit Pull Request( Merge request ) Complete project code submission process .

fork Warehouse

The author is very generous , Allow you to take this tutorial project directly for practical learning , And accept your request for merger . Because of the star The number is also close 2 ten thousand , So as long as you follow the tutorial and contribute to the project , It can also be said that I participated in a well-known project !

Initiate merge request

Find the code you can contribute

After learning how to contribute code , Where to find a suitable project to participate in and contribute ?

It is recommended to choose the project you are familiar with , Among the familiar projects, you should give priority to the more functions you use , Try to contribute some small changes first . Usually, the first step is to repair some documents bug、 Or start with supplementary documents and code comments . For example, there are many GitHub The mature projects of are developing rapidly , But maybe members are all developing new functions , The document is in disrepair , If you happen to use this project , Errors found in the document , Try to fix it , Although the work is not big , But I believe it will bring you a great sense of achievement .

Many project documents have Edit Links

By reading and modifying documents , You can become more familiar with the project , Understand his design idea and technical architecture . When using project functions, you will encounter bug, Sure Mention a issues( Submitting code is not the only thing that counts , Asking questions is also a contribution ), Then you can try to repair this small bug, Some may only need to change a few lines of code , But the impact will be great , Successful repair can also be recognized by many students , So as to encourage you to further optimize and improve this function , Improve your level .

Even if I don't have any projects bug, You can also go directly to the project issues page Check other students' problems , Many problems are not troublesome , But the authorities have no time to solve it , This is often the best time for us to participate in open source .

Like Ali's Ant Design project , And near 600 A problem to be solved !

So many issues, How to choose a problem suitable for beginners

It's very simple , Direct access github.com/<owner>/<repository>/contribute Address , You can find out the topics suitable for beginners in the designated warehouse .

such as Ant Design project , Access address :https://github.com/ant-design/ant-design/contribute, Go to the warehouse contribution page , In fact, it is to add a... At the back of the warehouse contribute nothing more .

Then you can see a lot of them good first issue label 、 Problems suitable for beginners , And a warehouse contribution guide :

Warehouse contribution page

These problems are usually not difficult to solve 、 The cost is not high , And it is of great learning significance .

Try to solve issue

It's highly recommended to Read the contribution guide , Then learn how others think about solving problems , Try it yourself again !

When you solve more and more problems , Or get familiar with the project , You can develop new features for the entire project , Even join the core team of the project ! Of course , This is the later story. , From programming Xiaobai to open source boss , Without typing hundreds of thousands of lines of code , I don't think so .


Okay , Just share it here .

Although this holiday was dragged by brother Yupi to knock the code for a few days , Not a game , But I still Point a praise Thank him , Contribute more code to open source projects in the future , My level can't take off !

Discovery items :https://www.code-nav.cn/rd/?rid=28ee4e3e604f7ce60ad166027f272d9e

原网站

版权声明
本文为[Programmer fish skin]所创,转载请带上原文链接,感谢
https://yzsam.com/2021/04/20210406201237548e.html