Permalink
Browse files

パッチ適用方法の修正。ライダー側に寄せました。

  • Loading branch information...
ShikemokuMK committed Jan 30, 2018
1 parent a17630b commit 2d8f9b9ec60029f0d97c6ce70f2f126b7a6adb99
Showing with 9 additions and 6 deletions.
  1. +1 −1 LICENCE.txt
  2. +8 −5 tyrano/plugins/kag/kag.js
View
@@ -1,6 +1,6 @@
TyranoScript |ティラノスクリプト
Copyright (c) 2017 STRIKEWORKS @Shikemokumk
Copyright (c) 2018 STRIKEWORKS @Shikemokumk
http://strikeworks.jp
■利用規約■
View
@@ -339,10 +339,11 @@ tyrano.plugin.kag ={
}
//Webアップデートの確認も
patch_path = patch_path + "/" + this.kag.config.projectID + ".tg.patch";
patch_path = patch_path + "/" + this.kag.config.projectID + ".tpatch";
//アップデートファイルの存在チェック
var fs = require('fs');
var fse = require('fs-extra');
if (!fs.existsSync(patch_path)) {
call_back();
return;
@@ -354,20 +355,22 @@ tyrano.plugin.kag ={
return;
}
var path = require('path');
var AdmZip = require('adm-zip');
var path = require('path');
var abspath = path.resolve("./");
// reading archives
var zip = new AdmZip(patch_path);
zip.extractAllTo("./", true);
zip.extractAllTo("./update_tmp", true);
fse.copySync("./update_tmp/","./");
fse.removeSync("./update_tmp");
fs.writeFileSync("./updated","true");
location.reload();
},
//スクリプトを解釈して実行する

0 comments on commit 2d8f9b9

Please sign in to comment.