Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue-189 : Allow connecting to bookmarked server from CLI #201

Merged
merged 8 commits into from
Nov 16, 2016

Commits on Nov 11, 2016

  1. Add method that returns if bookmark's ssh is empty

    We will use this method in upcoming commit to create
    client from stored bookmark.
    akarki15 committed Nov 11, 2016
    Configuration menu
    Copy the full SHA
    f4fb574 View commit details
    Browse the repository at this point in the history
  2. Add a func to read bookmark from stored toml file

    Given a bookmark path and bookmark name, GetBookmark
    returns a Bookmark object that corresponds to the
    stored bookmark settings.
    
    In next commits, we will use this method to read
    stored bookmarks and create a db client.
    akarki15 committed Nov 11, 2016
    Configuration menu
    Copy the full SHA
    0e88e3e View commit details
    Browse the repository at this point in the history
  3. Set the type of Bookmark.Port to int

    We know that a port is a number. Lets enforce that
    rule at type level by setting it so.
    
    This commit also adjusts test funcs and helper data
    to fit Port's new int type.
    akarki15 committed Nov 11, 2016
    Configuration menu
    Copy the full SHA
    038cb62 View commit details
    Browse the repository at this point in the history
  4. Add a method to convert bookmark to options

    We will use client.NewFromURL to create a client
    from stored bookmark in next commit. Since
    client.NewFromURL takes in a command.Options, lets
    add a method on Bookmark to get corresponding Option.
    akarki15 committed Nov 11, 2016
    Configuration menu
    Copy the full SHA
    61dfe67 View commit details
    Browse the repository at this point in the history
  5. initClient uses bookmark if it exists

    if options.Bookmark is set, initClient will now use
    it to create a client from the bookmarked settings.
    
    initClientUsingBookmark uses methods introduced in
    previous commits. It constructs connection string
    to db from Bookmark.Url if it exists. If not, it
    uses other fields in Bookmark to construct the
    connection string. An implication of this is that
    the Url field of Bookmark takes precedence.
    akarki15 committed Nov 11, 2016
    Configuration menu
    Copy the full SHA
    1b4902f View commit details
    Browse the repository at this point in the history

Commits on Nov 12, 2016

  1. Use generic typed error pattern

    The codebase doesn't yet use the explicitly typed error pattern. To keep
    things consistent, lets use the generic error type.
    akarki15 committed Nov 12, 2016
    Configuration menu
    Copy the full SHA
    68db934 View commit details
    Browse the repository at this point in the history
  2. Make assets.

    akarki15 committed Nov 12, 2016
    Configuration menu
    Copy the full SHA
    b1fdbf7 View commit details
    Browse the repository at this point in the history

Commits on Nov 16, 2016

  1. Remove error return value from ConvertToOptions

    ConvertToOptions can't return any error.
    akarki15 committed Nov 16, 2016
    Configuration menu
    Copy the full SHA
    fedde80 View commit details
    Browse the repository at this point in the history