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
| const {editKeyWord, copyDir} = require("./_common"); const path = require("path");
const {oldname} = require("./_oldname"); let newname = "星火直播测试";
const filePath = path.resolve(__dirname, '../src/'); editKeyWord(filePath, oldname, newname);
let html_arr = [ "_package/_oldname.js", "main.js", "package.json", "v_blackboard.html", "v_class_center.html", "v_classtip.html", "v_device_test.html", "v_dianming.html", "v_exit_dialog.html", "v_home.html", "v_huamingce.html", "v_huamingce_mini.html", "v_jiangping.html", "v_login.html", "v_player_win.html", "v_qiangda.html", "v_space.html", "v_stu_head.html", "v_teacher_head.html", "v_test.html", "v_tip.html", "v_tiwen.html", "v_tongji.html", "v_tweb.html" ];
for (const str of html_arr) { const temppath = path.resolve(__dirname + '/../' + str); editKeyWord(temppath, oldname, newname); }
const themepath = path.resolve(__dirname, '../src/config/Config.js'); editKeyWord(themepath, 'themename = "theme_red"', 'themename = "theme_blue"');
const path_origin = path.resolve(__dirname, './xh/image'); const path_target = path.resolve(__dirname, '../image'); copyDir(path_origin, path_target, function (err) { if (err) { console.log(err); } })
const ico_origin = path.resolve(__dirname, './xh/ico/'); const ico_target = path.resolve(__dirname, '../'); copyDir(ico_origin, ico_target, function (err) { if (err) { console.log(err); } })
|