On LineageOS 23.2 how to disable an app notification category with `adb`?
Feb 26, 11:28am

To disable a specific notification category for an app using ADB on LineageOS 23.2 (or similar Android versions), you can use the following approach:

  1. List Notification Channels: First, find the notification channel ID you want to disable. Use this command to list all notification channels for a specific app (replace com.example.app with your app's package name):

    bash
    adb shell dumpsys notification | grep -A 10 "com.example.app"

    This will output the notification channels for the app, including their IDs.

  2. Disable the Notification Channel: Once you have the channel ID (e.g., channel_id), use this command to disable it:

    bash
    adb shell cmd notification allow_channel <package_name> <channel_id> false

    Replace <package_name> with the app's package name and <channel_id> with the channel ID you want to disable.

Example: If you want to disable the phone_ongoing_call channel for the Dialer app (com.google.android.dialer), use:

bash
adb shell cmd notification allow_channel com.google.android.dialer phone_ongoing_call false

This method works for most Android versions, including LineageOS 23.2, and does not require root access.

Would you like help finding the package name or channel ID for a specific app?

Feb 26, 11:28am

This is a shared conversation and may include unverified content that doesn't reflect Mistral AI's views. Login to resume chatting.