Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

prepare to publish

  • Loading branch information...
commit 2d476d1682e23d409b696a6eb697e05c7249ef5b 1 parent 0d71bc7
@kononencheg kononencheg authored
Showing with 6 additions and 28 deletions.
  1. +1 −3 .gitignore
  2. +1 −0  .npmignore
  3. +4 −2 Makefile
  4. +0 −23 benchmarks/example.js
View
4 .gitignore
@@ -1,8 +1,6 @@
-bin/*.o
-bin/*.node
+bin/
.idea/
.build/
*.iml
-build/
node_modules
View
1  .npmignore
@@ -2,4 +2,5 @@
.build/
bin/
.gitignore
+*.iml
View
6 Makefile
@@ -49,7 +49,7 @@ clean:
#
-native-build : pg.node
+native-build : setup-build-dir pg.node
pg.node : pg.o \
@@ -72,7 +72,7 @@ pg.node : pg.o \
#
-js-build : index.js
+js-build : setup-build-dir index.js
js-lint : $(shell cat src.d)
@@ -112,3 +112,5 @@ setup-linter :
[ $$? -eq 0 ] || sudo pip install -U http://closure-linter.googlecode.com/files/closure_linter-latest.tar.gz;
+setup-build-dir :
+ mkdir bin/
View
23 benchmarks/example.js
@@ -1,23 +0,0 @@
-var pg = require('../bin');
-var preparedQuery = "SELECT $word1 AS word1, $word2 AS word2";
-
-pg.init(20, {
- 'user': 'postgres',
- 'dbname': 'postgres',
- 'hostaddr': '127.0.0.1',
- 'password': '123'
-});
-
-pg.execPrepared(preparedQuery, {
- 'word1': 'hello',
- 'word2': 'world'
-}, function(table) {
- console.log('Result table:', table);
-}, console.error);
-
-pg.execPrepared(preparedQuery, {
- 'word1': 'bye',
- 'word2': 'bye'
-}, function(table) {
- console.log('Result table:', table);
-}, console.error);
Please sign in to comment.
Something went wrong with that request. Please try again.