.gitea/workflows | ||
.gitignore | ||
Eask | ||
LICENSE | ||
Makefile | ||
password-gen.el | ||
README.org |
password-gen
Introduction
password-gen
is a utility package for generating passwords from within
Emacs. These passwords can be either copied or directly inserted in an
Emacs buffer.
Motivation
I often manipulate files that deal with passwords, such as dotenv files for services I either deploy to my servers or work on myself. I got really tired of always opening a terminal, remembering which command to use, copy manually its output only to insert it back in my initial Emacs buffer. So, why not directly generate it from Emacs and have it available as is?
Installation
Local Installation
The vanilla way of installing this package is to clone this repository
somewhere on your machine and add it to your Emacs’ load-path
as shown
below.
(add-to-list 'load-path "~/path/to/your/clone/password-gen.el")
Then, you can require
this package as needed.
(require 'password-gen)
Straight + use-package
This is my preferred method, as I use this combo everywhere in my configuration. This snippet below is what I use to have my package available.
(use-package password-gen
:straight (password-gen :build t
:type git
:repo "https://labs.phundrak.com/phundrak/password-gen.el.git")
:ensure t
:defer t)
Other Methods
I am aware other methods are available, such as a use-package
only
method (especially interesting since Emacs 29), elpaca, quelpa, or
Spacemacs’ and DoomEmacs’ package managers. However, I am unsure how
to install it with these methods. If you do, feel free to submit a PR
with new instructions!
Upcoming Changes
When working on this project, I was mainly inspired by Bitwarden’s password generator. Here are some features I would like to implement in the future:
- Avoid ambiguous characters (don’t generate
O
and0
in the same password, for instance) - Have a minimum amount of special characters
- Have a minimum amount of numbers
License
password-gen
is available under the GNU GPL-3.0 License. You can find
the full text in LICENSE.