Some time ago, I wrote an article about downloading an open source ebook from Github and received many likes. Some friends asked me how to write my own open source ebook. I will write in detail here…

Preparation:

  • Set up your own Github account
  • Know Markdown syntax
  • Patience to finish the article (it took me a whole day to finish it, about 10 minutes)

There are three steps to writing an open source book:

  • Set up a repository on Github to create a catalog of good books
  • Log in to Gitbook with Github authorization and create a book in Gitbook using Github repository as the source
  • Write articles in Gitbook, and then submit the writing data to the Github repository

Step 1: Set up a repository on Github and create a catalog of good books

The new warehouse

Establish warehouse

Add a new file

Build directory

# Summary* [editor's Preface](readme.md)Copy the code

Scroll to the bottom of the page and clickCommit new filebutton

Step 2: Connect to the Github repository via Gitbook

Enter thehttps://legacy.gitbook.com/To authorize login using the Github account

Authorized to log in

Add a new book

Turn to the next page

Out the import

Choose warehouse

Confirm creating a new book

Created successfully, ready to write!

Step 3: Write a book

The initial interface

Add an article

Switch to MarkDown editing mode

The interface is displayed after the switchover

Copy short book markdown format articles

Both Gitbook and Jane support Markdown, so I copied an article directly from Jane for a quick preview

Paste the copied article into the Gitbook editor

Results the preview

Update the article to Github

Check out the Github repository. Github has been updated

Watch e-books online

  • Now you’ve learned to create your own open source book!

Extension: You may encounter these problems…

Problem 1: Gitbook cannot be associated with the Github repository

Problem 2: The url of the article is pinyin, a littlelow, want to change to English


Bonus: Gives you open source project signature:

Recently I’ve been working on an open source Python book
The Great Paean Book, if you have a partner, willing to participate in the preparation of the book, or have good suggestions, you can private letter or message, I will add a signature for you in the title page of the open source book! If you want to finish this book as soon as possible, give open source projects a star!
Open source projects are here…My blog is handling synchronization to tencent cloud + community, invite everyone to come together: https://cloud.tencent.com/developer/support-plan?invite_code=37xtfq9gnbc4k