fixing some yazi and working on server

This commit is contained in:
Matt Nish-Lapidus 2025-04-14 12:29:32 -04:00
parent f2e2a045d8
commit 3ed1509126
6 changed files with 43 additions and 15 deletions

View file

@ -76,7 +76,7 @@
vlc
discord
slack
signal-desktop
signal-desktop-bin
libreoffice
hyphenDicts.en_US
plex-mpv-shim

View file

@ -44,7 +44,7 @@
owner = "boydaihungst";
repo = "restore.yazi";
rev = "HEAD";
sha256 = "sha256-OJJPgpSaUHYz8a9opVLCds+VZsK1B6T+pSRJyVgYNy8=";
sha256 = "sha256-3Z8P25u9bffdjrPjxLRWUQn6MdBS+vyElUBkgV4EUwY=";
};
lazygit = pkgs.fetchFromGitHub {
owner = "Lil-Dank";
@ -116,8 +116,8 @@
{ on = ["d" "d"]; run = "remove"; desc = "Delete files/folders"; }
{ on = ["d" "u"]; run = "plugin restore"; desc = "Restore last deleted files/folders"; }
{ on = "f"; run = "filter --smart"; desc = "Find file"; }
{ on = "F"; run = "find --smart"; desc = "Find file"; }
{ on = "F"; run = "filter --smart"; desc = "Find file"; }
{ on = "f"; run = "find --smart"; desc = "Find file"; }
{ on = "z"; run = "plugin zoxide"; }
{ on = "Z"; run = "plugin fzf"; }

View file

@ -1,6 +1,18 @@
require("git"):setup()
require("dir-rules"):setup()
require("restore"):setup({
-- Set the position for confirm and overwrite dialogs.
-- don't forget to set height: `h = xx`
-- https://yazi-rs.github.io/docs/plugins/utils/#ya.input
position = { "center", w = 70, h = 40 }, -- Optional
-- Show confirm dialog before restore.
-- NOTE: even if set this to false, overwrite dialog still pop up
show_confirm = true, -- Optional
})
Status:children_add(function()
local h = cx.active.current.hovered
if h == nil or ya.target_family() ~= "unix" then

View file

@ -1,5 +1,7 @@
{ config, lib, pkgs, ... }:
let
port = 12345;
in
{
services = {
forgejo = {
@ -7,7 +9,7 @@
lfs.enable = true;
settings = {
server = {
HTTP_PORT = 12345;
HTTP_PORT = port;
};
service.DISABLE_REGISTRATION = true;
actions = {
@ -24,6 +26,17 @@
# mailerPasswordFile = config.age.secrets.forgejo-mailer-password.path;
};
# caddy.virtualHosts."gt.emenel.ca" = {
# serverAliases = [ "www.gt.emenel.ca" ];
# extraConfig = ''
# reverse_proxy http://localhost:${port} {
# header_down X-Real-IP {http.request.remote}
# header_down X-Forwarded-For {http.request.remote}
# }
# '';
# };
};
# gitea-actions-runner = {
# package = pkgs.forgejo-actions-runner;
# instances.default = {
@ -66,10 +79,10 @@
sops.secrets.forgejo-emenel.owner = "forgejo";
systemd.services.forgejo.preStart = let
adminCmd = "${lib.getExe pkgs.forgejo} admin user";
pwd = config.sops.secrets.forgejoemenel;
pwd = config.sops.secrets.forgejo-emenel;
user = "emenel"; # Note, Forgejo doesn't allow creation of an account named "admin"
in ''
${adminCmd} create --admin --email "root@localhost" --username ${user} --password "$(tr -d '\n' < ${pwd.path})" || true
${adminCmd} create --admin --email "matt@emenel.ca" --username ${user} --password "$(tr -d '\n' < ${pwd.path})" || true
## uncomment this line to change an admin user which was already created
# ${adminCmd} change-password --username ${user} --password "$(tr -d '\n' < ${pwd.path})" || true
'';