From 471abeb63c6643c432e6264b07dddf5180c72e45 Mon Sep 17 00:00:00 2001 From: zpj80231 Date: Tue, 9 Dec 2025 14:34:48 +0800 Subject: [PATCH] Remove MyJBLS --- README.md | 12 +-- activate-code-plugin/_MyJBLS.js | 142 -------------------------------- 2 files changed, 6 insertions(+), 148 deletions(-) delete mode 100644 activate-code-plugin/_MyJBLS.js diff --git a/README.md b/README.md index f6d2682..2a5f284 100644 --- a/README.md +++ b/README.md @@ -75,13 +75,13 @@ ### 2.4 非正式激活-支持功能列表 - JetBrains 全家桶激活 -- 付费插件脚本: - - 认证方式(使用佬友提供的 LINUX.DO 认证提高使用门槛,认证需自行解决):配合猴油脚本,手动添加 `_MyJBLS.js` 脚本到猴油中,打开 [https://plugins.jetbrains.com](https://plugins.jetbrains.com/) 搜索你想要激活的插件,点击 `Generate Code` 按钮就能得到该插件的激活码,粘入到插件的 `Activation Code` 中即可 - - ~~离线方式(影响太大,已下架自用)~~ - 付费插件激活码: - - 本仓库现只随缘更新 `Rainbow Brackets` 和 `MyBatisCodeHelperPro (Marketplace Edition)` 这两个插件 2 年的激活码 - - 如果您是插件作者(望手下留情),或已知对以上 2 个插件造成恶意影响请联系我删除 - - 不要再问,仓库内不会再添加其他任何付费插件的激活码 + - 本仓库现只随缘更新 `Rainbow Brackets` 和 `MyBatisCodeHelperPro (Marketplace Edition)` 这两个插件 2 年的激活码 + - 如果您是插件作者(望手下留情),或已知对以上 2 个插件造成恶意影响请联系我删除 + - 不要再问,仓库内不会再添加其他任何付费插件的激活码 +- ~~付费插件脚本(已下架自用):~~ + - ~~认证方式(使用佬友提供的 LINUX.DO 认证提高使用门槛,认证需自行解决):配合猴油脚本,手动添加 `_MyJBLS.js` 脚本到猴油中,打开 [https://plugins.jetbrains.com](https://plugins.jetbrains.com/) 搜索你想要激活的插件,点击 `Generate Code` 按钮就能得到该插件的激活码,粘入到插件的 `Activation Code` 中即可~~ + - ~~离线方式(影响太大,已下架自用)~~ - ~~GitHub Copilot 激活:cocopilot 公车已废弃~~ - ~~Augment 激活:下载 Augment 插件,点击 Sign In 按钮【本地授权】,即可无限免费使用 Claude Sonnet 4 系列模型(代码开发和编程最强模型)~~ diff --git a/activate-code-plugin/_MyJBLS.js b/activate-code-plugin/_MyJBLS.js deleted file mode 100644 index 5b129d1..0000000 --- a/activate-code-plugin/_MyJBLS.js +++ /dev/null @@ -1,142 +0,0 @@ -// ==UserScript== -// @name MyJBLS -// @namespace https://jbls.ide-soft.com -// @version 2024-04-17 -// @description tampermonkey magic script for jetbrains, generate activation code for jetbrains plugin,use tampermonkey https://chromewebstore.google.com/detail/%E7%AF%A1%E6%94%B9%E7%8C%B4/dhdgffkkebhmkfjojejmpbldmpobfkfo to install this script -// @author anonymous -// @match https://plugins.jetbrains.com/ -// @match https://plugins.jetbrains.com/* -// @grant GM_setClipboard -// @grant GM_addStyle -// @grant GM_xmlhttpRequest -// @grant window.onurlchange -// @run-at document-end -// @license MIT -// ==/UserScript== -(function () { - const maxAttempts = 50; - const retryInterval = 100; - const backendBaseUrl = "https://jbls.ide-soft.com"; - const codes = ["YTD", "QDGO", "MF", "DG", "PS", "QA", "IIE", "YTWE", "FLS", "DLE", "RFU", "PPS", "PCWMP", "II", "TCC", "RSU", "PCC", "RC", "PCE", "FLIJ", "TBA", "DL", "SPP", "QDCLD", "SPA", "DMCLP", "PSW", "GW", "PSI", "IIU", "DMU", "PWS", "HB", "WS", "PCP", "KT", "DCCLT", "RSCLT", "WRS", "RSC", "RRD", "TC", "IIC", "QDPY", "DPK", "DC", "PDB", "DPPS", "QDPHP", "GO", "HCC", "RDCPPP", "QDJVMC", "CL", "DM", "CWML", "FLL", "RR", "QDJS", "RS", "RM", "DS", "MPS", "DPN", "US", "CLN", "DPCLT", "RSV", "MPSIIP", "DB", "QDANDC", "AC", "QDJVM", "PRB", "RD", "CWMR", "SP", "RS0", "DP", "RSF", "PGO", "QDPYC", "PPC", "PC", "EHS", "RSCHB", "FL", "QDNET", "JCD"]; - - async function findElementWithRetry(cssSelector, timeout = 5000) { - const maxAttempts = timeout / retryInterval; - for (let attempts = 0; attempts < maxAttempts; attempts++) { - const element = document.querySelector(cssSelector); - if (element) { - return element; - } - await new Promise((resolve) => setTimeout(resolve, retryInterval)); - } - throw new Error( - `Element with selector '${cssSelector}' not found after ${maxAttempts} attempts.` - ); - } - - async function addButton() { - ("use strict"); - GM_addStyle(` - .jetbra-button { - margin: 10px 0 0 10px; - } - `); - - const url = window.location.href; - if (!url.startsWith("https://plugins.jetbrains.com/plugin/")) { - return; - } - - const pluginId = url.split("/")[4].split("-")[0]; - - const pluginDetail = await fetch( - `https://plugins.jetbrains.com/api/plugins/${pluginId}` - ).then((r) => r.json()); - const parentElement = await findElementWithRetry( - ".plugin-header__controls-panel > div:first-child" - ); - - if ( - parentElement.querySelector(".refill-button") || - !pluginDetail.purchaseInfo - ) { - return; - } - const originalButton = await findElementWithRetry( - '.plugin-header__controls-panel button[data-test="button"]' - ); - const buttonClasses = originalButton.className; - if(document.getElementsByClassName("jetbra-button").length>0){ - return; - } - const newButton = document.createElement("button"); - newButton.setAttribute("type", "button"); - newButton.className = `${buttonClasses} jetbra-button`; - newButton.textContent = "Generate Code"; - - originalButton.parentNode.insertBefore( - newButton, - originalButton.nextSibling - ); - newButton.addEventListener("click", async () => { - let ls = window.localStorage; - let licenseeName = ls.getItem("licenseeName"); - if (!licenseeName) { - licenseeName = - window.prompt("Please enter the licensee name:") || "SuperMan"; - ls.setItem("licenseeName", licenseeName); - } - - if (!pluginDetail.purchaseInfo) { - window.alert("This plugin is not a paid plugin in the market"); - return; - } - - codes.push(pluginDetail.purchaseInfo.productCode); - const currentDate = new Date(); - currentDate.setFullYear(currentDate.getFullYear() + 1); - const paidUpTo = currentDate.toISOString().slice(0, 10); - - const data = { - licenseeName, - codes, - paidUpTo - }; - try { - GM_xmlhttpRequest({ - method: "POST", - url: backendBaseUrl + "/api/generateLicense", - headers: { - "Content-Type": "application/json", - }, - data: JSON.stringify(data), - onload: function (response) { - const data = JSON.parse(response.responseText); - if (data.error || !data.license) { - console.log(response.responseText); - window.alert(`${data.error} will jump to the oauth page,then go back try again.`); - setTimeout(() => { - window.open(backendBaseUrl + "/oauth2/authorize", "_blank"); - }, 1000); - return; - } - let license = data.license; - GM_setClipboard(license, "text"); - window.alert("The activation code has been copied to your clipboard"); - }, - }); - } catch (error) { - console.error("Error generating license:", error); - window.alert("An error occurred while generating the license."); - } - }); - } - window.onload = function() { - addButton(); - }; - - if (!window.onurlchange) { - window.addEventListener("urlchange", () => { - addButton(); - }); - } -})(); \ No newline at end of file