about summary refs log tree commit diff
path: root/src/nix-hash.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/nix-hash.cc')
-rw-r--r--src/nix-hash.cc16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/nix-hash.cc b/src/nix-hash.cc
new file mode 100644
index 000000000000..e35d0a1feda3
--- /dev/null
+++ b/src/nix-hash.cc
@@ -0,0 +1,16 @@
+#include <iostream>
+
+#include "hash.hh"
+#include "shared.hh"
+
+
+void run(Strings args)
+{
+    for (Strings::iterator it = args.begin();
+         it != args.end(); it++)
+        cout << format("%1%\n") % (string) hashPath(*it);
+}
+
+
+string programId = "nix-hash";
+