File tree Expand file tree Collapse file tree 4 files changed +28
-31
lines changed Expand file tree Collapse file tree 4 files changed +28
-31
lines changed Original file line number Diff line number Diff line change
1
+ #! /bin/sh
2
+ mkdir temp_web
3
+ npm run deploy:build
4
+ cd temp_web
5
+ git clone -b gh-pages https://github.com/ElemeFE/element.git && cd element
6
+
7
+ # build sub folder
8
+ SUB_FOLDER=' 1.4'
9
+ mkdir $SUB_FOLDER
10
+
11
+ rm -rf * .js * .css * .map static
12
+ rm -rf $SUB_FOLDER /**
13
+ cp -rf ../../examples/element-ui/** .
14
+ cp -rf ../../examples/element-ui/** $SUB_FOLDER /
15
+ cd ../..
16
+
17
+ # deploy domestic site
18
+ faas deploy alpha
Original file line number Diff line number Diff line change 199
199
this .localize ();
200
200
this .renderAnchorHref ();
201
201
this .goAnchor ();
202
- setTimeout (() => {
203
- const notified = localStorage .getItem (' BETA_NOTIFIED' );
204
- if (! notified) {
205
- const h = this .$createElement ;
206
- const title = this .lang === ' zh-CN'
207
- ? ' 2.0.0 Beta 发布'
208
- : ' 2.0.0 Beta released' ;
209
- const messages = this .lang === ' zh-CN'
210
- ? [' 点击' , ' 这里' , ' 查看详情' ]
211
- : [' Click ' , ' here' , ' to learn more' ];
212
- this .$notify .success ({
213
- title,
214
- duration: 0 ,
215
- message: h (' span' , [
216
- messages[0 ],
217
- h (' a' , {
218
- attrs: {
219
- target: ' _blank' ,
220
- href: ` https://github.com/ElemeFE/element/issues/${ this .lang === ' zh-CN' ? ' 7612' : ' 7613' } `
221
- }
222
- }, messages[1 ]),
223
- messages[2 ]
224
- ]),
225
- onClose () {
226
- localStorage .setItem (' BETA_NOTIFIED' , 1 );
227
- }
228
- });
229
- }
230
- }, 3500 );
231
202
},
232
203
233
204
created () {
Original file line number Diff line number Diff line change 259
259
const xhr = new XMLHttpRequest ();
260
260
xhr .onreadystatechange = _ => {
261
261
if (xhr .readyState === 4 && xhr .status === 200 ) {
262
- this .versions = JSON .parse (xhr .responseText );
262
+ const versions = JSON .parse (xhr .responseText );
263
+ this .versions = Object .keys (versions).slice (- 2 ).reduce ((prev , next ) => {
264
+ prev[next] = versions[next];
265
+ return prev;
266
+ }, {});
263
267
}
264
268
};
265
269
xhr .open (' GET' , ' /versions.json' );
Original file line number Diff line number Diff line change 23
23
"dist:all" : " node build/bin/build-all.js && npm run build:theme" ,
24
24
"i18n" : " node build/bin/i18n.js" ,
25
25
"lint" : " eslint src/**/* test/**/* packages/**/*.{js,vue} build/**/* --quiet" ,
26
- "pub" : " npm run bootstrap && sh build/git-release.sh && sh build/release.sh" ,
26
+ "pub" : " npm run bootstrap && sh build/git-release.sh && sh build/release.sh && sh build/deploy-faas.sh " ,
27
27
"pub:all" : " npm run dist:all && lerna publish --skip-git && git commit -am 'publish independent packages' && git push eleme dev" ,
28
28
"test" : " npm run lint && cross-env CI_ENV=/dev/ karma start test/unit/karma.conf.js --single-run" ,
29
29
"test:watch" : " karma start test/unit/karma.conf.js"
30
30
},
31
+ "faas" : {
32
+ "domain" : " element" ,
33
+ "public" : " temp_web/element"
34
+ },
31
35
"repository" : {
32
36
"type" : " git" ,
33
37
"url" :
" [email protected] :ElemeFE/element.git"
You can’t perform that action at this time.
0 commit comments