aly: switch to bitwarden (#72)

* aly: add password-store with extensions

* aly: add rofi-pass

* aly: simplify rofi-pass config

* aly: add rbw config

* aly/wm: bind super+p to rofi-rbw

* aly: remove password-store

* aly: remove rofi-pass

* aly/firefox: remove keepassxc extension

* aly: install bitwarden-desktop

* rofi: include rofi-rbw by default with sane defaults

* aly/wm: don't autostart keepassxc

* aly: remove keepassxc secret

* aly/wm: center and float bitwarden gui

* chromium: don't install keepassxc extension by default
This commit is contained in:
Aly Raffauf 2024-08-02 07:50:06 -04:00 committed by GitHub
parent 8dd3204275
commit aec4214add
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 187 additions and 217 deletions

View file

@ -12,7 +12,6 @@
{id = "enamippconapkdmgfgjchkhakpfinmaj";} # dearrow {id = "enamippconapkdmgfgjchkhakpfinmaj";} # dearrow
{id = "jldhpllghnbhlbpcmnajkpdmadaolakh";} # todoist {id = "jldhpllghnbhlbpcmnajkpdmadaolakh";} # todoist
{id = "mnjggcdmjocbbbhaepdhchncahnbgone";} # sponsorblock {id = "mnjggcdmjocbbbhaepdhchncahnbgone";} # sponsorblock
{id = "oboonakemofpalcgghocfoadofidjkkk";} # keepassxc
{id = "ocabkmapohekeifbkoelpmppmfbcibna";} # zoom redirector {id = "ocabkmapohekeifbkoelpmppmfbcibna";} # zoom redirector
]; ];
}; };

View file

@ -10,6 +10,7 @@ in {
home.packages = [ home.packages = [
pkgs.networkmanager_dmenu pkgs.networkmanager_dmenu
pkgs.rofi-bluetooth pkgs.rofi-bluetooth
pkgs.rofi-rbw-wayland
]; ];
programs.rofi = { programs.rofi = {
@ -61,168 +62,175 @@ in {
}; };
}; };
xdg.configFile."rofi/theme.rasi".text = '' xdg.configFile = {
* { "rofi-rbw.rc".text = ''
selected-normal-foreground: ${cfg.theme.colors.text}; prompt "Bitwarden"
foreground: ${cfg.theme.colors.text}; clear-after 60
normal-foreground: @foreground; '';
alternate-normal-background: transparent;
red: ${cfg.theme.colors.secondary};
selected-urgent-foreground: ${cfg.theme.colors.secondary};
blue: ${cfg.theme.colors.primary};
urgent-foreground: ${cfg.theme.colors.primary};
alternate-urgent-background: transparent;
active-foreground: ${cfg.theme.colors.primary};
lightbg: rgba ( 238, 232, 213, 100 % );
selected-active-foreground: rgba ( 32, 81, 113, 100 % );
alternate-active-background: transparent;
background: transparent;
bordercolor: ${cfg.theme.colors.background}CC;
alternate-normal-foreground: @foreground;
normal-background: transparent;
lightfg: rgba ( 88, 104, 117, 100 % );
selected-normal-background: ${cfg.theme.colors.primary};
border-color: ${cfg.theme.colors.primary};
spacing: 2;
separatorcolor: ${cfg.theme.colors.primary};
urgent-background: transparent;
selected-urgent-background: ${cfg.theme.colors.primary};
alternate-urgent-foreground: @urgent-foreground;
background-color: rgba ( 0, 0, 0, 0 % );
alternate-active-foreground: @active-foreground;
active-background: ${cfg.theme.colors.background}CC;
selected-active-background: ${cfg.theme.colors.primary};
}
window {
background-color: ${cfg.theme.colors.background}CC;
border: 2;
border-radius: 10px;
padding: 0;
}
mainbox {
border: 0;
padding: 0;
}
message {
border: 2px solid 0px 0px ;
border-color: @separatorcolor;
padding: 1px ;
}
textbox {
text-color: @foreground;
}
listview {
fixed-height: 0;
border: 2px solid 0px 0px ;
border-color: @separatorcolor;
spacing: 2px ;
scrollbar: false;
padding: 5px;
}
element {
border: 0;
padding: 5px;
border-radius: 10px;
}
element-text {
background-color: inherit;
text-color: inherit;
}
element.normal.normal {
background-color: @normal-background;
text-color: @normal-foreground;
}
element.normal.urgent {
background-color: @urgent-background;
text-color: @urgent-foreground;
}
element.normal.active {
background-color: @active-background;
text-color: @active-foreground;
}
element.selected.normal {
background-color: @selected-normal-background;
text-color: @selected-normal-foreground;
}
element.selected.urgent {
background-color: @selected-urgent-background;
text-color: @selected-urgent-foreground;
}
element.selected.active {
background-color: @selected-active-background;
text-color: @selected-active-foreground;
}
element.alternate.normal {
background-color: @alternate-normal-background;
text-color: @alternate-normal-foreground;
}
element.alternate.urgent {
background-color: @alternate-urgent-background;
text-color: @alternate-urgent-foreground;
}
element.alternate.active {
background-color: @alternate-active-background;
text-color: @alternate-active-foreground;
}
scrollbar {
width: 0px ;
border: 0;
handle-width: 0px ;
padding: 0;
}
mode-switcher {
border: 2px solid 0px 0px ;
border-color: @separatorcolor;
}
button.selected {
background-color: @selected-normal-background;
text-color: @selected-normal-foreground;
}
button {
background-color: @background;
text-color: @foreground;
}
inputbar {
spacing: 0;
text-color: @normal-foreground;
padding: 10px ;
}
case-indicator {
spacing: 0;
text-color: @normal-foreground;
}
entry {
spacing: 0;
text-color: @normal-foreground;
}
prompt {
spacing: 0;
text-color: @normal-foreground;
margin: 1px;
}
inputbar {
children: [ prompt,textbox-prompt-colon,entry,case-indicator ];
}
textbox-prompt-colon {
expand: false;
str: ":";
margin: 0px 0.3em 0em 0em ;
text-color: @normal-foreground;
}
'';
xdg.configFile."networkmanager-dmenu/config.ini".text = '' "rofi/theme.rasi".text = ''
[dmenu] * {
dmenu_command = ${lib.getExe config.programs.rofi.package} selected-normal-foreground: ${cfg.theme.colors.text};
highlight = True foreground: ${cfg.theme.colors.text};
normal-foreground: @foreground;
alternate-normal-background: transparent;
red: ${cfg.theme.colors.secondary};
selected-urgent-foreground: ${cfg.theme.colors.secondary};
blue: ${cfg.theme.colors.primary};
urgent-foreground: ${cfg.theme.colors.primary};
alternate-urgent-background: transparent;
active-foreground: ${cfg.theme.colors.primary};
lightbg: rgba ( 238, 232, 213, 100 % );
selected-active-foreground: rgba ( 32, 81, 113, 100 % );
alternate-active-background: transparent;
background: transparent;
bordercolor: ${cfg.theme.colors.background}CC;
alternate-normal-foreground: @foreground;
normal-background: transparent;
lightfg: rgba ( 88, 104, 117, 100 % );
selected-normal-background: ${cfg.theme.colors.primary};
border-color: ${cfg.theme.colors.primary};
spacing: 2;
separatorcolor: ${cfg.theme.colors.primary};
urgent-background: transparent;
selected-urgent-background: ${cfg.theme.colors.primary};
alternate-urgent-foreground: @urgent-foreground;
background-color: rgba ( 0, 0, 0, 0 % );
alternate-active-foreground: @active-foreground;
active-background: ${cfg.theme.colors.background}CC;
selected-active-background: ${cfg.theme.colors.primary};
}
window {
background-color: ${cfg.theme.colors.background}CC;
border: 2;
border-radius: 10px;
padding: 0;
}
mainbox {
border: 0;
padding: 0;
}
message {
border: 2px solid 0px 0px ;
border-color: @separatorcolor;
padding: 1px ;
}
textbox {
text-color: @foreground;
}
listview {
fixed-height: 0;
border: 2px solid 0px 0px ;
border-color: @separatorcolor;
spacing: 2px ;
scrollbar: false;
padding: 5px;
}
element {
border: 0;
padding: 5px;
border-radius: 10px;
}
element-text {
background-color: inherit;
text-color: inherit;
}
element.normal.normal {
background-color: @normal-background;
text-color: @normal-foreground;
}
element.normal.urgent {
background-color: @urgent-background;
text-color: @urgent-foreground;
}
element.normal.active {
background-color: @active-background;
text-color: @active-foreground;
}
element.selected.normal {
background-color: @selected-normal-background;
text-color: @selected-normal-foreground;
}
element.selected.urgent {
background-color: @selected-urgent-background;
text-color: @selected-urgent-foreground;
}
element.selected.active {
background-color: @selected-active-background;
text-color: @selected-active-foreground;
}
element.alternate.normal {
background-color: @alternate-normal-background;
text-color: @alternate-normal-foreground;
}
element.alternate.urgent {
background-color: @alternate-urgent-background;
text-color: @alternate-urgent-foreground;
}
element.alternate.active {
background-color: @alternate-active-background;
text-color: @alternate-active-foreground;
}
scrollbar {
width: 0px ;
border: 0;
handle-width: 0px ;
padding: 0;
}
mode-switcher {
border: 2px solid 0px 0px ;
border-color: @separatorcolor;
}
button.selected {
background-color: @selected-normal-background;
text-color: @selected-normal-foreground;
}
button {
background-color: @background;
text-color: @foreground;
}
inputbar {
spacing: 0;
text-color: @normal-foreground;
padding: 10px ;
}
case-indicator {
spacing: 0;
text-color: @normal-foreground;
}
entry {
spacing: 0;
text-color: @normal-foreground;
}
prompt {
spacing: 0;
text-color: @normal-foreground;
margin: 1px;
}
inputbar {
children: [ prompt,textbox-prompt-colon,entry,case-indicator ];
}
textbox-prompt-colon {
expand: false;
str: ":";
margin: 0px 0.3em 0em 0em ;
text-color: @normal-foreground;
}
'';
[dmenu_passphrase] "networkmanager-dmenu/config.ini".text = ''
obscure = True [dmenu]
dmenu_command = ${lib.getExe config.programs.rofi.package}
highlight = True
[editor] [dmenu_passphrase]
gui = ${pkgs.networkmanagerapplet}/bin/nm-connection-editor obscure = True
gui_if_available = True
terminal = ${lib.getExe cfg.defaultApps.terminal} [editor]
''; gui = ${pkgs.networkmanagerapplet}/bin/nm-connection-editor
gui_if_available = True
terminal = ${lib.getExe cfg.defaultApps.terminal}
'';
};
}; };
} }

View file

@ -28,6 +28,7 @@ in {
}; };
packages = [ packages = [
pkgs.bitwarden-desktop
pkgs.browsh pkgs.browsh
pkgs.curl pkgs.curl
pkgs.fractal pkgs.fractal
@ -62,26 +63,14 @@ in {
gitui.enable = true; gitui.enable = true;
home-manager.enable = true; home-manager.enable = true;
password-store = { rbw = {
enable = true; enable = true;
package = unstable.rbw;
package = pkgs.pass.withExtensions (exts: settings = {
with exts; [ email = "alyraffauf@fastmail.com";
pass-checkup pinentry = pkgs.pinentry-gnome3;
pass-file };
pass-genphrase
pass-otp
pass-update
]);
};
rofi.pass = {
enable = true;
package = pkgs.rofi-pass-wayland;
extraConfig = ''
USERNAME_field='login'
'';
}; };
}; };

View file

@ -22,7 +22,6 @@
extensions = with config.nur.repos.rycee.firefox-addons; [ extensions = with config.nur.repos.rycee.firefox-addons; [
augmented-steam augmented-steam
decentraleyes decentraleyes
keepassxc-browser
omnivore omnivore
raindropio raindropio
sidebery sidebery
@ -162,7 +161,6 @@
clearurls clearurls
consent-o-matic consent-o-matic
decentraleyes decentraleyes
keepassxc-browser
ublock-origin ublock-origin
zoom-redirector zoom-redirector
]; ];

View file

@ -4,7 +4,6 @@
alyraffaufFastmail.file = ../../secrets/aly/mail/alyraffauf_fastmail.age; alyraffaufFastmail.file = ../../secrets/aly/mail/alyraffauf_fastmail.age;
backblazeKeyId.file = ../../secrets/aly/backblaze/keyId.age; backblazeKeyId.file = ../../secrets/aly/backblaze/keyId.age;
backblazeKey.file = ../../secrets/aly/backblaze/key.age; backblazeKey.file = ../../secrets/aly/backblaze/key.age;
keepassxc.file = ../../secrets/aly/keepassxc.age;
transmissionRemote = { transmissionRemote = {
file = ../../secrets/aly/transmissionRemote.age; file = ../../secrets/aly/transmissionRemote.age;

View file

@ -3,9 +3,7 @@
lib, lib,
pkgs, pkgs,
... ...
}: let }: {
keepassxc = "${lib.getExe' config.ar.home.apps.keepassxc.package "keepassxc"} --pw-stdin ${config.home.homeDirectory}/sync/Passwords.kdbx < ${config.age.secrets.keepassxc.path}";
in {
programs.waybar.settings.mainBar."bluetooth" = { programs.waybar.settings.mainBar."bluetooth" = {
"on-click" = lib.mkForce "${lib.getExe pkgs.rofi-bluetooth} -i"; "on-click" = lib.mkForce "${lib.getExe pkgs.rofi-bluetooth} -i";
}; };
@ -20,10 +18,10 @@ in {
"workspace 5: work" = [{app_id = "google-chrome";} {app_id = "chromium-browser";} {app_id = "firework";}]; "workspace 5: work" = [{app_id = "google-chrome";} {app_id = "chromium-browser";} {app_id = "firework";}];
}; };
floating.criteria = [{app_id = "org.keepassxc.KeePassXC";}]; floating.criteria = [{app_id = "Bitwarden";} {app_id = "org.keepassxc.KeePassXC";}];
keybindings = { keybindings = {
"${config.wayland.windowManager.sway.config.modifier}+P" = "exec ${keepassxc}"; "${config.wayland.windowManager.sway.config.modifier}+P" = "exec ${lib.getExe pkgs.rofi-rbw-wayland}";
"${config.wayland.windowManager.sway.config.modifier}+N" = "exec ${lib.getExe' pkgs.obsidian "obsidian"}"; "${config.wayland.windowManager.sway.config.modifier}+N" = "exec ${lib.getExe' pkgs.obsidian "obsidian"}";
}; };
@ -39,11 +37,13 @@ in {
}; };
}; };
startup = [{command = ''sleep 1 && ${keepassxc}'';}];
window.commands = [ window.commands = [
{ {
command = "resize set 80ppt 80ppt; move position center; sticky toggle; "; command = "resize set 80ppt 80ppt; move position center;";
criteria = {app_id = "Bitwarden";};
}
{
command = "resize set 80ppt 80ppt; move position center; sticky toggle;";
criteria = {app_id = "org.keepassxc.KeePassXC";}; criteria = {app_id = "org.keepassxc.KeePassXC";};
} }
]; ];
@ -53,16 +53,17 @@ in {
bind = [ bind = [
"SUPER SHIFT,N,movetoworkspace,special:notes" "SUPER SHIFT,N,movetoworkspace,special:notes"
"SUPER,N,togglespecialworkspace,notes" "SUPER,N,togglespecialworkspace,notes"
"SUPER,P,exec,${keepassxc}" "SUPER,P,exec,${lib.getExe pkgs.rofi-rbw-wayland}"
]; ];
exec-once = ["sleep 1 && ${keepassxc}"];
input.kb_options = "ctrl:nocaps"; input.kb_options = "ctrl:nocaps";
windowrulev2 = [ windowrulev2 = [
"center(1),class:(Bitwarden)"
"center(1),class:(org.keepassxc.KeePassXC)" "center(1),class:(org.keepassxc.KeePassXC)"
"float,class:(Bitwarden)"
"float,class:(org.keepassxc.KeePassXC)" "float,class:(org.keepassxc.KeePassXC)"
"size 80% 80%,class:(Bitwarden)"
"size 80% 80%,class:(org.keepassxc.KeePassXC)" "size 80% 80%,class:(org.keepassxc.KeePassXC)"
"workspace 1,class:(brave-browser)" "workspace 1,class:(brave-browser)"
"workspace 1,class:(firefox)" "workspace 1,class:(firefox)"

View file

@ -1,23 +0,0 @@
age-encryption.org/v1
-> ssh-ed25519 xIeYNQ jNhPUqxRGL1/AgHEmzbkiVUyjEWwj0YdW05zAIyo1kk
5yhF4pbBu1RSxYXZBfr+EO2SZ7jmyilE6rabF6RnPrE
-> ssh-ed25519 g+apXg dhEVCLqN3BSJcBmqeWpsXwBFWuKxT78qds3oACPCsVA
bq6xG45TiYdLibqINhzZVWzpjAe3nYTbREErU0631Rc
-> ssh-ed25519 xZaw4A 6soVrhT7xPJd5Bz8oKtCNANxBdfkFnf6h0Vo7/PsCzk
VQmSHXgfLEQLo/eWROfZrIPnan/13cX++cHVp4jUz5I
-> ssh-ed25519 GrlIbA dgLoBxYih2VGLXsKoRGlYKB8jxLalsyX+MXV1bqSXBk
4/L8Pk39+NnObP57T56qQgg91iIPrKxl7KyiER9vPGw
-> ssh-ed25519 STQ5RA qJuOjmwNlQpvLOWljB5hT1M6rFGUy6HONSrRe/DI9EM
RSi/QojxNbZn5KTzrfyHJUgXA/xk0Ml0aXEVxv08U+g
-> ssh-ed25519 nrny8w 81xJfiA33ew6xXW+uZDFnLae/RJnUcZwuNNTBeX6sWI
aQszpGAyAXk+k6cl37/yieDgruq2OaTd+t/aPd0ixGA
-> ssh-ed25519 c7E/gQ ABPJ26sXSC6PU7EBv+xCCvNGkeKpkmhKvVaiAkvAKWM
/cpZC4H1hdvylEyt2Vh/4WR3s1+sovEQiEJcVSEQ/ho
-> ssh-ed25519 IghKlQ GTiXc4wtFZd2eeZHaEtRDtrlIXJHWLNzfp8wORVnoWE
g5k2lTqcx5nvAX09rDZkMx9sSIthrwKhjvs3R0vmgpU
-> ssh-ed25519 1mX44w xVeaRaqaIVSM7MWsW0TXmzreb5dt5lUbKYJSMrhdNiw
5byOZi2QHGStVmWCT/L3p7HpDmnQkD2tfVE1sqYqjEA
-> ssh-ed25519 FhVeqQ mXAIr6c4Ipv1p1hfdLDIYj6T7Ia0curJv0Ao+28X+mw
iYjxG756GietbM4J7bVjV23qjcOwAXP7Rf1llL6BDgo
--- NlASWbMfTtePdKOvTQ1MXypX1iPDymslSLJglpIzfxs
ÍÞ—îÄ÷éØÉ<´À<C2B4>)]fAXÍG·­åé«œœ$I+åO(¥g™WÐð”Úgéóö[5Ô)à¯LÑÄ

View file

@ -19,7 +19,6 @@ let
in { in {
"aly/backblaze/key.age".publicKeys = keys; "aly/backblaze/key.age".publicKeys = keys;
"aly/backblaze/keyId.age".publicKeys = keys; "aly/backblaze/keyId.age".publicKeys = keys;
"aly/keepassxc.age".publicKeys = keys;
"aly/mail/achacega_gmail.age".publicKeys = keys; "aly/mail/achacega_gmail.age".publicKeys = keys;
"aly/mail/alyraffauf_fastmail.age".publicKeys = keys; "aly/mail/alyraffauf_fastmail.age".publicKeys = keys;
"aly/syncthing/fallarbor/cert.age".publicKeys = keys; "aly/syncthing/fallarbor/cert.age".publicKeys = keys;