For developers drowning in browser tabs or juggling multiple web-based tools, the allure of standalone desktop applications—where each web app runs in its own focused window—is undeniable. Platforms like Omarchy offer this feature out-of-the-box, but what if you're committed to a lean, customizable Linux environment like Arch with DWM and suckless tools? A new script-driven method now brings this functionality to any Linux desktop, proving that elegance doesn't require proprietary bloat.

Why Standalone Web Apps Matter

Standalone web apps mimic native desktop applications, stripping away browser chrome (toolbars, menus) to run services like Gmail, Notion, or cloud IDEs in dedicated windows. This reduces distractions, improves performance for resource-heavy tools, and integrates seamlessly with tiling window managers like DWM. As web apps dominate modern workflows, this approach declutters digital workspaces—a boon for developers prioritizing focus and efficiency.

The solution hinges on two key components: a browser supporting the --app flag (e.g., Brave, Chromium) and an application launcher like dmenu. By leveraging these, a lightweight script automates the creation and management of web apps, transforming URLs into launchable desktop entries.

Implementing the Solution in Four Steps

Here’s how to replicate this setup on Arch-based systems (adaptable to any Linux distro):

  1. Set Up Directories: Create essential folders for apps and scripts:

    mkdir -p ~/.local/share/webapps/apps ~/.local/bin
    

    This organizes web app configurations and executable scripts cleanly within the user's home directory.

  2. Install the Script: Save the webapp-menu script to ~/.local/bin/webapp-menu. For quick access, here’s a truncated overview of its core function:

    #!/bin/bash
    # Script to add/launch web apps via dmenu
    APPS_DIR="$HOME/.local/share/webapps/apps"
    # ... (logic for adding/deleting apps)
    

    The script uses dmenu to present options for adding apps (name, URL, private/normal mode) and lists existing entries.

  3. Make It Executable: Grant run permissions:

    chmod +x ~/.local/bin/webapp-menu
    
  4. Integrate with Your Workflow: Bind the script to a key combination in your window manager (e.g., add to DWM’s config.h). Once triggered, dmenu displays options to create or launch apps, which then appear in standard launcher searches.

Beyond the Basics: Customization and Troubleshooting

The real power lies in adaptability. Need to use Firefox? Modify the script’s browser command. Using rofi instead of dmenu? Adjust the launcher logic. Ensure ~/.local/bin is in your $PATH for seamless access. This method exemplifies Linux’s ethos—empowering users to build bespoke solutions without vendor lock-in.

As web apps evolve, techniques like this democratize features once reserved for monolithic environments, proving that with a few lines of code, developers can reshape their tools to fit their vision, not the other way around.

Source: Protyasha Roy's article