pear-desktop

pear-devsMIT活跃维护

基于 Electron 的跨平台桌面音乐播放器,为 YouTube Music 等流媒体服务提供增强扩展,支持 Windows、macOS 和 Linux。

Pear 🍐 is extension for music player

v3.12.0发布于 2026-06-28 15:43 UTC34,006star +10 / 7 天2,039fork同步于 2026-11-10 11:20 UTC

怎么上手

由 README 提炼,执行前请确认
brew install pear-devs/pear/pear-desktop
winget install pear-devs.pear-desktop
硬件要求按 README 说明

README 未说明硬件要求

下载:源码 zip·GitHub Releases(安装包)本站不镜像安装包

项目说明

由 README 自动翻译提炼

把 YouTube Music 网页版封装成带原生外观的桌面客户端,并支持插件扩展

基于 Electron 的跨平台桌面音乐播放器,为 YouTube Music 等流媒体服务提供增强扩展,支持 Windows、macOS 和 Linux。

核心能力

  • 基于 Electron 封装音乐播放器网页为桌面应用
  • 通过插件修改 BrowserWindow 与 HTML/CSS 前端
  • 插件支持 backend、renderer、preload 三类钩子
  • 可加载 CSS 主题文件自定义界面外观
  • 提供 IPC 机制实现前后端通信

容易踩的坑

macOS 手动安装若提示已损坏,需执行 xattr -cr 清除隔离属性;Windows 安装可能被 SmartScreen 以未知发布者拦截;从源码构建需先安装 pnpm 并执行 pnpm install --frozen-lockfile

内容由模型根据 README 生成,可能不完整或不准确,以官方文档为准。看原文 README

最近发版

5 个版本v3.12.0
  1. v3.12.03.12.0最新正式版2026-06-28 · 2026-06-28 15:43 UTC

    See changelog for the list of updates and the full diff.

    Thanks to all contributors! 🏅

    (Note for Windows: ...-Desktop-Web-Setup-3.12.0.exe is an installer, and ...-Desktop-3.12.0.exe is a portable version)
    (Note for macOS: see https://github.com/pear-devs/pear-desktop#macos)

    What's Changed

  2. v3.11.02025-09-07 · 2025-09-07 09:01 UTC
    查看更新说明

    New plugin

    transparent-player

    458960038-96325f4b-09bb-49af-9adf-14a0015442b4

    • Thanks to @frostybiscuit!

    Custom Output Device

    • Thanks to @Benjas333!

    Enhancement

    Synced lyrics with preferred provider / thai romanization

    • Thanks to @ArjixWasTaken, @hax0r31337!

    API Server

    Add websocket endpoint
    • Thanks to @Johannes7k75, @cxntered!

    Discord RPC

    • add song & artist URLs to rich presence (@foxfirecodes)
    • add option to display artist/title in status (@pynappo)

    Downloader

    • Add context menu button for playlists and albums (@lolsuffocate)

    Bug fixes

    • fix(audio-compressor): real-time behavior and duplicated audio bug (@Benjas333)
    • Fixed missing videochange dataupdated event when using shuffle (@rewhex)
    • fix(exponential-volume): volume desync bug (@Benjas333)
    • Fix https://github.com/th-ch/youtube-music/issues/3621 (@Daksh777)
    • chore(docs): update copyright footer year (@RealCyGuy)

    Breaking Changes

    • Lyrics Genius is deprecated and removed. Please use Synced Lyrics instead.

    Other changes

    • See changelog for the list of updates and the full diff.

    Thanks to all contributors! 🏅

    (Note for macOS: see https://github.com/pear-devs/pear-desktop#macos)
    (Note for Ubuntu >=24.04: see #2007)
  3. v3.10.02025-07-13 · 2025-07-13 08:26 UTC
    查看更新说明

    New plugin

    auth-proxy-adapter

    • Thanks to @qiye45!

    Enhancement

    Synced lyrics with virtual scrolling, and Musixmatch

    wJvGxitjnv

    • Thanks to @ArjixWasTaken!

    API Server

    Add optional parameter for search
    • Thanks to @franz-dc!
    Add a note in swagger
    • Thanks to @johan456789!

    Bug fixes

    • fix duplicated scrollbar (@h-banii)
    • use gtk 3 switch as workaround (@franz-dc)
    • fix(precise-volume): replace constructor check for volume slider (@franz-dc)

    Breaking Changes

    • Lyrics Genius is deprecated and removed. Please use Synced Lyrics instead.

    Other changes

    Thanks to all contributors! 🏅

    (Note for macOS: see https://github.com/th-ch/youtube-music#macos)
    (Note for Ubuntu 24.04: see #2007)
    (Note for Windows: YouTube-Music-Web-Setup-3.10.0.exe is an installer, and YouTube-Music-3.10.0.exe is a portable version)
  4. v3.9.02025-04-26 · 2025-04-26 19:43 UTC
    查看更新说明

    New plugin

    Performance Improvement

    Unobtrusive player

    • Thanks to @franz-dc

    Enhancement

    Synced lyrics with romanization

    wJvGxitjnv UHcvPkcxfI

    • Thanks to @ArjixWasTaken, @kimjammer, @JellyBrick!

    tuna-obs

    • added alternativeTitle and tags to tuna (Thanks to @AARP41298)

    See changelog for the list of updates and the full diff.

    Thanks to all contributors! 🏅

    (Note for macOS: see https://github.com/th-ch/youtube-music#macos)
    (Note for Ubuntu 24.04: see #2007)
    (Note for Windows: YouTube-Music-Web-Setup-3.9.0.exe is an installer, and YouTube-Music-3.9.0.exe is a portable version)
  5. v3.8.12025-04-25 · 2025-04-25 14:30 UTC
    查看更新说明

    New plugin

    Unobtrusive player

    • Thanks to @franz-dc

    Enhancement

    Synced lyrics with romanization

    wJvGxitjnv UHcvPkcxfI

    • Thanks to @ArjixWasTaken, @kimjammer, @JellyBrick!

    Bug fix

    • Thanks to @Yumeo0, @Paciupa, @LelouchFR, @Tx-ID!

    See changelog for the list of updates and the full diff.

    Thanks to all contributors! 🏅

    (Note for Ubuntu 24.04: see #2007)
    (Note for Windows: YouTube-Music-Web-Setup-3.8.1.exe is an installer, and YouTube-Music-3.8.1.exe is a portable version)

用户点评

登录用户的真实使用记录,可按版本和硬件筛选
共 0 条

    还没有人点评。第一个说出真实体验的人最有价值。

    README 原文

    未翻译

    :pear: Pear Desktop

    GitHub release GitHub license eslint code style Build status GitHub All Releases

    Known Vulnerabilities

    • Native look & feel extension

    [!IMPORTANT] ⚠️ Disclaimer

    No Affiliation

    This project, and its contributors, are not affiliated with, authorized by, endorsed by, or in any way officially connected with Google LLC, YouTube, or any of their subsidiaries or affiliates. This is an independent, non-profit, and unofficial extension developed by a team of volunteers with the goal of providing a desktop experience.

    Trademarks

    The names "Google" and "YouTube Music", as well as related names, marks, emblems, and images, are registered trademarks of their respective owners. Any use of these trademarks is for identification and reference purposes only and does not imply any association with the trademark holder. We have no intention of infringing upon these trademarks or causing harm to the trademark holders.

    Limitation of Liability

    This application (extension) is provided "AS IS", and you use it at your own risk. In no event shall the developers or contributors be liable for any claim, damages, or other liability, including any legal consequences, arising from, out of, or in connection with the software or the use or other dealings in the software. The responsibility for any and all outcomes of using this software rests entirely with the user.

    Content

    Translation

    You can help with translation on Hosted Weblate.

    Download

    You can check out the latest release to quickly find the latest version.

    Arch Linux

    Install the pear-desktop package from the AUR. For AUR installation instructions, take a look at this wiki page.

    Solus

    sudo eopkg install pear-desktop
    

    macOS

    You can install the app using Homebrew (see the cask definition):

    brew install pear-devs/pear/pear-desktop
    

    If you install the app manually and get an error "is damaged and can’t be opened." when launching the app, run the following in the Terminal:

    /usr/bin/xattr -cr /Applications/Pear\ Desktop.app
    

    Windows

    You can use the Scoop package manager to install the pear-desktop package from the extras bucket.

    scoop bucket add extras
    scoop install extras/pear-desktop
    

    Alternately you can use Winget, Windows 11s official CLI package manager to install the pear-devs.pear-desktop package.

    Note: Microsoft Defender SmartScreen might block the installation since it is from an "unknown publisher". This is also true for the manual installation when trying to run the executable(.exe) after a manual download here on github (same file).

    winget install pear-devs.pear-desktop
    
    How to install without a network connection? (in Windows)
    • Download the *.nsis.7z file for your device architecture in release page.
      • x64 for 64-bit Windows
      • ia32 for 32-bit Windows
      • arm64 for ARM64 Windows
    • Download installer in release page. (*-Setup.exe)
    • Place them in the same directory.
    • Run the installer.

    Themes

    You can load CSS files to change the look of the application (Options > Visual Tweaks > Themes).

    Some predefined themes are available in https://github.com/kerichdev/themes-for-ytmdesktop-player.

    Dev

    git clone https://github.com/pear-devs/pear-desktop
    cd pear-desktop
    pnpm install --frozen-lockfile
    pnpm dev
    

    Instead of installing pnpm on your system, you can also use devcontainers. You can use devcontainers either as a development environment in VS Code, or as a way to easily build the project without installing dependencies on your host system.

    Note that this has it's own limitations (for example, GUI doesn't work on, at least some, Linux hosts).

    Build your own plugins

    Using plugins, you can:

    • manipulate the app - the BrowserWindow from electron is passed to the plugin handler
    • change the front by manipulating the HTML/CSS

    Creating a plugin

    Create a folder in src/plugins/YOUR-PLUGIN-NAME:

    • index.ts: the main file of the plugin
    import style from './style.css?inline'; // import style as inline
    
    import { createPlugin } from '@/utils';
    
    export default createPlugin({
      name: 'Plugin Label',
      restartNeeded: true, // if value is true, ytmusic show restart dialog
      config: {
        enabled: false,
      }, // your custom config
      stylesheets: [style], // your custom style,
      menu: async ({ getConfig, setConfig }) => {
        // All *Config methods are wrapped Promise<T>
        const config = await getConfig();
        return [
          {
            label: 'menu',
            submenu: [1, 2, 3].map((value) => ({
              label: `value ${value}`,
              type: 'radio',
              checked: config.value === value,
              click() {
                setConfig({ value });
              },
            })),
          },
        ];
      },
      backend: {
        start({ window, ipc }) {
          window.maximize();
    
          // you can communicate with renderer plugin
          ipc.handle('some-event', () => {
            return 'hello';
          });
        },
        // it fired when config changed
        onConfigChange(newConfig) { /* ... */ },
        // it fired when plugin disabled
        stop(context) { /* ... */ },
      },
      renderer: {
        async start(context) {
          console.log(await context.ipc.invoke('some-event'));
        },
        // Only renderer available hook
        onPlayerApiReady(api, context) {
          // set plugin config easily
          context.setConfig({ myConfig: api.getVolume() });
        },
        onConfigChange(newConfig) { /* ... */ },
        stop(_context) { /* ... */ },
      },
      preload: {
        async start({ getConfig }) {
          const config = await getConfig();
        },
        onConfigChange(newConfig) {},
        stop(_context) {},
      },
    });
    

    Common use cases

    • injecting custom CSS: create a style.css file in the same folder then:
    // index.ts
    import style from './style.css?inline'; // import style as inline
    
    import { createPlugin } from '@/utils';
    
    export default createPlugin({
      name: 'Plugin Label',
      restartNeeded: true, // if value is true, pear-desktop will show a restart dialog
      config: {
        enabled: false,
      }, // your custom config
      stylesheets: [style], // your custom style
      renderer() {} // define renderer hook
    });
    
    • If you want to change the HTML:
    import { createPlugin } from '@/utils';
    
    export default createPlugin({
      name: 'Plugin Label',
      restartNeeded: true, // if value is true, ytmusic will show the restart dialog
      config: {
        enabled: false,
      }, // your custom config
      renderer() {
        console.log('hello from renderer');
      } // define renderer hook
    });
    
    • communicating between the front and back: can be done using the ipcMain module from electron. See index.ts file and example in sponsorblock plugin.

    Build

    1. Clone the repo
    2. Follow this guide to install pnpm
    3. Run pnpm install --frozen-lockfile to install dependencies
    4. Run pnpm build:OS
    • pnpm dist:win - Windows
    • pnpm dist:linux - Linux (amd64)
    • pnpm dist:linux:deb-arm64 - Linux (arm64 for Debian)
    • pnpm dist:linux:rpm-arm64 - Linux (arm64 for Fedora)
    • pnpm dist:mac - macOS (amd64)
    • pnpm dist:mac:arm64 - macOS (arm64)

    Builds the app for macOS, Linux, and Windows, using electron-builder.

    Building in devcontainer

    1. Clone the repo;
    2. Open the folder in VS Code;
    3. Reopen in container when prompted;
    4. Run pnpm build as above (choosing the desired target);
    5. Collect the built files from the dist folder.

    Since devcontainer uses a mount for the workspace, the built files will be available on the host system as well.

    Production Preview

    pnpm start
    

    Tests

    pnpm test
    

    Uses Playwright to test the app.

    License

    MIT © pear-devs

    FAQ

    Why apps menu isn't showing up?

    If Hide Menu option is on - you can show the menu with the alt key (or ` [backtick] if using the in-app-menu plugin)