I believe there is somewhere a small document how it goes, although that is only the official mbed part and not the github part.
Summary (from someone who isn't really into github and what you can do with it):
Make a github account, fork the mbed library: https://github.com/mbedmicro/mbed
I installed the github windows desktop client, limitted in what it can do, enough for me. If you login it should download the library (maybe you need to press some buttons, bit ago for me I had to download a new fork).
You got your changes in the online compiler. Open the one from github in explorer. If it is limitted changes I just copy paste it (a proper editor like notepad++ or ultraedit is needed for that route). Otherwise just export it from the online compiler, and copy the relevant files/folders.
Commit it in the github client. This also gives you a list of changes. Since the previous method isn't the most secure method to do it, it is advisable to really check if they are correct.
Then on the github site you can make a pull request. On the mbed site you need to have signed the contributors agreement http://mbed.org/contributor_agreement/, and especially with your first pull request it is handy to link your mbed account.
I've submitted a pull request on the official USBDevice library in order to add support for the EA LPC11U35 QuickStart Board, and correct a few long standing bugs that have been driving me nuts. I also added pin muxing code for PIO0_3 on the LPC11U35 which allows the USB hardware to automatically connect and disconnect from the host when the cable is inserted and removed. I wasn't sure if PIO0_3 was wired for this on the LPC11U24 mbed board, so I made that part conditional. The pull request should address the following 3 issues: