mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-09 12:29:19 -08:00
nixdirfmt + getAlias function
This commit is contained in:
parent
589bef29fa
commit
5da38c626d
7 changed files with 89 additions and 83 deletions
|
|
@ -1,8 +1,10 @@
|
|||
{ config, tf, meta, kw, pkgs, lib, sources, ... }: with lib; let
|
||||
oci-root = meta.deploy.targets.oci-root.tf;
|
||||
addr_ipv6_nix = let
|
||||
addr_ipv6_nix =
|
||||
let
|
||||
prefix = head (splitString "/" (oci-root.resources.oci_kw_subnet.importAttr "ipv6cidr_block"));
|
||||
in assert hasSuffix "::" prefix; prefix + "7";
|
||||
in
|
||||
assert hasSuffix "::" prefix; prefix + "7";
|
||||
in
|
||||
{
|
||||
imports = (with (import (sources.tf-nix + "/modules")); [
|
||||
|
|
|
|||
|
|
@ -20,6 +20,9 @@ in
|
|||
nano = ''
|
||||
${pkgs.kitty}/bin/kitty +kitten icat ${./nano.png}
|
||||
'';
|
||||
getAlias = ''
|
||||
printf '%s\n' $aliases[$1]
|
||||
'';
|
||||
} // shellFunAliases {
|
||||
sed = "sd";
|
||||
find = "fd";
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
let initvim = pkgs.callPackage
|
||||
let
|
||||
initvim = pkgs.callPackage
|
||||
({ stdenv, elinks, nodejs }: stdenv.mkDerivation {
|
||||
name = "init.vim";
|
||||
src = ./init.vim;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue