Skip to content

Add Linux support#1

Open
ameenalasady wants to merge 2 commits into
NUber-dev:mainfrom
ameenalasady:linux-port
Open

Add Linux support#1
ameenalasady wants to merge 2 commits into
NUber-dev:mainfrom
ameenalasady:linux-port

Conversation

@ameenalasady

@ameenalasady ameenalasady commented Jul 5, 2026

Copy link
Copy Markdown

Adds Linux as a supported platform. The Rust backend already compiled on Linux (all Windows-specific code is behind cfg), so this is mostly packaging plus two WebKitGTK/Wayland fixes. No Windows changes.

Changes

  • Linux bundles — new tauri.linux.conf.json adds deb, rpm and appimage targets, with the WebKitGTK/GTK/GStreamer runtime dependencies declared for deb/rpm.
  • Window resizing — frameless windows have no resize border on WebKitGTK/WKWebView (only WebView2 does), so the window was stuck at its size. Added a WindowResizeHandles overlay that grabs the edges/corners and calls startResizeDragging, plus the matching capability. Gated off on Windows, where the native border already works.
  • Release CI — added an ubuntu-22.04 job to the matrix so Linux artifacts ship on tagged releases.
  • Docs — README now covers Linux install and runtime dependencies.

Testing

Built and run on CachyOS (KDE/Wayland, webkit2gtk 4.1): pnpm build, cargo check and cargo test all pass, playback works end to end (needs gst-plugins-good for autoaudiosink and matroskademux), and the window resizes from every edge and corner.

Known limitation

On Linux, sign-in cookies are stored unencrypted — secure_store falls back to plaintext off Windows (which uses DPAPI). Anonymous browsing and playback are unaffected; wiring this into libsecret is a sensible follow-up.

The Rust backend already compiled on Linux — all Windows-specific code
(DPAPI, CREATE_NO_WINDOW, the yt-dlp binary name/URL) was already guarded
behind cfg — so this is mostly packaging plus two WebKitGTK/Wayland
runtime fixes. No Windows behaviour changes.

- Bundle: add src-tauri/tauri.linux.conf.json with deb/rpm/appimage
  targets. deb/rpm declare their WebKitGTK, GTK and GStreamer runtime
  dependencies so audio decoding works out of the box.
- Window resizing: a frameless window (decorations: false) has no resize
  affordance on WebKitGTK/WKWebView — only WebView2 provides an invisible
  native border. Add a WindowResizeHandles overlay that grabs the window
  edges/corners and calls startResizeDragging, mounted in the main shell
  and the floating player, gated off on Windows. Add the matching
  core:window:allow-start-resize-dragging capability.
- Release CI: build on ubuntu-22.04 alongside windows-latest so Linux
  artifacts are published on tagged releases.
- Docs: update README for Windows/Linux and list the Linux runtime deps,
  notably the GStreamer plugins WebKitGTK needs for playback.
@yochananmarqos

Copy link
Copy Markdown

Seems to work well so far. I've added it to the AUR with this PR applied: ytubic.

@ameenalasady ameenalasady deleted the linux-port branch July 7, 2026 02:58
@ameenalasady ameenalasady restored the linux-port branch July 7, 2026 03:32
@ameenalasady ameenalasady reopened this Jul 7, 2026
@ameenalasady

Copy link
Copy Markdown
Author

Sorry, I accidentally closed this — reopening. The linux-port branch is restored at the same commit (56632b4), so no changes to the diff.

@yochananmarqos

Copy link
Copy Markdown

@ameenalasady This needs to be rebased, it no longer applies as of v0.2.0.

@ameenalasady

Copy link
Copy Markdown
Author

@yochananmarqos Thanks! Rather than rebase this one, check out my fork for an up-to-date Linux port: https://github.com/ameenalasady/YTubic. It includes all upstream commits plus a lot of performance optimizations, fixes, and new features.

@yochananmarqos

Copy link
Copy Markdown

@ameenalasady I've switched to your fork in the AUR package for now, then. Are you planning on submitting a revised PR?

# Conflicts:
#	src/components/layout/app-shell.tsx
@NUber-dev

Copy link
Copy Markdown
Owner

@ameenalasady Hey! I’m still learning how GitHub and pull requests work, but I’ve adapted your implementation to the current upstream codebase and prepared Linux support for the main branch. I’ve also credited you as a co-author of the integration commit. Is that okay with you?

My goal is to keep all supported OS versions in the same repository and codebase, so they have the same functionality and new versions can be released together.

@ameenalasady

Copy link
Copy Markdown
Author

@NUber-dev Sure thing, that works for me. Thanks for the credit! Glad to see Linux support making it into the main codebase, and nice work getting it all unified. Feel free to close this PR when done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants