# bakugo-root/autopass architecture

> Architecture diagram of the GitHub repository bakugo-root/autopass, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-02). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/bakugo-root/autopass
- Repository: https://github.com/bakugo-root/autopass

## Overview

autopass is a one-file Bash utility for filling credentials into the currently focused application without running in the background. Its documented workflow is: a keyboard shortcut starts the script; it detects the active window, decrypts the pass vault, matches a vault line against the window class or title, then types the identifier and password. Environment-specific tools provide window detection and text entry. The README documents these relationships; source excerpts were not available, so internal implementation details beyond that workflow are not asserted.

Main entry points: [`autopass`](https://github.com/bakugo-root/autopass/blob/main/autopass) (autopass script)

## Diagram (Mermaid)

```mermaid
flowchart TD

node_user(("User"))
node_script["autopass script"]
node_window_tools["Window tools"]
node_active_window["Active window"]
node_vault[("Encrypted vault")]
node_pass_gpg["pass and GPG"]
node_rule_match["Rule matching"]
node_typing_tools["Typing tools"]
node_focused_app["Focused application"]
node_notifications["Notifications"]

node_user -->|"starts by shortcut"| node_script
node_script -->|"detects window"| node_window_tools
node_window_tools -->|"reads class and title"| node_active_window
node_script -->|"decrypts vault"| node_pass_gpg
node_pass_gpg -->|"reads entry"| node_vault
node_script -->|"matches rule"| node_rule_match
node_active_window -->|"provides class and title"| node_rule_match
node_script -->|"types credentials"| node_typing_tools
node_typing_tools -->|"enters text"| node_focused_app
node_script -->|"reports no match"| node_notifications

click node_script "https://github.com/bakugo-root/autopass/blob/main/autopass"
click node_rule_match "https://github.com/bakugo-root/autopass/blob/main/autopass"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_user toneBlue
class node_script,node_rule_match toneTeal
class node_window_tools,node_active_window,node_pass_gpg,node_typing_tools,node_focused_app,node_notifications toneIndigo
class node_vault toneAmber
```

## Components

### Other components

- **User**
- [autopass script](https://github.com/bakugo-root/autopass/blob/main/autopass): `autopass`
- **Window tools**
- **Active window**
- **Encrypted vault**
- **pass and GPG**
- [Rule matching](https://github.com/bakugo-root/autopass/blob/main/autopass): `autopass`
- **Typing tools**
- **Focused application**
- **Notifications**

## Connections

- User → autopass script: starts by shortcut (evidence: `README.md`)
- autopass script → Window tools: detects window (evidence: `README.md`)
- Window tools → Active window: reads class and title (evidence: `README.md`)
- autopass script → pass and GPG: decrypts vault (evidence: `README.md`)
- pass and GPG → Encrypted vault: reads entry (evidence: `README.md`)
- autopass script → Rule matching: matches rule (evidence: `README.md`)
- Active window → Rule matching: provides class and title (evidence: `README.md`)
- autopass script → Typing tools: types credentials (evidence: `README.md`)
- Typing tools → Focused application: enters text (evidence: `README.md`)
- autopass script → Notifications: reports no match (evidence: `README.md`)
