diff options
author | mattn <mattn.jp@gmail.com> | 2011-10-27 21:22:48 +0900 |
---|---|---|
committer | mattn <mattn.jp@gmail.com> | 2011-10-27 21:22:48 +0900 |
commit | a1acbaffbd086ceb1fe4625ebb4413cc6a898cab (patch) | |
tree | 06c783732a007c2caa8366142bd625a8be330bc0 | |
parent | 3a67144b6ccf3291eb1f16db00427bf4e49dc62e (diff) | |
download | vim-sonictemplate-a1acbaffbd086ceb1fe4625ebb4413cc6a898cab.tar.gz vim-sonictemplate-a1acbaffbd086ceb1fe4625ebb4413cc6a898cab.tar.bz2 vim-sonictemplate-a1acbaffbd086ceb1fe4625ebb4413cc6a898cab.zip |
add perl stuff.
-rw-r--r-- | template/dbi-sqlite.pl | 1 | ||||
-rw-r--r-- | template/read-file.perl | 2 |
2 files changed, 3 insertions, 0 deletions
diff --git a/template/dbi-sqlite.pl b/template/dbi-sqlite.pl new file mode 100644 index 0000000..6f66987 --- /dev/null +++ b/template/dbi-sqlite.pl @@ -0,0 +1 @@ +my $dbh = DBI->connect("dbi:SQLite:dbname={{_cursor_}}"); diff --git a/template/read-file.perl b/template/read-file.perl new file mode 100644 index 0000000..53138a4 --- /dev/null +++ b/template/read-file.perl @@ -0,0 +1,2 @@ +open my $fh, '<', '{{_cursor}}' or die "failed to open: $!"; +my $content = do { local $/; <$fh> }; |