diff --git a/COPYING b/COPYING new file mode 100644 index 0000000..e31cea1 --- /dev/null +++ b/COPYING @@ -0,0 +1,8 @@ +/* + * ---------------------------------------------------------------------------- + * "THE BEER-WARE LICENSE" (Revision 42.1): + * wrote this file. As long as you retain this notice you + * can do whatever you want with this stuff. If we meet some day, and you think + * this stuff is worth it, you can buy me a bottle of sake in return Izuru Yakumo + * ---------------------------------------------------------------------------- + */ diff --git a/DPL-2.3 b/DPL-2.3 deleted file mode 100644 index c467e69..0000000 --- a/DPL-2.3 +++ /dev/null @@ -1,15 +0,0 @@ -Discordian Public License 2.3 (DPL-2.3) - -All Rites Reversed (ĸ) 3188 Aoi Koizumi [Champagne Supernova] - -Permission is hereby granted, to any person obtaining a copy of this -material without restriction, including but not limited the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the material, subject to the following conditions: - -YOU AGREE THAT THERE IS NO GODDESS BUT GODDESS AND SHE IS YOUR GODDESS & -THAT THERE IS NO ERISIAN MOVEMENT BUT THE ERISIAN MOVEMENT AND IT IS THE -ERISIAN MOVEMENT. - -HAIL ERIS! -FIVE TONS OF FLAX diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..4501190 --- /dev/null +++ b/Makefile @@ -0,0 +1,18 @@ +include config.mk + +install: install-bin install-examples install-man +uninstall: uninstall-bin uninstall-examples uninstall-man + +install-bin: + install -Dm${EXEC_MODE} kanako ${PREFIX}/bin/kanako +install-examples: + install -Dm${FILE_MODE} kanako.conf.example ${PREFIX}/share/examples/kanako/kanako.conf +install-man: + install -Dm${FILE_MODE} kanako.mdoc ${PREFIX}/share/man/man1/kanako.1 + install -Dm${FILE_MODE} kanako.conf.mdoc ${PREFIX}/share/man/man5/kanako.conf.5 +uninstall-bin: + rm -f ${PREFIX}/bin/kanako +uninstall-examples: + rm -f ${PREFIX}/share/examples/kanako/kanako.conf ${PREFIX}/share/exmaples/kanako/kanakomenu.conf +uninstall-man: + rm -f ${PREFIX}/share/man/man1/kanako.1 ${PREFIX}/share/man/man5/kanako.conf.5 diff --git a/README.md b/README.md index a6e7ce5..f12bb2f 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ # kanako (神奈子) -the adaptable password manager. named after [Kanako Yasaka](https://en.touhouwiki.net/wiki/Kanako_Yasaka) +the adaptable password manager. named after [Kanako Yasaka](https://en.touhouwiki.net/wiki/Kanako_Yasaka) from [Touhou 10: Mountain of Faith](https://en.touhouwiki.net/wiki/Mountain_of_Faith) ## Backends supported * [age](https://age-encryption.org) @@ -14,21 +14,21 @@ the adaptable password manager. named after [Kanako Yasaka](https://en.touhouwik ## Add-ons -### kanako_gen +### kanako\_gen random username and password generator, requires `strings(1)`, `dd(1)` and a sane `tr(1)` (FreeBSD's one behaves differently and in unexpected ways) -### kanako_menu +### kanako\_menu quick graphical front-end for kanako, works with either of `dmenu(1)` or `bemenu(1)`, useful for copying passwords to clipboard. -### kanako_totp +### kanako\_totp time-based one time password addon for kanako, requires `oathtool(1)` from oath-toolkit. ## License -* [Discordian Public License, version 2.3](https://gt.kalli.st/novaburst/discordian-public-license/src/branch/discordia/DPL-2.3) +* [Beerware License (Revision 42.1)](COPYING) ## Related software * [akoizumi/ayu](https://git.shelltalk.net/akoizumi/ayu) [predecessor] diff --git a/addons/kanako_gen b/addons/kanako_gen index 970626c..97cc61a 100755 --- a/addons/kanako_gen +++ b/addons/kanako_gen @@ -1,4 +1,5 @@ #!/bin/sh -e +# $TheSupernovaDuo: kanako_gen,v 1.9 2023/5/18 21:9:33 yakumo_izuru Exp $ fn_genpass() { printf "Password: %s\n" $(strings /dev/null | tr -d " \t\n\r") diff --git a/addons/kanako_menu b/addons/kanako_menu index e747e93..8725ad1 100755 --- a/addons/kanako_menu +++ b/addons/kanako_menu @@ -1,6 +1,7 @@ #!/bin/sh -e -readonly kanako_conf_dir="${conf_dir:-$HOME/.config/kanako}" -readonly kanako_store_dir="${store_dir:-$HOME/.kanako-store}" +# $TheSupernovaDuo: kanako,v 1.9 2023/5/18 21:9:33 yakumo_izuru Exp $ +readonly kanako_conf_dir="${kanako_conf_dir:-$HOME/.config/kanako}" +readonly kanako_store_dir="${kanako_store_dir:-$HOME/.kanako-store}" if test -f "${kanako_conf_dir}"/kanako.conf; then . "${kanako_conf_dir}"/kanako.conf diff --git a/addons/kanako_totp b/addons/kanako_totp index 8eba861..d544872 100755 --- a/addons/kanako_totp +++ b/addons/kanako_totp @@ -1,4 +1,5 @@ #!/bin/sh -e +# $TheSupernovaDuo: kanako,v 1.9 2023/5/18 21:9:33 yakumo_izuru Exp $ # extracted from https://rgz.ee/bin/pass totp_seed="$(kanako -v "$@" | grep 'totp: ' | head -n1 | cut -d' ' -f2)" diff --git a/kanako b/kanako index 41ab5a1..cf26757 100755 --- a/kanako +++ b/kanako @@ -1,5 +1,5 @@ #!/bin/sh -# $KyokoNet: kanako,v 1.8 2022/11/29 19:59:07 akoizumi Exp $ +# $TheSupernovaDuo: kanako,v 1.9 2023/5/18 21:9:33 yakumo_izuru Exp $ readonly kanako_conf_dir="${kanako_conf_dir:-$HOME/.config/kanako}" readonly kanako_key_dir="${kanako_key_dir:-$HOME/.kanako}" @@ -8,17 +8,17 @@ readonly kanako_store_dir="${kanako_store_dir:-$HOME/.kanako-store}" if test -d "${kanako_store_dir}"; then cd "${kanako_store_dir}" else - echo "Password store not found!" - echo "Create it with mkdir -p $kanako_store_dir" + printf "Password store not found!\n" + printf "Create it with mkdir -p %s\n" "$kanako_store_dir" exit 1 fi if test -f "${kanako_conf_dir}/kanako.conf"; then . "${kanako_conf_dir}/kanako.conf"; else - echo "Configuration file has not been found!" - echo "Copy kanako.conf from the examples directory," - echo "and edit accordingly." + printf "Configuration file has not been found!\n" + printf "Copy kanako.conf from the examples directory,\n" + printf "and edit accordingly.\n" exit 1 fi