-
Notifications
You must be signed in to change notification settings - Fork 0
/
atom.xml
426 lines (387 loc) · 36 KB
/
atom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<title><![CDATA[Ryuya's Blog]]></title>
<subtitle><![CDATA[Ryuya's Blog]]></subtitle>
<link href="/atom.xml" rel="self"/>
<link href="http://yoursite.com/"/>
<updated>2018-03-14T16:25:38.759Z</updated>
<id>http://yoursite.com/</id>
<author>
<name><![CDATA[Ryuya]]></name>
</author>
<generator uri="http://hexo.io/">Hexo</generator>
<entry>
<title><![CDATA[快速搭建ssr服务器]]></title>
<link href="http://yoursite.com/2018/03/15/%E5%BF%AB%E9%80%9F%E6%90%AD%E5%BB%BAssr%E6%9C%8D%E5%8A%A1%E5%99%A8/"/>
<id>http://yoursite.com/2018/03/15/快速搭建ssr服务器/</id>
<published>2018-03-14T15:00:36.000Z</published>
<updated>2018-03-14T16:25:38.759Z</updated>
<content type="html"><![CDATA[<p>####安装####</p>
<ol>
<li>获取root权限:<code>sudo su</code></li>
<li>安装:</li>
</ol>
<p><code>wget -N --no-check-certificate https://softs.fun/Bash/ssrmu.sh && chmod +x ssrmu.sh && bash ssrmu.sh</code></p>
<p>####维护####</p>
<ol>
<li><code>sudo su</code></li>
<li><code>bash ssrmu.sh</code></li>
</ol>
<a id="more"></a>
<hr>
<p>####服务器部分####</p>
<p>推荐使用googlecloud</p>
<p>进入console.cloud.google.com</p>
<p>创建实例后,ssh链接安装ssr,记得修改防火墙规则</p>
<hr>
<p>备用网址:</p>
<p>ssr客户端下载: <a href="https://doub.io/ss-jc10/" target="_blank" rel="noopener">https://doub.io/ss-jc10/</a></p>
<p>ss临时账号:<a href="https://global.ishadowx.net/" target="_blank" rel="noopener">https://global.ishadowx.net/</a></p>
]]></content>
<summary type="html">
<![CDATA[<p>####安装####</p>
<ol>
<li>获取root权限:<code>sudo su</code></li>
<li>安装:</li>
</ol>
<p><code>wget -N --no-check-certificate https://softs.fun/Bash/ssrmu.sh && chmod +x ssrmu.sh && bash ssrmu.sh</code></p>
<p>####维护####</p>
<ol>
<li><code>sudo su</code></li>
<li><code>bash ssrmu.sh</code></li>
</ol>]]>
</summary>
<category term="linux ssr" scheme="http://yoursite.com/tags/linux-ssr/"/>
</entry>
<entry>
<title><![CDATA[Useful Tips for MacOS]]></title>
<link href="http://yoursite.com/2018/01/23/Useful-Tips-for-MacOS/"/>
<id>http://yoursite.com/2018/01/23/Useful-Tips-for-MacOS/</id>
<published>2018-01-23T05:29:34.000Z</published>
<updated>2018-01-23T06:11:05.332Z</updated>
<content type="html"><![CDATA[<h3 id="u5E94_u7528_u7BC7"><a href="#u5E94_u7528_u7BC7" class="headerlink" title="应用篇"></a>应用篇</h3><p><strong>karabiner-elements</strong>:键盘自定义,可以将日文键盘不太使用的英数键改成delete,かな键改成中英切换。</p>
<p>打开:~/.config/karabiner/karabiner.json</p>
<a id="more"></a>
<pre><code> "rules": [
{
"manipulators": [
{
"description": "Change caps_lock to command+control+option+shift.",
"from": {
"key_code": "japanese_kana",
"modifiers": {
"optional": [
"any"
]
}
},
"to": [
{
"key_code": "spacebar",
"modifiers": [
"left_option"
]
}
],
"type": "basic"
}
]
}
]
"simple_modifications": [
{
"from": {
"key_code": "japanese_eisuu"
},
"to": {
"key_code": "delete_or_backspace"
}
}
],
</code></pre><p><strong>gfxCardastatus</strong>:帮助切换核心或者独立显卡</p>
<p><strong>Noizio</strong>:模拟大自然的背景声</p>
<p><strong>Typora</strong>:markdown编辑器</p>
<p><strong>iPic</strong>:图床</p>
<p><strong>Itsycal</strong>:状态栏小日历</p>
<p><strong>Vanilla</strong>:状态栏管理,可以隐藏或删除图标</p>
<p><strong>TouchSwitcher</strong>:用Touchbar更快捷切换应用</p>
<p><strong>IINA</strong>:视频播放器</p>
<p><strong>CheatSheet</strong>:长按command可显示当前应用的所有快捷键</p>
<h3 id="u8BBE_u7F6E_u7BC7"><a href="#u8BBE_u7F6E_u7BC7" class="headerlink" title="设置篇"></a>设置篇</h3><p><strong>自动操作</strong>(创建一个搜索的服务,参考自<a href="https://stackoverflow.com/questions/17935301/how-to-force-mac-os-to-open-search-with-google-in-chrome" target="_blank" rel="noopener">StackOverflow</a>):</p>
<ol>
<li><p>Open Automator and choose Service as the type</p>
</li>
<li><p>Add a “Run Shell Script” action by dragging it to the right pane <a href="https://i.stack.imgur.com/D27Va.png" target="_blank" rel="noopener"><img src="https://i.stack.imgur.com/D27Va.png" alt="enter image description here"></a></p>
</li>
<li><p>Add script</p>
<p><code>open "http://www.google.com/search?q=$(ruby -rcgi -e 'print CGI.escape $<.read.chomp')"</code></p>
<p>Adjust the TLD as needed for your country specific Google page. ex: <a href="http://www.google.co.in/search?q=" target="_blank" rel="noopener">http://www.google.co.in/search?q=</a></p>
</li>
<li><p>Save the service as “Search Google”</p>
</li>
<li><p>Activate the service in System Preferences and optionally assign a keyboard shortcut. Once activated, “Search Google” will appear in the context menu<a href="https://i.stack.imgur.com/DhuJX.png" target="_blank" rel="noopener"><img src="https://i.stack.imgur.com/DhuJX.png" alt="enter image description here"></a></p>
</li>
</ol>
<p><strong>触发角</strong>:</p>
<p><img src="https://ws4.sinaimg.cn/large/006tNc79gy1fnqi32gsijj31120swn6d.jpg" alt=""></p>
<p><strong>Touchbar</strong>:</p>
<p>Finder-显示-自定触控栏 </p>
<p><img src="https://ws1.sinaimg.cn/large/006tNc79gy1fnqi67yzocj31kw01lmxg.jpg" alt=""></p>
<p>shift+command+6 可以对其截图。</p>
]]></content>
<summary type="html">
<![CDATA[<h3 id="u5E94_u7528_u7BC7"><a href="#u5E94_u7528_u7BC7" class="headerlink" title="应用篇"></a>应用篇</h3><p><strong>karabiner-elements</strong>:键盘自定义,可以将日文键盘不太使用的英数键改成delete,かな键改成中英切换。</p>
<p>打开:~/.config/karabiner/karabiner.json</p>]]>
</summary>
<category term="MacOS tips" scheme="http://yoursite.com/tags/MacOS-tips/"/>
</entry>
<entry>
<title><![CDATA[One line solution]]></title>
<link href="http://yoursite.com/2018/01/21/One-line-solution/"/>
<id>http://yoursite.com/2018/01/21/One-line-solution/</id>
<published>2018-01-21T14:36:08.000Z</published>
<updated>2018-01-21T15:54:31.514Z</updated>
<content type="html"><![CDATA[<p>最近开始用python做leetcode,很多题能用python写的十分简洁。在此做一个前30题里能用1-3行解决的问题小结。</p>
<hr>
<p>Q9_Palindrome Number</p>
<p>判断回文数,将其转换成字符串类型后直接比较其翻转版本。</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br></pre></td><td class="code"><pre><span class="line"><span class="class"><span class="keyword">class</span> <span class="title">Solution</span>:</span></span><br><span class="line"> <span class="function"><span class="keyword">def</span> <span class="title">isPalindrome</span><span class="params">(self, x)</span>:</span></span><br><span class="line"> <span class="keyword">return</span> str(x) == str(x)[::<span class="number">-1</span>]</span><br></pre></td></tr></table></figure>
<hr>
<a id="more"></a>
<p>Q17_Phone Number</p>
<p>输入电话按键,输出对应的可能字母组合。首先使用一个字典存储每个数字对应的字母,再作一个递归解决。</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br></pre></td><td class="code"><pre><span class="line"><span class="class"><span class="keyword">class</span> <span class="title">Solution</span>:</span></span><br><span class="line"> dic = {<span class="string">'2'</span>: <span class="string">'abc'</span>, <span class="string">'3'</span>: <span class="string">'def'</span>, <span class="string">'4'</span>: <span class="string">'ghi'</span>, <span class="string">'5'</span>: <span class="string">'jkl'</span>, <span class="string">'6'</span>: <span class="string">'mno'</span>, <span class="string">'7'</span>: <span class="string">'pqrs'</span>, <span class="string">'8'</span>: <span class="string">'tuv'</span>, <span class="string">'9'</span>: <span class="string">'wxyz'</span>}</span><br><span class="line"> <span class="function"><span class="keyword">def</span> <span class="title">letterCombinations</span><span class="params">(self, digits)</span>:</span></span><br><span class="line"> <span class="keyword">return</span> [b + a <span class="keyword">for</span> b <span class="keyword">in</span> self.dic.get(digits[:<span class="number">1</span>],<span class="string">""</span>) <span class="keyword">for</span> a <span class="keyword">in</span> self.letterCombinations(digits[<span class="number">1</span>:]) <span class="keyword">or</span> [<span class="string">''</span>]] <span class="keyword">or</span> []</span><br></pre></td></tr></table></figure>
<hr>
<p>Q22_Generate Parentheses</p>
<p>生成给定n对括号的所有可能合法组合。添加一个默认参数op,表示没有闭合的左括号个数,再用n记未使用的左括号个数,使用递归完成。</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br></pre></td><td class="code"><pre><span class="line"><span class="class"><span class="keyword">class</span> <span class="title">Solution</span>:</span></span><br><span class="line"> <span class="function"><span class="keyword">def</span> <span class="title">generateParenthesis</span><span class="params">(self, n, op=<span class="number">0</span>)</span>:</span></span><br><span class="line"> <span class="keyword">if</span> n > <span class="number">0</span> <span class="keyword">and</span> op >= <span class="number">0</span>:</span><br><span class="line"> <span class="keyword">return</span> [<span class="string">"("</span> + p <span class="keyword">for</span> p <span class="keyword">in</span> self.generateParenthesis(n - <span class="number">1</span>, op + <span class="number">1</span>)] + \</span><br><span class="line"> [<span class="string">")"</span> + p <span class="keyword">for</span> p <span class="keyword">in</span> self.generateParenthesis(n, op - <span class="number">1</span>)]</span><br><span class="line"> <span class="keyword">return</span> [<span class="string">")"</span> * op] * (n == <span class="number">0</span>)</span><br></pre></td></tr></table></figure>]]></content>
<summary type="html">
<![CDATA[<p>最近开始用python做leetcode,很多题能用python写的十分简洁。在此做一个前30题里能用1-3行解决的问题小结。</p>
<hr>
<p>Q9_Palindrome Number</p>
<p>判断回文数,将其转换成字符串类型后直接比较其翻转版本。</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br></pre></td><td class="code"><pre><span class="line"><span class="class"><span class="keyword">class</span> <span class="title">Solution</span>:</span></span><br><span class="line"> <span class="function"><span class="keyword">def</span> <span class="title">isPalindrome</span><span class="params">(self, x)</span>:</span></span><br><span class="line"> <span class="keyword">return</span> str(x) == str(x)[::<span class="number">-1</span>]</span><br></pre></td></tr></table></figure>
<hr>]]>
</summary>
<category term="python leetcode" scheme="http://yoursite.com/tags/python-leetcode/"/>
</entry>
<entry>
<title><![CDATA[The Zen of Python]]></title>
<link href="http://yoursite.com/2018/01/17/The-Zen-of-Python/"/>
<id>http://yoursite.com/2018/01/17/The-Zen-of-Python/</id>
<published>2018-01-16T18:48:04.000Z</published>
<updated>2018-01-17T16:45:36.679Z</updated>
<content type="html"><![CDATA[<p>今天学完了sololearn上python3的课程,完成新年第一个任务。</p>
<a id="more"></a>
<p><img src="https://www.sololearn.com/Certificate/1073-5640152/jpg/?mode=download" alt=""></p>
<p>Sololearn的课程在最后一章提到了python的哲学,当你在shell中输入</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line"><span class="keyword">import</span> this</span><br></pre></td></tr></table></figure>
<p>会输出</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br></pre></td><td class="code"><pre><span class="line">/Users/zhou/anaconda3/envs/py3<span class="number">.6</span>/bin/python /Users/zhou/PycharmProjects/learning/test.py</span><br><span class="line">The Zen of Python, by Tim Peters</span><br><span class="line"></span><br><span class="line">Beautiful <span class="keyword">is</span> better than ugly.</span><br><span class="line">Explicit <span class="keyword">is</span> better than implicit.</span><br><span class="line">Simple <span class="keyword">is</span> better than complex.</span><br><span class="line">Complex <span class="keyword">is</span> better than complicated.</span><br><span class="line">Flat <span class="keyword">is</span> better than nested.</span><br><span class="line">Sparse <span class="keyword">is</span> better than dense.</span><br><span class="line">Readability counts.</span><br><span class="line">Special cases aren<span class="string">'t special enough to break the rules.</span></span><br><span class="line"><span class="string">Although practicality beats purity.</span></span><br><span class="line"><span class="string">Errors should never pass silently.</span></span><br><span class="line"><span class="string">Unless explicitly silenced.</span></span><br><span class="line"><span class="string">In the face of ambiguity, refuse the temptation to guess.</span></span><br><span class="line"><span class="string">There should be one-- and preferably only one --obvious way to do it.</span></span><br><span class="line"><span class="string">Although that way may not be obvious at first unless you'</span>re Dutch.</span><br><span class="line">Now <span class="keyword">is</span> better than never.</span><br><span class="line">Although never <span class="keyword">is</span> often better than *right* now.</span><br><span class="line">If the implementation <span class="keyword">is</span> hard to explain, it<span class="string">'s a bad idea.</span></span><br><span class="line"><span class="string">If the implementation is easy to explain, it may be a good idea.</span></span><br><span class="line"><span class="string">Namespaces are one honking great idea -- let'</span>s do more of those!</span><br><span class="line"></span><br><span class="line">Process finished <span class="keyword">with</span> exit code <span class="number">0</span></span><br></pre></td></tr></table></figure>
<p>有趣的点有二,一是</p>
<blockquote>
<p>Although that way may not be obvious at first unless you’re Dutch.</p>
</blockquote>
<p>此处的Dutch是指Python之父<a href="http://www.python.org/~guido/" target="_blank" rel="noopener">Guido van Rossum</a>是荷兰人.</p>
<p>二是查看this的代码,可以看出其写法非常有意思:</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br></pre></td><td class="code"><pre><span class="line">s = <span class="string">"""Gur Mra bs Clguba, ol Gvz Crgref</span></span><br><span class="line"><span class="string"> </span></span><br><span class="line"><span class="string">Ornhgvshy vf orggre guna htyl.</span></span><br><span class="line"><span class="string">Rkcyvpvg vf orggre guna vzcyvpvg.</span></span><br><span class="line"><span class="string">Fvzcyr vf orggre guna pbzcyrk.</span></span><br><span class="line"><span class="string">Pbzcyrk vf orggre guna pbzcyvpngrq.</span></span><br><span class="line"><span class="string">Syng vf orggre guna arfgrq.</span></span><br><span class="line"><span class="string">Fcnefr vf orggre guna qrafr.</span></span><br><span class="line"><span class="string">Ernqnovyvgl pbhagf.</span></span><br><span class="line"><span class="string">Fcrpvny pnfrf nera'g fcrpvny rabhtu gb oernx gur ehyrf.</span></span><br><span class="line"><span class="string">Nygubhtu cenpgvpnyvgl orngf chevgl.</span></span><br><span class="line"><span class="string">Reebef fubhyq arire cnff fvyragyl.</span></span><br><span class="line"><span class="string">Hayrff rkcyvpvgyl fvyraprq.</span></span><br><span class="line"><span class="string">Va gur snpr bs nzovthvgl, ershfr gur grzcgngvba gb thrff.</span></span><br><span class="line"><span class="string">Gurer fubhyq or bar-- naq cersrenoyl bayl bar --boivbhf jnl gb qb vg.</span></span><br><span class="line"><span class="string">Nygubhtu gung jnl znl abg or boivbhf ng svefg hayrff lbh'er Qhgpu.</span></span><br><span class="line"><span class="string">Abj vf orggre guna arire.</span></span><br><span class="line"><span class="string">Nygubhtu arire vf bsgra orggre guna *evtug* abj.</span></span><br><span class="line"><span class="string">Vs gur vzcyrzragngvba vf uneq gb rkcynva, vg'f n onq vqrn.</span></span><br><span class="line"><span class="string">Vs gur vzcyrzragngvba vf rnfl gb rkcynva, vg znl or n tbbq vqrn.</span></span><br><span class="line"><span class="string">Anzrfcnprf ner bar ubaxvat terng vqrn -- yrg'f qb zber bs gubfr!"""</span></span><br><span class="line"> </span><br><span class="line">d = {}</span><br><span class="line"><span class="keyword">for</span> c <span class="keyword">in</span> (<span class="number">65</span>, <span class="number">97</span>):</span><br><span class="line"> <span class="keyword">for</span> i <span class="keyword">in</span> range(<span class="number">26</span>):</span><br><span class="line"> d[chr(i+c)] = chr((i+<span class="number">13</span>) % <span class="number">26</span> + c)</span><br><span class="line"></span><br><span class="line">print(<span class="string">""</span>.join([d.get(c, c) <span class="keyword">for</span> c <span class="keyword">in</span> s]))</span><br></pre></td></tr></table></figure>
<p>这段代码使用d来保存一个字典,再用两个循环将a-z,A-Z作为key,通过对其ASCII码进行加13模26的运算获得对应value,实质是一个凯撒加密。</p>
]]></content>
<summary type="html">
<![CDATA[<p>今天学完了sololearn上python3的课程,完成新年第一个任务。</p>]]>
</summary>
<category term="python" scheme="http://yoursite.com/tags/python/"/>
</entry>
<entry>
<title><![CDATA[2018 plan]]></title>
<link href="http://yoursite.com/2018/01/15/2018-plan/"/>
<id>http://yoursite.com/2018/01/15/2018-plan/</id>
<published>2018-01-15T12:50:42.000Z</published>
<updated>2018-01-16T20:19:50.188Z</updated>
<content type="html"><![CDATA[<ul>
<li><del>使用sololearn完成python3的学习</del></li>
</ul>
<ul>
<li>使用python做完leetcode</li>
<li>完成东大情报创情的过去问</li>
<li>读完英语原著《harry potter》</li>
<li>学习机器学习并完成一些项目</li>
<li>找一份实习</li>
</ul>
]]></content>
<summary type="html">
<![CDATA[<ul>
<li><del>使用sololearn完成python3的学习</del></li>
</ul>
<ul>
<li>使用python做完leetcode</li>
<li>完成东大情报创情的过去问</li>
<li>读完英语原著《harry potter》</li>
]]>
</summary>
<category term="plan" scheme="http://yoursite.com/tags/plan/"/>
</entry>
<entry>
<title><![CDATA[使用Sublime Text书写Markdown]]></title>
<link href="http://yoursite.com/2016/02/05/%E4%BD%BF%E7%94%A8Sublime%20Text%E4%B9%A6%E5%86%99Markdown/"/>
<id>http://yoursite.com/2016/02/05/使用Sublime Text书写Markdown/</id>
<published>2016-02-05T07:11:31.000Z</published>
<updated>2016-02-05T17:17:54.000Z</updated>
<content type="html"><![CDATA[<h2 id="u4EC0_u4E48_u662F_Markdown"><a href="#u4EC0_u4E48_u662F_Markdown" class="headerlink" title="什么是 Markdown"></a>什么是 Markdown</h2><p>Markdown 是一种方便记忆、书写的纯文本标记语言,用户可以使用这些标记符号以最小的输入代价生成极富表现力的文档:它使用简单的符号标记不同的标题,分割不同的段落,<strong>粗体</strong> 或者 <em>斜体</em> 某些文字,它还可以</p>
<h3 id="u5236_u4F5C_u4E00_u4EFD_u5F85_u529E_u4E8B_u5B9C"><a href="#u5236_u4F5C_u4E00_u4EFD_u5F85_u529E_u4E8B_u5B9C" class="headerlink" title="制作一份待办事宜"></a>制作一份待办事宜</h3><ul>
<li><del>使用Github进行代码管理</del></li>
<li><del>建立独立Blog</del></li>
<li>熟练Markdown的语法</li>
<li>使用$\LaTeX$写论文</li>
</ul>
<h3 id="u4E66_u5199_u4E00_u4E2A_u8D28_u80FD_u5B88_u6052_u516C_u5F0F"><a href="#u4E66_u5199_u4E00_u4E2A_u8D28_u80FD_u5B88_u6052_u516C_u5F0F" class="headerlink" title="书写一个质能守恒公式"></a>书写一个质能守恒公式</h3><p>$$E=mc^2$$</p>
<h3 id="u9AD8_u4EAE_u4E00_u6BB5_u4EE3_u7801"><a href="#u9AD8_u4EAE_u4E00_u6BB5_u4EE3_u7801" class="headerlink" title="高亮一段代码"></a>高亮一段代码</h3><figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br></pre></td><td class="code"><pre><span class="line"><span class="meta">@requires_authorization</span></span><br><span class="line"><span class="class"><span class="keyword">class</span> <span class="title">SomeClass</span>:</span></span><br><span class="line"> <span class="keyword">pass</span></span><br><span class="line"></span><br><span class="line"><span class="keyword">if</span> __name__ == <span class="string">'__main__'</span>:</span><br><span class="line"> <span class="comment"># A comment</span></span><br><span class="line"> <span class="keyword">print</span> <span class="string">'hello world'</span></span><br></pre></td></tr></table></figure>
<a id="more"></a>
<h3 id="u7ED8_u5236_u8868_u683C"><a href="#u7ED8_u5236_u8868_u683C" class="headerlink" title="绘制表格"></a>绘制表格</h3><table>
<thead>
<tr>
<th>Item</th>
<th style="text-align:right">Price</th>
<th style="text-align:center">Numbers</th>
</tr>
</thead>
<tbody>
<tr>
<td>PC</td>
<td style="text-align:right">\$1600</td>
<td style="text-align:center">1</td>
</tr>
<tr>
<td>Pen</td>
<td style="text-align:right">\$3</td>
<td style="text-align:center">10</td>
</tr>
<tr>
<td>Paper</td>
<td style="text-align:right">\$1</td>
<td style="text-align:center">200</td>
</tr>
</tbody>
</table>
<p>不同于其它 <em>所见即所得</em> 的编辑器:你只需使用键盘专注于书写文本内容,就可以生成印刷级的排版格式,省却在键盘和工具栏之间来回切换,调整内容和格式的麻烦。<strong>Markdown 在流畅的书写和印刷级的阅读体验之间找到了平衡。</strong> 目前它已经成为世界上最大的技术分享网站 GitHub 和 技术问答网站 StackOverFlow 的御用书写格式。</p>
<hr>
<h2 id="u4EC0_u4E48_u662FSublime_Text"><a href="#u4EC0_u4E48_u662FSublime_Text" class="headerlink" title="什么是Sublime Text"></a>什么是Sublime Text</h2><p><a href="http://www.sublimetext.com/" target="_blank" rel="noopener">Sublime Text</a>是一个代码编辑器,也是一个先进的文本编辑器。对比其他编辑器,体积小,运行速度快,界面漂亮,支持编译,重要的是具有几乎无限的拓展功能。</p>
<hr>
<h2 id="u5982_u4F55_u4F7F_u7528Sublime_Text_u4E66_u5199Markdown"><a href="#u5982_u4F55_u4F7F_u7528Sublime_Text_u4E66_u5199Markdown" class="headerlink" title="如何使用Sublime Text书写Markdown"></a>如何使用Sublime Text书写Markdown</h2><p><em>本文针对Sublime Text 3,Windows 10 x64系统</em></p>
<p>Sublime Text拥有大量的插件进行功能拓展,在此介绍一套比较舒服的解决方案(MarkDown Editing+OmniMarkupPreviwer)。</p>
<h3 id="u5B89_u88C5_u63D2_u4EF6_u7684_u65B9_u6CD5"><a href="#u5B89_u88C5_u63D2_u4EF6_u7684_u65B9_u6CD5" class="headerlink" title="安装插件的方法"></a>安装插件的方法</h3><ul>
<li>Ctrl+`调出console</li>
<li><p>输入以下代码</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line"><span class="keyword">import</span> urllib.request,os,hashlib; h = <span class="string">'2915d1851351e5ee549c20394736b442'</span> + <span class="string">'8bc59f460fa1548d1514676163dafc88'</span>; pf = <span class="string">'Package Control.sublime-package'</span>; ipp = sublime.installed_packages_path(); urllib.request.install_opener( urllib.request.build_opener( urllib.request.ProxyHandler()) ); by = urllib.request.urlopen( <span class="string">'http://packagecontrol.io/'</span> + pf.replace(<span class="string">' '</span>, <span class="string">'%20'</span>)).read(); dh = hashlib.sha256(by).hexdigest(); print(<span class="string">'Error validating download (got %s instead of %s), please try manual install'</span> % (dh, h)) <span class="keyword">if</span> dh != h <span class="keyword">else</span> open(os.path.join( ipp, pf), <span class="string">'wb'</span> ).write(by)</span><br></pre></td></tr></table></figure>
</li>
<li><p>Ctrl+Shift+P调出命令面板,选择Install Package。</p>
</li>
</ul>
<h3 id="MarkDown_Editing"><a href="#MarkDown_Editing" class="headerlink" title="MarkDown Editing"></a>MarkDown Editing</h3><p>MarkDown Editing支持Markdown语法高亮;支持Github Favored。 Markdown语法;自带3个主题。<br>安装后重启Sublime Text即可。</p>
<h3 id="OmniMarkupPreviwer"><a href="#OmniMarkupPreviwer" class="headerlink" title="OmniMarkupPreviwer"></a>OmniMarkupPreviwer</h3><p>实时在浏览器中预览,如果大屏/双屏/多设备的话,具有很不错的体验。快捷键如下:<br>Ctrl+Alt+O: Preview Markup in Browser<br>Ctrl+Alt+X: Export Markup as HTML<br>Ctrl+Alt+C: Copy Markup as HTML<br>如果想要更好的体验,可以修改<em>Sublime Text 3/Packages/OmniMarkupPreviewer.sublime-settings</em> 文件。</p>
<figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br></pre></td><td class="code"><pre><span class="line"><span class="string">"server_host"</span>: <span class="string">"127.0.0.1"</span>,</span><br><span class="line"><span class="string">"mathjax_enabled"</span>: <span class="literal">true</span></span><br></pre></td></tr></table></figure>
<p>修改<code>server_host</code>为局域网地址便可实现多设备实时预览(默认为localhost)。</p>
<p>开启<code>mathjax_enabled</code>可以支持使用$\LaTeX$语法编辑数学公式。</p>
<p>More info: <a href="http://www.jianshu.com/p/aa30cc25c91b" target="_blank" rel="noopener">Sublime插件:Markdown篇</a></p>
<hr>
]]></content>
<summary type="html">
<![CDATA[<h2 id="u4EC0_u4E48_u662F_Markdown"><a href="#u4EC0_u4E48_u662F_Markdown" class="headerlink" title="什么是 Markdown"></a>什么是 Markdown</h2><p>Markdown 是一种方便记忆、书写的纯文本标记语言,用户可以使用这些标记符号以最小的输入代价生成极富表现力的文档:它使用简单的符号标记不同的标题,分割不同的段落,<strong>粗体</strong> 或者 <em>斜体</em> 某些文字,它还可以</p>
<h3 id="u5236_u4F5C_u4E00_u4EFD_u5F85_u529E_u4E8B_u5B9C"><a href="#u5236_u4F5C_u4E00_u4EFD_u5F85_u529E_u4E8B_u5B9C" class="headerlink" title="制作一份待办事宜"></a>制作一份待办事宜</h3><ul>
<li><del>使用Github进行代码管理</del></li>
<li><del>建立独立Blog</del></li>
<li>熟练Markdown的语法</li>
<li>使用$\LaTeX$写论文</li>
</ul>
<h3 id="u4E66_u5199_u4E00_u4E2A_u8D28_u80FD_u5B88_u6052_u516C_u5F0F"><a href="#u4E66_u5199_u4E00_u4E2A_u8D28_u80FD_u5B88_u6052_u516C_u5F0F" class="headerlink" title="书写一个质能守恒公式"></a>书写一个质能守恒公式</h3><p>$$E=mc^2$$</p>
<h3 id="u9AD8_u4EAE_u4E00_u6BB5_u4EE3_u7801"><a href="#u9AD8_u4EAE_u4E00_u6BB5_u4EE3_u7801" class="headerlink" title="高亮一段代码"></a>高亮一段代码</h3><figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br></pre></td><td class="code"><pre><span class="line"><span class="meta">@requires_authorization</span></span><br><span class="line"><span class="class"><span class="keyword">class</span> <span class="title">SomeClass</span>:</span></span><br><span class="line"> <span class="keyword">pass</span></span><br><span class="line"></span><br><span class="line"><span class="keyword">if</span> __name__ == <span class="string">'__main__'</span>:</span><br><span class="line"> <span class="comment"># A comment</span></span><br><span class="line"> <span class="keyword">print</span> <span class="string">'hello world'</span></span><br></pre></td></tr></table></figure>]]>
</summary>
<category term="Markdown" scheme="http://yoursite.com/tags/Markdown/"/>
<category term="Sublime Text" scheme="http://yoursite.com/tags/Sublime-Text/"/>
<category term="Web" scheme="http://yoursite.com/categories/Web/"/>
</entry>
<entry>
<title><![CDATA[搭建blog学习笔记]]></title>
<link href="http://yoursite.com/2016/02/04/%E6%90%AD%E5%BB%BAblog%E5%AD%A6%E4%B9%A0%E7%AC%94%E8%AE%B0/"/>
<id>http://yoursite.com/2016/02/04/搭建blog学习笔记/</id>
<published>2016-02-04T08:54:01.000Z</published>
<updated>2016-02-05T11:46:24.000Z</updated>
<content type="html"><![CDATA[<h2 id="u5185_u5BB9_u63D0_u8981"><a href="#u5185_u5BB9_u63D0_u8981" class="headerlink" title="内容提要"></a>内容提要</h2><blockquote>
<ul>
<li>注册github,创建github page</li>
<li>git,node.js,hexo的安装</li>
<li>域名的购买与解析</li>
<li>hexo的基础用法<a id="more"></a>
</li>
</ul>
</blockquote>
<hr>
<h2 id="Github_u7BC7"><a href="#Github_u7BC7" class="headerlink" title="Github篇"></a>Github篇</h2><h3 id="u6CE8_u518C"><a href="#u6CE8_u518C" class="headerlink" title="注册"></a>注册</h3><p>进<a href="https://github.com/" target="_blank" rel="noopener">官网</a>注册,并完成<a href="https://guides.github.com/activities/hello-world/" target="_blank" rel="noopener">教程</a>,掌握Repositories, Branches, Commits, Issues 和 Pull Requests的概念与用法</p>
<h3 id="u521B_u5EFAgithub_page"><a href="#u521B_u5EFAgithub_page" class="headerlink" title="创建github page"></a>创建github page</h3><p>参考<a href="https://pages.github.com/" target="_blank" rel="noopener">pages主页</a></p>
<hr>
<h2 id="u5DE5_u5177_u51C6_u5907_u7BC7"><a href="#u5DE5_u5177_u51C6_u5907_u7BC7" class="headerlink" title="工具准备篇"></a>工具准备篇</h2><ol>
<li><a href="https://git-scm.com/" target="_blank" rel="noopener">git</a></li>
<li><a href="https://git-scm.com/" target="_blank" rel="noopener">node.js</a></li>
<li>hexo<br>使用git <code>$ npm install -g hexo</code></li>
</ol>
<hr>
<h2 id="u57DF_u540D_u7BC7"><a href="#u57DF_u540D_u7BC7" class="headerlink" title="域名篇"></a>域名篇</h2><p>可以使用阿里云的解决方案</p>
<blockquote>
<p><a href="http://wanwang.aliyun.com/" target="_blank" rel="noopener">域名购买</a><br><a href="https://help.aliyun.com/document_detail/dns/quick-start/hichina.html?spm=5176.776555913.6.98.S0rinO" target="_blank" rel="noopener">DNS设置</a>.</p>
</blockquote>
<hr>
<h2 id="hexo_u7BC7"><a href="#hexo_u7BC7" class="headerlink" title="hexo篇"></a>hexo篇</h2><p>Create a new post</p>
<blockquote>
<p>$ hexo new “My New Post”</p>
</blockquote>
<p>Run server</p>
<blockquote>
<p>$ hexo server</p>
</blockquote>
<p>Generate static files</p>
<blockquote>
<p>$ hexo generate</p>
</blockquote>
<p>Deploy to remote sites</p>
<blockquote>
<p>$ hexo deploy</p>
</blockquote>
<p>More info: <a href="http://hexo.io/docs/" target="_blank" rel="noopener">hexo docs</a></p>
<hr>
]]></content>
<summary type="html">
<![CDATA[<h2 id="u5185_u5BB9_u63D0_u8981"><a href="#u5185_u5BB9_u63D0_u8981" class="headerlink" title="内容提要"></a>内容提要</h2><blockquote>
<ul>
<li>注册github,创建github page</li>
<li>git,node.js,hexo的安装</li>
<li>域名的购买与解析</li>
<li>hexo的基础用法]]>
</summary>
<category term="Github" scheme="http://yoursite.com/tags/Github/"/>
<category term="Hexo" scheme="http://yoursite.com/tags/Hexo/"/>
<category term="Web" scheme="http://yoursite.com/categories/Web/"/>
</entry>
<entry>
<title><![CDATA[First Essay]]></title>
<link href="http://yoursite.com/2016/02/04/First%20Essay/"/>
<id>http://yoursite.com/2016/02/04/First Essay/</id>
<published>2016-02-03T17:37:47.000Z</published>
<updated>2019-05-24T09:24:01.340Z</updated>
<content type="html"><![CDATA[<p>第一篇随笔,摘录一首《万叶集》的短歌。</p>
<hr>
<pre><code>鸣神の 少しとよみて さし昙り 雨も降らんか 君を留めん
鸣神の 少しとよみて 降らずとも 我は止まらん 妹し留めば
</code></pre><hr>
]]></content>
<summary type="html">
<![CDATA[<p>第一篇随笔,摘录一首《万叶集》的短歌。</p>
<hr>
<pre><code>鸣神の 少しとよみて さし昙り 雨も降らんか 君を留めん
鸣神の 少しとよみて 降らずとも 我は止まらん 妹し留めば
</code></pre><hr>
]]>
</summary>
<category term="短歌" scheme="http://yoursite.com/tags/%E7%9F%AD%E6%AD%8C/"/>
<category term="Essay" scheme="http://yoursite.com/categories/Essay/"/>
</entry>
</feed>