Move wiki configuration
This commit is contained in:
parent
d4a9f2f3af
commit
91d9643bd5
3 changed files with 40 additions and 35 deletions
|
@ -1,35 +1 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
home =
|
||||
let
|
||||
remoteIpAddress = "192.168.1.111";
|
||||
wikiPath = "${config.xdg.userDirs.documents}/wiki";
|
||||
in
|
||||
{
|
||||
packages = [
|
||||
(pkgs.writeShellApplication {
|
||||
name = "wiki-pull";
|
||||
|
||||
text = ''
|
||||
${lib.getExe pkgs.rsync} -avz --update \
|
||||
${remoteIpAddress}:${wikiPath}/ ${wikiPath} "$@"
|
||||
'';
|
||||
})
|
||||
|
||||
(pkgs.writeShellApplication {
|
||||
name = "wiki-push";
|
||||
|
||||
text = ''
|
||||
${lib.getExe pkgs.rsync} -avz --update \
|
||||
${wikiPath}/ ${remoteIpAddress}:${wikiPath} "$@"
|
||||
'';
|
||||
})
|
||||
];
|
||||
};
|
||||
}
|
||||
{ }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue