From 1123b0db81b6057e113f16a1ddea15c36b7b3d79 Mon Sep 17 00:00:00 2001 From: pks Date: Sun, 27 Sep 2020 20:55:18 +0200 Subject: init --- db-query.rb | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100755 db-query.rb (limited to 'db-query.rb') diff --git a/db-query.rb b/db-query.rb new file mode 100755 index 0000000..3a3fa70 --- /dev/null +++ b/db-query.rb @@ -0,0 +1,14 @@ +#!/usr/bin/env ruby + +require 'sqlite3' + +def main + db = SQLite3::Database.new ARGV[0] + db.execute("select * from power") do |result| + puts result.to_s + end + db.close +end + + +main -- cgit v1.2.3