| 14 | } catch (e) {} |
| 15 | class env { |
| 16 | constructor(name) { |
| 17 | this.config = { ...config, |
| 18 | ...process.env, |
| 19 | ...user, |
| 20 | }; |
| 21 | this.name = name; |
| 22 | this.message = []; |
| 23 | this.sharecode = []; |
| 24 | this.code = []; |
| 25 | this.timestamp = new Date().getTime(); |
| 26 | this.time = this.start = parseInt(this.timestamp / 1000); |
| 27 | this.options = { |
| 28 | 'headers': {} |
| 29 | }; |
| 30 | console.log(`\n🔔${this.name}, 开始!\n`) |
| 31 | console.log(`=========== 脚本执行-北京时间(UTC+8):${new Date(new Date().getTime() + new Date().getTimezoneOffset()*60*1000 + 8*60*60*1000).toLocaleString()} ===========\n`) |
| 32 | } |
| 33 | done() { |
| 34 | let timestamp = new Date().getTime(); |
| 35 | let work = ((timestamp - this.timestamp) / 1000).toFixed(2) |