Giter Site home page Giter Site logo

sqlectron-core's Introduction

sqlectron-core

Build status

The common code used by all sqlectron clients.

Requires node 6 or higher.

Current supported databases

Do you want to support another SQL database? It is expected that in the pull request the new database is included in the db.spec.js.

Installation

Install via npm:

$ npm install sqlectron-core

Configuration

SQLECTRON keeps a hidden configuration file called .sqlectron.json at the user's home directory (~/ osx and linux; %userprofile% windows ).

Although you can change this file manually, most of time you should not worry about it because SQLECTRON will manage the configuration for you.

Example

{
  "resultItemsPerPage": 50,
  "limitQueryDefaultSelectTop": 100,
  "servers": [
    {
      "id": "c48890d8-5d87-4085-8b22-94981f8d522c",
      "name": "pg-vm-ssh",
      "client": "postgresql",
      "host": "localhost",
      "port": 5432,
      "user": "user",
      "password": "password",
      "database": "company",
      "ssh": {
        "host": "10.10.10.10",
        "port": 22,
        "privateKey": "~/.vagrant.d/insecure_private_key",
        "user": "core"
      }
    },
    {
      "id": "0f6536a1-c232-4515-942a-c0fb56d362b2",
      "name": "vm-ssh",
      "client": "mysql",
      "host": "localhost",
      "port": 3306,
      "user": "root",
      "password": "password",
      "database": "authentication"
    }
  ]
}

Fields

resultItemsPerPage

The limit of items per page (default on sqlectron-gui: 100) The paging is not done in SQL query. Instead its is done during the results rendering.

limitQueryDefaultSelectTop

The limit used in the default query (default: 1000)

servers

Array with all servers connection.

  • id: in case including a new server manually there is no need setting an id field because SQLECTRON will do it for you
  • name
  • client: postgresql, mysql or sqlserver
  • host
  • port
  • user
  • password
  • database
  • ssh
    • host
    • user
    • port
    • privateKey
    • privateKeyWithPassphrase

Contributing

It is required to use editorconfig and please write and run specs before pushing any changes.

with docker + docker-compose

It will bring up a MySQL and PostgreSQL database and run all the tests:

docker-compose run --rm test

"manually"

You will need to bring up all the databases then run the tests through:

npm test

License

Copyright (c) 2015 The SQLECTRON Team. This software is licensed under the MIT License.

sqlectron-core's People

Contributors

bornap avatar ckee83 avatar emerzh avatar kas avatar krolow avatar luisrudge avatar maxcnunes avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.