DanielStenberg–August13th
2020
Landing code in
Daniel Stenberg
@bagderhttps://daniel.haxx.se
Daniel Stenberg
@bagder
CommunityCommunity
BuildingBuilding
TestingTesting
SubmittingSubmitting
FeedbackFeedback
MergingMerging
ReleaseRelease
@bagder@bagder
Q&A in the end!Q&A in the end!
@bagder@bagder
@bagder@bagder
Lessons on how to code – you know
that already
URLs to the various resources – you
can find them
Discussions on what tools to use –
use whatever you like
This presentation will not include
@bagder@bagder
@bagder@bagder
2,200 contributors – 200 new/year
820 authors – 100 new/year
15 active maintainers
30-50 in progress Pull-Requests in GitHub at all times
You are not alone
@bagder@bagder
@bagder@bagder
Community & communication in curl
The curl-library mailing list
Questions, support, brainstorms,
suggestions, ideas, debugging,
roadmap, feedback
Issues and Pull-Requests on
GitHub
Bugs and improvements
#curl IRC channel on
Freenode
Chit chat - anything
@bagder@bagder
HackerOne
Security problems
@bagder@bagder
We’re nice to each other
Code of Conduct
@bagder@bagder
@bagder@bagder
Clone the github git repository
Since you’re going to change code, make your own fork
Get the curl project’s code, not from anyone else hosting it
Get the latest / master
Get the curl code
@bagder@bagder
Build the unmodified version first
Verifies you have the infra setup accordingly
Autotools (configure), cmake and Windows build systems
are supported
‘make test’
Build curl
@bagder@bagder
@bagder@bagder
Most of the code is C89
Code style
Documentation?
Update or add tests?
Change the curl code
@bagder@bagder
@bagder@bagder
./configure --enable-debug
make checksrc
make test
Test your curl code
@bagder@bagder
@bagder@bagder
Commit the change in a local git branch
Gold points: follow the git message
template
Git push the commit(s) in your curl fork
Commit and push the codeCommit and push the code
@bagder@bagder
@bagder@bagder
Submit your dedicated branch in a pull request to curl/curl
Listen to feedback, amend the branch to adapt
The PR will trigger a large amount of CI jobs, tests and
analyzes
Watch incoming CI job results, amend the branch to adapt
It might take a while to get human response
Create a Pull Request on curl
@bagder@bagder
@bagder@bagder
No CLA or form to sign to contribute code
By submitting code, you are assumed to have the right to
For a large change, you can add your copyright line
Must not interfere with or be incompatible with license
curl copyright and license
@bagder@bagder
@bagder@bagder
Each PR triggers 90+ builds
Tests, sanitizers and analyses are run on many platforms
with numerous setups and different configs
Unfortunately, CI jobs sometimes fail as false positives
Follow-up commits to the branch restarts the CI builds
The curl CI system
@bagder@bagder
@bagder@bagder
Who reviews Pull Requests?Who reviews Pull Requests?
Anyone can
Everyone is encouraged to
Maintainers tend to watch out for “their areas”
Daniel most likely will
@bagder@bagder
@bagder@bagder
Who decides what’s a good new feature?
It must beIt must be URL/transferURL/transfer relatedrelated
It is aIt is a discussiondiscussion – argue for your point– argue for your point
DanielDaniel has the final sayhas the final say
Old decisions can beOld decisions can be brought backbrought back
@bagder@bagder
@bagder@bagder
If you disagree with a comment/remark: argue your case
For small incremental changes, do a follow-up commit and
push
For larger changes, consider squashing commits and force-
push a new take – to simplify the review process
Did I mention ‘make checksrc’ ?
Amend a Pull Request
@bagder@bagder
@bagder@bagder
Once all feedback and test failures are addressed
Bug-fixes can get merged any at point in the release cycle
Features can only get merged when the feature-window is
open
Someone will merge it with a “Closes #1234” GitHub
instruction
Merging a Pull Request into curl
@bagder@bagder
@bagder@bagder
The next PR will be easier!
The first one is the hardestThe first one is the hardest
The second time you know what to expectThe second time you know what to expect
Consider reviewing other PRsConsider reviewing other PRs
Help us improve docs for other first-timersHelp us improve docs for other first-timers
@bagder@bagder
@bagder@bagder
Everything is merged via PRsEverything is merged via PRs
The same procedures and rules apply to everyone
@bagder@bagder
@bagder@bagder
All commits merged into the master branch
At the time of the release
There’s always another chance in the next release!
We do releases every eight weeks
Contents of a curl release
@bagder@bagder
@bagder@bagder
“scratch your own itch”
Existing issues on GitHub
KNOWN_BUGS and TODO
Need ideas of what to work on?
@bagder@bagder
@bagder@bagder
We are all on the same team
Ask when in doubt
We love you for helping out and being one of us
We want you to succeed!
@bagder@bagder
Commercial curl support!
@bagder@bagder
https://curl.haxx.se/dev/
https://github.com/curl/curl
@bagder@bagder
Daniel Stenberg
@bagder
https://daniel.haxx.se/
Thank you!Thank you!
Questions?Questions?
@bagder@bagder
@bagder@bagder
License
This presentation and its contents are
licensed under the Creative Commons
Attribution 4.0 license:
http://creativecommons.org/licenses/by/4.0/

Landing code in curl