Skip to content

Instantly share code, notes, and snippets.

View leon2017's full-sized avatar
🎯
Focusing

leon leon2017

🎯
Focusing
  • なになに?
  • Hefei
View GitHub Profile
@onlymash
onlymash / deb-packaging.md
Last active December 3, 2025 07:41
Advanced `.deb` Packaging for Compose Multiplatform Desktop Apps

Advanced .deb Packaging for Compose Multiplatform Desktop Apps

Compose Multiplatform is a fantastic framework for building desktop applications, but its default Linux packaging capabilities, which rely on jpackage, have some known limitations. A common pain point for developers is the lack of fine-grained control over the generated .deb package, especially concerning the .desktop entry file.

This often leads to issues like:

  • The application icon showing correctly in the app menu, but displaying as a generic icon in the dock or taskbar when running.
  • The inability to place icons and other resources in standard system-wide directories like /usr/share/icons.

This tutorial provides a robust, script-based solution to overcome these limitations. We will create a "post-processing" script that takes the basic .deb package generated by Gradle and enhances it into a professional, standards-compliant package. This solution was perfected during an intensive, all-night debugging session, and it's b

@LeslieLeung
LeslieLeung / claude.zsh
Last active February 28, 2026 06:04
A sleek script to switch between Claude Code providers.
function claude() {
# 默认渠道配置
local default_provider=""
# 定义不同服务的配置
local base_url=""
local auth_token=""
local api_key=""
local model=""
local small_fast_model=""
@JakeWharton
JakeWharton / OkHttpStack.java
Created May 21, 2013 01:14
A `HttpStack` implementation for Volley that uses OkHttp as its transport.
import com.android.volley.toolbox.HurlStack;
import com.squareup.okhttp.OkHttpClient;
import java.io.IOException;
import java.net.HttpURLConnection;
import java.net.URL;
/**
* An {@link com.android.volley.toolbox.HttpStack HttpStack} implementation which
* uses OkHttp as its transport.
*/