diff options
Diffstat (limited to '')
-rw-r--r-- | packages/myip.nix | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/packages/myip.nix b/packages/myip.nix index a830139..67ea1ed 100644 --- a/packages/myip.nix +++ b/packages/myip.nix @@ -1,12 +1,22 @@ { dnsutils, + lib, writeShellApplication, }: writeShellApplication { name = "myip"; + runtimeInputs = [dnsutils]; + text = '' dig -4 +short @resolver1.opendns.com myip.opendns.com A dig -6 +short @resolver1.opendns.com myip.opendns.com AAAA ''; + + meta = with lib; { + description = "A dumb tool to get host's current public IP"; + homepage = "https://git.azahi.cc/nixfiles"; + license = licenses.wtfpl; + maintainers = with maintainers; [azahi]; + }; } |