Compare commits
6 commits
22b1484026
...
24a80896a8
Author | SHA1 | Date | |
---|---|---|---|
24a80896a8 | |||
6d715d8878 | |||
a7f927516e | |||
fd793b791d | |||
5692a37c88 | |||
ff5359cd50 |
7 changed files with 82 additions and 20 deletions
|
@ -927,7 +927,7 @@ This is meant to be an helper to be called from the window manager."
|
||||||
(require 'org-roam-protocol)
|
(require 'org-roam-protocol)
|
||||||
:custom
|
:custom
|
||||||
(org-roam-v2-ack t)
|
(org-roam-v2-ack t)
|
||||||
(org-roam-directory (file-truename "~/org"))
|
(org-roam-directory (file-truename "~/roam"))
|
||||||
(org-roam-complete-everywhere 't)
|
(org-roam-complete-everywhere 't)
|
||||||
(org-roam-dailies-capture-templates
|
(org-roam-dailies-capture-templates
|
||||||
'(
|
'(
|
||||||
|
@ -1027,6 +1027,13 @@ This is meant to be an helper to be called from the window manager."
|
||||||
org-roam-ui-update-on-save t
|
org-roam-ui-update-on-save t
|
||||||
org-roam-ui-open-on-start nil))
|
org-roam-ui-open-on-start nil))
|
||||||
|
|
||||||
|
(use-package org-download
|
||||||
|
:after org
|
||||||
|
:custom (org-download-image-dir (concat org-roam-directory "/images"))
|
||||||
|
:bind
|
||||||
|
(:map org-mode-map
|
||||||
|
(("M-p" . org-download-clipboard))))
|
||||||
|
|
||||||
(use-package gptel
|
(use-package gptel
|
||||||
:custom
|
:custom
|
||||||
(gptel-model 'google/gemini-2.5-flash-preview)
|
(gptel-model 'google/gemini-2.5-flash-preview)
|
||||||
|
@ -1152,6 +1159,23 @@ This is meant to be an helper to be called from the window manager."
|
||||||
:type string
|
:type string
|
||||||
:description "The text to append to the buffer."))
|
:description "The text to append to the buffer."))
|
||||||
:category "emacs")
|
:category "emacs")
|
||||||
|
,(gptel-make-tool
|
||||||
|
:function (lambda (buffer text)
|
||||||
|
(with-current-buffer (get-buffer-create buffer)
|
||||||
|
(save-excursion
|
||||||
|
(goto-char (point-max))
|
||||||
|
(insert text)))
|
||||||
|
(format "Appended text to buffer %s" buffer))
|
||||||
|
:name "append_to_buffer"
|
||||||
|
:description "Append text to an Emacs buffer. If the buffer does not exist, it will be created."
|
||||||
|
:confirm t
|
||||||
|
:args (list '(:name "buffer"
|
||||||
|
:type string
|
||||||
|
:description "The name of the buffer to append text to.")
|
||||||
|
'(:name "text"
|
||||||
|
:type string
|
||||||
|
:description "The text to append to the buffer."))
|
||||||
|
:category "emacs")
|
||||||
,(gptel-make-tool
|
,(gptel-make-tool
|
||||||
:name "EditBuffer"
|
:name "EditBuffer"
|
||||||
:function #'ccr/edit-buffer
|
:function #'ccr/edit-buffer
|
||||||
|
@ -1185,6 +1209,22 @@ This is meant to be an helper to be called from the window manager."
|
||||||
:description "Content to write to the buffer"
|
:description "Content to write to the buffer"
|
||||||
:required t))
|
:required t))
|
||||||
:category "edit")
|
:category "edit")
|
||||||
|
,(gptel-make-tool
|
||||||
|
:function (lambda (title body)
|
||||||
|
(org-roam-capture-
|
||||||
|
:templates `(("d" "" plain "%?" :target (file+head "%<%Y%m%d%H%M%S>-${slug}.org" ,(concat "#+title: ${title}\n\n" body)))) ; override default template
|
||||||
|
:node (org-roam-node-create :title title)
|
||||||
|
:props '(:unnarrowed 't :tags "gptel"))
|
||||||
|
)
|
||||||
|
:name "create_org_roam_note"
|
||||||
|
:description "Create a new org-roam note."
|
||||||
|
:args (list '(:name "title"
|
||||||
|
:type string
|
||||||
|
:description "The name of the note to create. Try to automatically infere it and ask only if dubious.")
|
||||||
|
'(:name "body"
|
||||||
|
:type string
|
||||||
|
:description "The body of the note write in an org language, aovoid starting with an headline as first line. Feel free to exploit the org syntax."))
|
||||||
|
:category "org-roam")
|
||||||
))
|
))
|
||||||
|
|
||||||
|
|
||||||
|
|
24
hmModules/unison/default.nix
Normal file
24
hmModules/unison/default.nix
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
{ pkgs, lib, ... }:
|
||||||
|
{
|
||||||
|
home.packages = [ pkgs.unison ];
|
||||||
|
services.unison = {
|
||||||
|
enable = true;
|
||||||
|
pairs = {
|
||||||
|
"roam" = {
|
||||||
|
roots = [
|
||||||
|
# Pair of roots to synchronize
|
||||||
|
"/home/ccr/roam"
|
||||||
|
"ssh://root@sisko.wg.aciceri.dev//mnt/hd/roam"
|
||||||
|
];
|
||||||
|
commandOptions = {
|
||||||
|
auto = "true";
|
||||||
|
batch = "true";
|
||||||
|
log = "false";
|
||||||
|
repeat = "watch";
|
||||||
|
sshcmd = lib.getExe pkgs.openssh;
|
||||||
|
ui = "text";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -28,13 +28,11 @@
|
||||||
"pam"
|
"pam"
|
||||||
"wireguard-client"
|
"wireguard-client"
|
||||||
"greetd"
|
"greetd"
|
||||||
"syncthing"
|
|
||||||
"mount-sisko"
|
"mount-sisko"
|
||||||
"adb"
|
"adb"
|
||||||
"binfmt"
|
"binfmt"
|
||||||
"prometheus-exporters"
|
"prometheus-exporters"
|
||||||
"alloy"
|
"alloy"
|
||||||
"syncthing"
|
|
||||||
"zerotier"
|
"zerotier"
|
||||||
]
|
]
|
||||||
++ [ ./disko.nix ];
|
++ [ ./disko.nix ];
|
||||||
|
|
|
@ -31,7 +31,6 @@
|
||||||
"wireguard-client"
|
"wireguard-client"
|
||||||
"binfmt"
|
"binfmt"
|
||||||
"greetd"
|
"greetd"
|
||||||
"syncthing"
|
|
||||||
"hass-poweroff"
|
"hass-poweroff"
|
||||||
"forgejo-runners"
|
"forgejo-runners"
|
||||||
"teamviewer"
|
"teamviewer"
|
||||||
|
@ -99,6 +98,7 @@
|
||||||
"pantalaimon"
|
"pantalaimon"
|
||||||
"moonlight"
|
"moonlight"
|
||||||
"gimp"
|
"gimp"
|
||||||
|
"unison"
|
||||||
];
|
];
|
||||||
extraGroups = [ "plugdev" ];
|
extraGroups = [ "plugdev" ];
|
||||||
backupPaths = [ ];
|
backupPaths = [ ];
|
||||||
|
|
|
@ -29,7 +29,6 @@
|
||||||
"wireguard-client"
|
"wireguard-client"
|
||||||
"binfmt"
|
"binfmt"
|
||||||
"greetd"
|
"greetd"
|
||||||
# "syncthing"
|
|
||||||
"teamviewer"
|
"teamviewer"
|
||||||
"sunshine"
|
"sunshine"
|
||||||
"mount-sisko"
|
"mount-sisko"
|
||||||
|
|
|
@ -26,7 +26,6 @@
|
||||||
"atuin"
|
"atuin"
|
||||||
"immich"
|
"immich"
|
||||||
"paperless"
|
"paperless"
|
||||||
"syncthing"
|
|
||||||
"atticd"
|
"atticd"
|
||||||
"jellyfin"
|
"jellyfin"
|
||||||
"matrix"
|
"matrix"
|
||||||
|
@ -114,6 +113,7 @@
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
cifs-utils
|
cifs-utils
|
||||||
|
unison
|
||||||
];
|
];
|
||||||
|
|
||||||
powerManagement.scsiLinkPolicy = "med_power_with_dipm";
|
powerManagement.scsiLinkPolicy = "med_power_with_dipm";
|
||||||
|
|
|
@ -188,6 +188,7 @@ let
|
||||||
org-roam
|
org-roam
|
||||||
org-roam-ql
|
org-roam-ql
|
||||||
org-roam-ui
|
org-roam-ui
|
||||||
|
org-download
|
||||||
visual-fill-column
|
visual-fill-column
|
||||||
consult-org-roam
|
consult-org-roam
|
||||||
pass
|
pass
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue