-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
executable file
·252 lines (166 loc) · 9.68 KB
/
index.html
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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>GeeMing's</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<meta property="og:type" content="website">
<meta property="og:title" content="GeeMing's">
<meta property="og:url" content="http://geeming.github.io/index.html">
<meta property="og:site_name" content="GeeMing's">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="GeeMing's">
<link rel="alternate" href="/atom.xml" title="GeeMing's" type="application/atom+xml">
<link rel="icon" href="/favicon.png">
<link href="//fonts.googleapis.com/css?family=Source+Code+Pro" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="/css/style.css">
</head>
<body>
<div id="container">
<div id="wrap">
<header id="header">
<div id="banner"></div>
<div id="header-outer" class="outer">
<div id="header-title" class="inner">
<h1 id="logo-wrap">
<a href="/" id="logo">GeeMing's</a>
</h1>
</div>
<div id="header-inner" class="inner">
<nav id="main-nav">
<a id="main-nav-toggle" class="nav-icon"></a>
<a class="main-nav-link" href="/">Home</a>
<a class="main-nav-link" href="/archives">Archives</a>
<a class="main-nav-link" href="/about">About</a>
</nav>
<nav id="sub-nav">
<a id="nav-rss-link" class="nav-icon" href="/atom.xml" title="Flux RSS"></a>
<a id="nav-search-btn" class="nav-icon" title="Rechercher"></a>
</nav>
<div id="search-form-wrap">
<form action="//google.com/search" method="get" accept-charset="UTF-8" class="search-form"><input type="search" name="q" results="0" class="search-form-input" placeholder="Search"><button type="submit" class="search-form-submit"></button><input type="hidden" name="sitesearch" value="http://geeming.github.io"></form>
</div>
</div>
</div>
</header>
<div class="outer">
<section id="main">
<article id="post-test-resource-download" class="article article-type-post" itemscope itemprop="blogPost">
<div class="article-meta">
<a href="/2016/08/17/test-resource-download/" class="article-date">
<time datetime="2016-08-16T23:28:03.000Z" itemprop="datePublished">2016-08-17</time>
</a>
</div>
<div class="article-inner">
<header class="article-header">
<h1 itemprop="name">
<a class="article-title" href="/2016/08/17/test-resource-download/">Test Resource Download</a>
</h1>
</header>
<div class="article-entry" itemprop="articleBody">
<h2 id="Thought"><a href="#Thought" class="headerlink" title="Thought"></a>Thought</h2><p> Suddently I wounder, though it’s possiable to load a image resource from local static website on GitHub Pages, if is the same possiable to download other resource via GitHub Pages with Hexo, So I did some test.</p>
<h2 id="Start-Test"><a href="#Start-Test" class="headerlink" title="Start Test"></a>Start Test</h2><ul>
<li>I created a new article using <code>hexo new post_name</code>, and it seem automatically built a new folder which name same as the article (why?).</li>
<li>So I directly make a file into this folder, for most comment situation, I choose a archive file, inside it is a text file with a sentence <code>resource test</code>.</li>
<li>Then edit the markdown file, add a link <code>[resource](test-resource-download/file.zip)</code> like what image resource did, start hexo local server and check the result (<a href="test-resource-download/file.zip">resource</a>).</li>
<li>And it fail, click from home link, it shown:<br><img src="/2016/08/17/test-resource-download/home_result.png" alt="home retult"></li>
<li>Click from the article, it shown:<br><img src="/2016/08/17/test-resource-download/post_result.png" alt="post result"></li>
<li>It seem the folder name is redundancy, next try, I change into <code>[resource](file.zip)</code> <a href="file.zip">resource</a>.</li>
<li>Restart Hexo server, try again, and find that click from home it shown no doubtly:<br><img src="/2016/08/17/test-resource-download/home_result2.png" alt="home result 2"></li>
<li>And from the article site, the links is:<br><code>http://localhost:4000/2016/08/17/test-resource-download/file.zip</code><br>This is a correct link.</li>
<li>One more try, deploy on remote server, use <code>hexo g</code>, <code>hexo d</code> .</li>
<li>And as expected, it react correct in the post site, download the archive file is avaliable from the artilcle.</li>
</ul>
<h2 id="Summary"><a href="#Summary" class="headerlink" title="Summary"></a>Summary</h2><ul>
<li>Download resource can be done, just use the link as <code>[resource](file.zip)</code>, dont’t add with folder name.</li>
<li>And fail to acquire true link from the home page, I think it’s hexo’s problem (I’m not mean that’s a BUG), hexo has special processing image link, so I should write a plugin about this or using JavaScripts to correct this(but I’m not familiar with this both, I have not much interested about this now :/).</li>
</ul>
</div>
<footer class="article-footer">
<a data-url="http://geeming.github.io/2016/08/17/test-resource-download/" data-id="ciry5epk500007cp62rest735" class="article-share-link">Partager</a>
</footer>
</div>
</article>
<article id="post-start-hexo" class="article article-type-post" itemscope itemprop="blogPost">
<div class="article-meta">
<a href="/2016/08/16/start-hexo/" class="article-date">
<time datetime="2016-08-15T22:46:58.000Z" itemprop="datePublished">2016-08-16</time>
</a>
</div>
<div class="article-inner">
<header class="article-header">
<h1 itemprop="name">
<a class="article-title" href="/2016/08/16/start-hexo/">Start Hexo</a>
</h1>
</header>
<div class="article-entry" itemprop="articleBody">
<p><img src="/2016/08/16/start-hexo/GeeMing_HD.png" alt="GeeMing"></p>
<h2 id="First-time-using-HEXO"><a href="#First-time-using-HEXO" class="headerlink" title="First time using HEXO"></a>First time using HEXO</h2><h3 id="Making-image-insert-avilable-With-the-instruction-from-here"><a href="#Making-image-insert-avilable-With-the-instruction-from-here" class="headerlink" title="Making image insert avilable.(With the instruction from here)"></a>Making image insert avilable.(With the instruction from <a href="https://codefalling.com/2015/12/19/no-pains-with-hexo-local-image/" target="_blank" rel="external">here</a>)</h3><p><strong>Point:</strong></p>
<ul>
<li><p>install plugin:</p>
<figure class="highlight sh"><table><tr><td class="gutter"><pre><div class="line">1</div></pre></td><td class="code"><pre><div class="line">npm install hexo-asset-image --save</div></pre></td></tr></table></figure>
</li>
<li><p>make a new folder in <code>_posts</code>, whitch is the same path as the passage, and the name should be the same as the article’s title (ex: <code>start-hexo</code> is the name of this folder)</p>
</li>
<li>using <code>![img](foldername/image.png)</code> in the article</li>
</ul>
<h3 id="Add-Duoshuo-commet-support"><a href="#Add-Duoshuo-commet-support" class="headerlink" title="Add Duoshuo commet support"></a>Add Duoshuo commet support</h3><ul>
<li>login <a href="http://duoshuo.com/" target="_blank" rel="external">Duoshuo</a></li>
<li>create a site in <a href="http://duoshuo.com/create-site/" target="_blank" rel="external">Duoshuo</a></li>
<li>modify layout config file follow by <a href="http://dev.duoshuo.com/threads/541d3b2b40b5abcd2e4df0e9" target="_blank" rel="external">this instruction</a><ul>
<li><strong>NOTES:</strong></li>
<li>the instruction is based on the default hexo themes <code>landscape</code></li>
<li>be aware of the copy ecoding problem (I get mess in pasting code using vim, if in Windows, use <code>notepad++</code> would be better)</li>
</ul>
</li>
</ul>
</div>
<footer class="article-footer">
<a data-url="http://geeming.github.io/2016/08/16/start-hexo/" data-id="ciry5epkh00027cp6qongr4fv" class="article-share-link">Partager</a>
</footer>
</div>
</article>
</section>
<aside id="sidebar">
<div class="widget-wrap">
<h3 class="widget-title">Archives</h3>
<div class="widget">
<ul class="archive-list"><li class="archive-list-item"><a class="archive-list-link" href="/archives/2016/08/">August 2016</a></li></ul>
</div>
</div>
<div class="widget-wrap">
<h3 class="widget-title">Articles récents</h3>
<div class="widget">
<ul>
<li>
<a href="/2016/08/17/test-resource-download/">Test Resource Download</a>
</li>
<li>
<a href="/2016/08/16/start-hexo/">Start Hexo</a>
</li>
</ul>
</div>
</div>
</aside>
</div>
<footer id="footer">
<div class="outer">
<div id="footer-info" class="inner">
© 2016 GeeMing<br>
Propulsé by <a href="http://hexo.io/" target="_blank">Hexo</a>
</div>
</div>
</footer>
</div>
<nav id="mobile-nav">
<a href="/" class="mobile-nav-link">Home</a>
<a href="/archives" class="mobile-nav-link">Archives</a>
<a href="/about" class="mobile-nav-link">About</a>
</nav>
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js"></script>
<link rel="stylesheet" href="/fancybox/jquery.fancybox.css">
<script src="/fancybox/jquery.fancybox.pack.js"></script>
<script src="/js/script.js"></script>
</div>
</body>
</html>