🎉 欢迎访问GreasyFork.Org 镜像站!本镜像站由公众号【爱吃馍】搭建,用于分享脚本。联系邮箱📮

Greasy fork 爱吃馍镜像

Greasy Fork is available in English.

📂 缓存分发状态(共享加速已生效)
🕒 页面同步时间:2026/02/01 04:41:53
🔄 下次更新时间:2026/02/01 05:41:53
手动刷新缓存

GitHub Latest

Always keep an eye on the latest activity of your favorite projects

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

🚀 安装遇到问题?关注公众号获取帮助

公众号二维码

扫码关注【爱吃馍】

回复【脚本】获取最新教程和防失联地址

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

🚀 安装遇到问题?关注公众号获取帮助

公众号二维码

扫码关注【爱吃馍】

回复【脚本】获取最新教程和防失联地址

// ==UserScript==
// @name        GitHub Latest
// @namespace   https://github.com/Ede123/userscripts
// @version     1.1.3
// @description Always keep an eye on the latest activity of your favorite projects
// @icon        https://raw.githubusercontent.com/Ede123/userscripts/master/icons/GitHub.png
// @author      Eduard Braun <[email protected]>
// @license     GPL-3.0-or-later; https://www.gnu.org/licenses/gpl-3.0.txt
// @include     https://github.com/*
// @grant       none
// ==/UserScript==


// redirect link to automatically sort "your stars" by "recently active"
document.body.addEventListener('mousedown', function (e) {
    var targ = e.target || e.srcElement;
    if (targ && targ.href && targ.href.match(/tab=stars$/)) {
        targ.href = targ.href.replace(/tab=stars$/, "tab=stars&sort=updated");
    }
});

// add a button to "latest issues"
function addLatestButton() {
    // do not add button again if already present
    if (document.getElementById("latest-button")) {
        return;
    }

    var reponav_list = document.querySelector("nav.js-repo-nav > ul");
    if (reponav_list) {
        var list_item_issues_copy = reponav_list.children[1].cloneNode(true);
        list_item_issues_copy.style.marginLeft = "auto";

        var button = list_item_issues_copy.firstElementChild;
        button.id = "latest-button"
        button.href += "?sort=updated";
        button.style.float = "right";

        // unselect
        button.classList.remove("selected");
        button.removeAttribute("data-selected-links");
        button.removeAttribute("aria-current");

        // adjust icon
        var icon = button.getElementsByTagName("svg")[0];
        icon.setAttribute("class", icon.getAttribute("class").replace("octicon-issue-opened", "octicon-flame"));
        icon.firstElementChild.setAttribute("d", "M5.05 0.31c0.81 2.17 0.41 3.38-0.52 4.31-0.98 1.05-2.55 1.83-3.63 3.36-1.45 2.05-1.7 6.53 3.53 7.7-2.2-1.16-2.67-4.52-0.3-6.61-0.61 2.03 0.53 3.33 1.94 2.86 1.39-0.47 2.3 0.53 2.27 1.67-0.02 0.78-0.31 1.44-1.13 1.81 3.42-0.59 4.78-3.42 4.78-5.56 0-2.84-2.53-3.22-1.25-5.61-1.52 0.13-2.03 1.13-1.89 2.75 0.09 1.08-1.02 1.8-1.86 1.33-0.67-0.41-0.66-1.19-0.06-1.78 1.25-1.23 1.75-4.09-1.88-6.22l-0.02-0.02z");

        // adjust name
        var label = button.getElementsByTagName("span")[0];
        label.textContent = "Latest issues";

        // remove counter
        var counter = button.getElementsByClassName('counter')[0] || button.getElementsByClassName('Counter')[0];
        if (counter) {
            button.removeChild(counter);
        }

        reponav_list.appendChild(list_item_issues_copy);
    }
}

addLatestButton();

// GitHub uses usage of https://github.com/defunkt/jquery-pjax#events and https://turbo.hotwired.dev/reference/events.
// https://github.com/refined-github/refined-github/issues/5719
document.addEventListener('turbo:render', addLatestButton);