mali-applet-ui 1.1.39 → 1.1.40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/env/index.d.ts +3 -2
- package/env/index.js +13 -3
- package/package.json +1 -1
package/env/index.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ export function parseEnv(dirPath: string): Record<string, string>
|
|
|
7
7
|
export function initEnv(dirPath: string, defaultEnv: Record<string, string>): Record<string, string>
|
|
8
8
|
export function initManifestEnv(dirPath: string, manifestJson: any): Record<string, string>
|
|
9
9
|
export function uploadWxMiniprogram(version: string): void
|
|
10
|
-
export function getSCSSAdditionalData(
|
|
10
|
+
export function getSCSSAdditionalData(): string
|
|
11
11
|
export function sendMail(options: {
|
|
12
12
|
receivedBy: string | string[]
|
|
13
13
|
subject: string
|
|
@@ -17,4 +17,5 @@ export function sendQyWechatMsg(webhook: string, params: {
|
|
|
17
17
|
content: string
|
|
18
18
|
mentionedList?: string[]
|
|
19
19
|
mentionedMobileList?: string[]
|
|
20
|
-
})
|
|
20
|
+
})
|
|
21
|
+
export function getBuildSuccessMsg(): string
|
package/env/index.js
CHANGED
|
@@ -213,6 +213,7 @@ function uploadWxMiniprogram (rootPath, version) {
|
|
|
213
213
|
}
|
|
214
214
|
deleteFolder(path.resolve(rootPath, 'temp'))
|
|
215
215
|
fs.unlinkSync(path.resolve(rootPath, 'sm.zip'))
|
|
216
|
+
|
|
216
217
|
resolve()
|
|
217
218
|
})
|
|
218
219
|
}).catch(e => {
|
|
@@ -264,8 +265,8 @@ function sendQyWechatMsg (webhook, params) {
|
|
|
264
265
|
throw new Error('企微机器人 webhook 地址不能为空')
|
|
265
266
|
}
|
|
266
267
|
return axios.post(webhook, {
|
|
267
|
-
msgtype: 'markdown',
|
|
268
|
-
markdown: {
|
|
268
|
+
msgtype: params.msgtype || 'markdown',
|
|
269
|
+
[params.msgtype || 'markdown']: {
|
|
269
270
|
content: params.content || '',
|
|
270
271
|
mentioned_list: params.mentionedList || [],
|
|
271
272
|
mentioned_mobile_list: params.mentionedMobileList || []
|
|
@@ -275,6 +276,13 @@ function sendQyWechatMsg (webhook, params) {
|
|
|
275
276
|
})
|
|
276
277
|
}
|
|
277
278
|
|
|
279
|
+
function getBuildSuccessMsg () {
|
|
280
|
+
return `
|
|
281
|
+
# <font color="info">${[getCustomName(process.env.VUE_APP_CUSTOM_MODULE), pack.description, '-', getEnvName(process.env.VUE_APP_MODE), '已更新'].join('')}</font>
|
|
282
|
+
>> 构建时间:<font color="comment">${XEUtils.toDateString(XEUtils.toStringDate(process.env.VUE_APP_PUBLISH_DATE, 'yyyyMMddHHmmss'), 'yyyy-MM-dd HH:mm:ss')}</font>
|
|
283
|
+
<font color="comment">-自动化发版</font>`
|
|
284
|
+
}
|
|
285
|
+
|
|
278
286
|
exports.getEnvCode = getEnvCode
|
|
279
287
|
exports.getEnvName = getEnvName
|
|
280
288
|
exports.getCustomName = getCustomName
|
|
@@ -287,6 +295,7 @@ exports.uploadWxMiniprogram = uploadWxMiniprogram
|
|
|
287
295
|
exports.getSCSSAdditionalData = getSCSSAdditionalData
|
|
288
296
|
exports.sendMail = sendMail
|
|
289
297
|
exports.sendQyWechatMsg = sendQyWechatMsg
|
|
298
|
+
exports.getBuildSuccessMsg = getBuildSuccessMsg
|
|
290
299
|
|
|
291
300
|
module.exports = {
|
|
292
301
|
getEnvCode,
|
|
@@ -300,5 +309,6 @@ module.exports = {
|
|
|
300
309
|
uploadWxMiniprogram,
|
|
301
310
|
getSCSSAdditionalData,
|
|
302
311
|
sendMail,
|
|
303
|
-
sendQyWechatMsg
|
|
312
|
+
sendQyWechatMsg,
|
|
313
|
+
getBuildSuccessMsg
|
|
304
314
|
}
|