{"id":23462570,"url":"https://github.com/dnanhkhoa/kitty-password-manager","last_synced_at":"2025-04-14T06:55:07.154Z","repository":{"id":162585193,"uuid":"631370575","full_name":"dnanhkhoa/kitty-password-manager","owner":"dnanhkhoa","description":"A simple password manager for the Kitty terminal","archived":false,"fork":false,"pushed_at":"2024-03-06T00:01:04.000Z","size":35,"stargazers_count":12,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-14T06:55:00.140Z","etag":null,"topics":["kittens","kitty","kitty-terminal","password-manager","terminal"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dnanhkhoa.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-04-22T20:09:22.000Z","updated_at":"2024-11-14T10:42:15.000Z","dependencies_parsed_at":"2024-03-06T01:25:14.628Z","dependency_job_id":"996689d6-8901-430f-885e-c426abdafe7c","html_url":"https://github.com/dnanhkhoa/kitty-password-manager","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dnanhkhoa%2Fkitty-password-manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dnanhkhoa%2Fkitty-password-manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dnanhkhoa%2Fkitty-password-manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dnanhkhoa%2Fkitty-password-manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dnanhkhoa","download_url":"https://codeload.github.com/dnanhkhoa/kitty-password-manager/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248837281,"owners_count":21169374,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["kittens","kitty","kitty-terminal","password-manager","terminal"],"created_at":"2024-12-24T08:18:02.896Z","updated_at":"2025-04-14T06:55:07.121Z","avatar_url":"https://github.com/dnanhkhoa.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# KITTY PASSWORD MANAGER\n\nA simple password manager for [the Kitty terminal](https://sw.kovidgoyal.net/kitty/).\n\n![Demo](assets/demo.gif)\n\n## Prerequisites\n\nBefore you can use this plugin, you will need to install the following dependencies:\n\n- [Bitwarden CLI](https://bitwarden.com/help/cli/#download-and-install)\n- [fzf](https://github.com/junegunn/fzf#installation)\n- [jq](https://stedolan.github.io/jq/download/)\n\nThese dependencies are necessary as the plugin uses your credentials stored in Bitwarden, fzf for interactive password selection, and jq for JSON parsing.\n\n## Installation\n\nFollow the steps below to install the plugin:\n\n1. Download [password_manager.py](password_manager.py) from this repository and place the file in the same directory as `kitty.conf`.\n\n2. Add the following snippet in your `.bashrc` or `.zshrc`, depending on your shell:\n\n```sh\nif [[ -n \"${KITTY_PASSWORD_MANAGER}\" ]]; then\n    _bw_unlock() {\n        local cache_file=\"${HOME}/.cache/kpm.session\"\n\n        [[ -f \"${cache_file}\" ]] \u0026\u0026 source \"${cache_file}\"\n\n        bw unlock --check \u0026\u003e/dev/null\n\n        if [[ $? -ne 0 ]]; then\n            (bw login --check \u0026\u003e/dev/null || bw login --apikey) \u0026\u0026 bw sync -f \u0026\u003e/dev/null\n\n            export BW_SESSION=\"$(bw unlock --raw)\"\n\n            mkdir -p \"$(dirname ${cache_file})\"\n\n            echo \"export BW_SESSION=\\\"${BW_SESSION}\\\"\" \u003e\"${cache_file}\"\n        fi\n    }\n\n    _bw_enter_pw() {\n        _bw_unlock\n\n        bw unlock --check \u0026\u003e/dev/null\n\n        if [[ $? -eq 0 ]]; then\n            local pw=$(echo \"Name\\tUsername\\tPassword\\n$(bw list items | sed 's/ /\\\\u00a0/g' | jq -r 'map(select(.type == 1)) | .[] | \"\\(.name) \\(.login.username) \\(.login.password)\"')\" | column -t | fzf --height=100% --cycle --layout=reverse --info=inline --with-nth=1,2 --header='Select an account' --header-lines=1 | tr -s ' ' | cut -d ' ' -f 3 | sed 's/\\\\u00a0/ /g')\n\n            [[ -n \"${pw}\" ]] \u0026\u0026 echo \"${pw}\" | kitty @ send-text -m id:$1 --stdin\n        fi\n    }\n\n    () {\n        trap 'exit' EXIT\n\n        _bw_enter_pw \"${KITTY_PASSWORD_MANAGER}\"\n    }\nfi\n```\n\n3. Set up a key shortcut to activate the plugin in your `kitty.conf`. For example, you can use `Ctrl+Shift+Cmd+P`:\n\n```properties\nmap ctrl+shift+cmd+p kitten password_manager.py\n```\n\n## Usage\n\nNow that the installation is complete, you can start using the plugin. Whenever you are at a password prompt, simply press the key shortcut that you have defined above to activate the plugin. The plugin will prompt you to select the appropriate account and will then automatically fill in your password.\n\n## Credits\n\nThis plugin is inspired by [Andrew Lazarus's work](https://github.com/nerdrew/kittens/blob/master/password.py).\n\n## License\n\n[Apache License 2.0](https://choosealicense.com/licenses/apache-2.0/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdnanhkhoa%2Fkitty-password-manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdnanhkhoa%2Fkitty-password-manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdnanhkhoa%2Fkitty-password-manager/lists"}