I think that relying on one service is a risk, so I will write a script to migrate Qiita articles to GitHub.
In addition, my article is as follows. https://github.com/mima3/note
(Added on 2020/3/29) Please refer to the following for the migration to WordPress. https://qiita.com/mima_ita/items/f4beb31c0ba65e6ab409
Python 3.7.4 Windows10
Get the Qiita access token.
(1) Click "Issue a new token" from the application tab of the setting screen.
(2) Give read permission and press "Publish"
(3) Make a note of the access token
(1) Get the script from the following repository https://github.com/mima3/qiita_exporter
(2) Execute the script in the following format.
python qiita_to_github.py [userid] [accesstoken] [Save destination folder] [GitHub blob root URL ex.https://github.com/mima3/note/blob/master]
(3) Register the save destination folder on GitHub.
-Use Qiita API to get all the markdown described by the specified user on Qiita. -Download the image locally and rewrite the link. -On lines other than the code block, add a space 2 before the line feed code to start a new line. ・ If there is a description of "#title", change it to "#title". -Code block title (eg ""```python:test.py ") is not displayed, so respond. ・ Modify the URL to your article to the URL of the migration destination
#Task ・ What to do with expressions such as tags. ・ How do you handle comments? -The title is the file name, but it does not work depending on the characters used. Depending on the title, it may be necessary to convert it to uppercase. ・ Maybe it's better to use the Wiki function. .. .. -Twitter embedding that could be displayed on Qiita is not displayed properly. ↓ ・GitHub PagesThere is a markdown where Jekyll doesn't work. For example{%s}It will fail if the code is mixed.
Recommended Posts