xmoj-script 1.1.45 → 1.1.46

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.
@@ -16,7 +16,7 @@ jobs:
16
16
  fetch-depth: 0
17
17
  - name: Generate new sitemap
18
18
  id: sitemap
19
- uses: cicirello/generate-sitemap@v1.6.1
19
+ uses: cicirello/generate-sitemap@v1.10.0
20
20
  with:
21
21
  additional-extensions: user.js
22
22
  sitemap-format: xml
@@ -24,10 +24,24 @@ console.log("Last JSON version : " + LastJSONVersion);
24
24
  console.log("Last PR : " + LastPR);
25
25
  console.log("Last type : " + LastType);
26
26
  console.log("npm version : " + NpmVersion);
27
-
28
- if (JSONFileContent.includes('//ci-no-touch')) {
29
- var updatedContent = JSONFileContent.replace('//ci-no-touch', '');
27
+ execSync("git config --global user.email \"github-actions[bot]@users.noreply.github.com\"");
28
+ execSync("git config --global user.name \"github-actions[bot]\"");
29
+ if (JSONFileContent.includes('//!ci-no-touch')) {
30
+ var updatedContent = JSONFileContent.replace('//!ci-no-touch', '');
30
31
  writeFileSync(JSONFileName, updatedContent, "utf8");
32
+ execSync("git config pull.rebase false");
33
+ execSync("git pull");
34
+ execSync("git push origin --delete actions/temp || true");
35
+ execSync("git checkout -b actions/temp");
36
+ execSync("git commit -a -m \"remove //!ci-no-touch\"");
37
+ execSync("git push -u origin actions/temp -f");
38
+ console.warn("Pushed to actions/temp.");
39
+
40
+ var PRNumber = execSync("gh pr create --title \"Update to release " + CurrentVersion + "\" --body \"Update to release " + CurrentVersion + "\" --base dev --head actions/temp").toString().split("/")[6].trim();
41
+ console.warn("PR #" + PRNumber + " has been created.");
42
+
43
+ execSync("gh pr merge " + PRNumber + " --merge --auto");
44
+ console.warn("PR #" + PRNumber + " has enabled auto merge.");
31
45
  console.log('I won\'t touch this. Exiting process.');
32
46
  process.exit(0);
33
47
  }
@@ -41,8 +55,6 @@ if (LastType == "Release") {
41
55
  execSync("gh pr close " + PRNumber);
42
56
  process.exit(1);
43
57
  }
44
- execSync("git config --global user.email \"github-actions[bot]@users.noreply.github.com\"");
45
- execSync("git config --global user.name \"github-actions[bot]\"");
46
58
 
47
59
  if (LastJSVersion != NpmVersion) {
48
60
  console.warn("Assuming you manually ran npm version.");
@@ -26,10 +26,16 @@ console.log("Last PR : " + LastPR);
26
26
  console.log("Last description : " + LastDescription);
27
27
  console.log("Last release online: " + LastReleaseVersionOnline);
28
28
  console.log("npm version : " + NpmVersion);
29
-
30
- if (JSONFileContent.includes('//ci-no-touch')) {
31
- var updatedContent = JSONFileContent.replace('//ci-no-touch', '');
29
+ execSync("git config --global user.email \"github-actions[bot]@users.noreply.github.com\"");
30
+ execSync("git config --global user.name \"github-actions[bot]\"");
31
+ if (JSONFileContent.includes('//!ci-no-touch')) {
32
+ var updatedContent = JSONFileContent.replace('//!ci-no-touch', '');
32
33
  writeFileSync(JSONFileName, updatedContent, "utf8");
34
+ execSync("git config pull.rebase false");
35
+ execSync("git pull");
36
+ execSync("git commit -a -m \"" + "remove //!ci-no-touch" + "\"");
37
+ execSync("git push -f");
38
+ console.log("Pushed to GitHub.");
33
39
  console.log('I won\'t touch this. Exiting process.');
34
40
  process.exit(0);
35
41
  }
package/Update.json CHANGED
@@ -1309,6 +1309,29 @@
1309
1309
  }
1310
1310
  ],
1311
1311
  "Notes": "No release notes were provided for this release."
1312
+ },
1313
+ "1.1.46": {
1314
+ "UpdateDate": 1708137046736,
1315
+ "Prerelease": false,
1316
+ "UpdateContents": [
1317
+ {
1318
+ "PR": 445,
1319
+ "Description": "fix [Bug] 右上角用户名点击后无反应 "
1320
+ },
1321
+ {
1322
+ "PR": 447,
1323
+ "Description": "fix the unpkg-cdn option"
1324
+ },
1325
+ {
1326
+ "PR": 449,
1327
+ "Description": "regression!"
1328
+ },
1329
+ {
1330
+ "PR": 454,
1331
+ "Description": "fix #400 + //ci-no-touch"
1332
+ }
1333
+ ],
1334
+ "Notes": "No release notes were provided for this release."
1312
1335
  }
1313
1336
  }
1314
1337
  }
package/XMOJ.user.js CHANGED
@@ -1,6 +1,6 @@
1
1
  // ==UserScript==
2
2
  // @name XMOJ
3
- // @version 1.1.45
3
+ // @version 1.1.46
4
4
  // @description XMOJ增强脚本
5
5
  // @author @XMOJ-Script-dev, @langningchen and the community
6
6
  // @namespace https://github/langningchen
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xmoj-script",
3
- "version": "1.1.45",
3
+ "version": "1.1.46",
4
4
  "description": "an improvement script for xmoj.tech",
5
5
  "main": "AddonScript.js",
6
6
  "scripts": {