Permalink
Commits on Mar 31, 2016
  1. Fix CLI connection to the postgres database

    mcasper committed Mar 31, 2016
    We connect to the postgres database to create/drop databases, but when
    the user supplied a username and password, we would connect to
    postgres://user:pass@localhost, which psql assumes means you also want
    to connect to the `user` database. So, now we are always explicit about
    what database we're connecting to.
Commits on Mar 23, 2016
  1. Merge pull request #242 from mcasper/bump_syntex

    mcasper committed Mar 23, 2016
    Bump syntex and syntex_syntax to 0.30.0
Commits on Mar 21, 2016
  1. Merge pull request #236 from mcasper/error_handling

    mcasper committed Mar 21, 2016
    Print error and exit 1 instead of panicking in CLI
Commits on Mar 14, 2016
  1. Go back to printing errors and then exiting 1

    mcasper committed Mar 13, 2016
    This was removed earlier because if a diesel_cli test started failing,
    it would abort the entire test suite because it exited with a status
    code of 1, which rust interprets as a problem. Now, because we shell out
    all our tests that ever hit this part of the code, we can go back to
    printing errors and exiting 1. This presentation is much nicer than a
    panic.
Commits on Mar 4, 2016
  1. Merge pull request #221 from benaryorg/patch-1

    mcasper committed Mar 4, 2016
    documentation fix of function `diesel::update`
  2. Merge pull request #223 from mcasper/remove_unnecessary_unit_tests

    mcasper committed Mar 4, 2016
    Remove database tests and replace with integration tests
Commits on Mar 3, 2016
  1. Merge pull request #230 from SoftwareWarlock/remove_strip_prefix

    mcasper committed Mar 3, 2016
    Removed internal copy of Path#strip_prefix
Commits on Feb 20, 2016
  1. Remove database tests and replace with integration tests

    mcasper committed Feb 20, 2016
    These database tests aren't providing much more than our integrations
    tests are now, and the integration tests have a much cleaner and nicer
    test structure to run in, so there doesn't seem like much of a point in
    keeping these around. All removed tests have a mirror test or assertion
    in the integration test suite, and the one lacking has been added.
Commits on Feb 18, 2016
  1. Merge pull request #216 from mcasper/fix_subcommand_descriptions

    mcasper committed Feb 18, 2016
    Fix `diesel database setup` help, and specify subgroup help messages
  2. Merge pull request #214 from mcasper/fix_sqlite_output

    mcasper committed Feb 18, 2016
    Fix create_database_if_needed output
  3. Remove dead CLI test now that we have integration tests

    mcasper committed Feb 18, 2016
    I don't feel that this test provides anything more than the current
    integration tests provide, so my vote is to just remove this.
  4. Fix create_database_if_needed output.

    mcasper committed Feb 16, 2016
    We should only notify that we're creating a database when we actually
    are. Sqlite has always been missing this, and it seems to have been
    introduced to Postgres unintentionally.
  5. Merge pull request #213 from mcasper/more_cli_integration_tests

    mcasper committed Feb 18, 2016
    Add more CLI integration tests
Commits on Feb 11, 2016
  1. `diesel migration generate` shouldn't require a DATABASE_URL to be set

    mcasper committed Feb 11, 2016
    This got inadvertently introduced in my SQLite support branch. Even
    though pretty much every command after this one requires a DATABASE_URL,
    I think it's unintuitive to require one here (and wasn't the previous
    use case).
Commits on Feb 4, 2016
  1. Merge pull request #189 from mcasper/sqlite_support_for_cli

    mcasper committed Feb 4, 2016
    Implement Sqlite support for the CLI.
  2. Implement Sqlite support for the CLI.

    mcasper committed Feb 4, 2016
    Because `Connection` isn't object safe (and probably shouldn't be),
    switching based on the desired backend had to be achieved through
    branching, handled with a macro wherever possible. This will obviously
    grow more and more burdensome as more backends are added, and a better
    solution will have to be figured out in the future.
    
    I also split out database related functions into their own module, as it
    was starting to feel like too much to juggle in one file.
    
    The tests in the `database` mod each use their own database, as for many
    of them we're dropping and creating the database, which can't be wrapped
    in a transaction. Using a separate database for each allows us to still
    run the tests multi threaded, but does add the extra cost of some setup
    and teardown in the code.
    
    The Sqlite portions don't use the `temdir` crate for generating their
    database path because I couldn't figure out an ergonomic way of keeping
    the tests able to run for both backends, while keeping the TempDir in
    scope (returning a path from a function causes the TempDir to go out of
    scope, which removes the directory in its destructor).
Commits on Feb 1, 2016
  1. Display generated migration paths as relative for diesel CLI

    mcasper committed Feb 1, 2016
  2. Allow the user to set the DATABASE_URL through dotenv

    mcasper committed Jan 31, 2016
    This allows the user to set their DATABASE_URL for the diesel CLI in
    their `.env` file.
    
    I also took the chance to bump the dotenv version.
  3. Merge pull request #161 from mcasper/diesel_cli_reset

    mcasper committed Feb 1, 2016
    Implement `diesel database reset`
  4. Implement `diesel database reset`, and move `diesel setup` to `diesel

    mcasper committed Jan 30, 2016
    database setup`
    
    This has a lot of changes because it does a few things at the same time:
    * Changed most functions to take a generic Connection. This gets us a
    little closer to making the CLI generic over the backend, and allows for
    easier testing, as it gives us control over the connection it uses.
    
    * Document more functions and add some messages to the user when
    running setup/reset.
    
    * Add the `diesel database reset` command, and move `diesel setup` to be
    a subcommand of `diesel database`.
Commits on Jan 24, 2016
  1. Merge pull request #136 from mcasper/fix_cli_tests

    mcasper committed Jan 24, 2016
    Fix diesel_cli test race condition by using a transaction
  2. Fix diesel_cli test race condition by using a transaction.

    mcasper committed Jan 24, 2016
    Also add semi-colons to the querys, _just in case_
  3. Merge pull request #126 from mcasper/diesel_cli_setup

    mcasper committed Jan 24, 2016
    Implement `diesel setup` for diesel CLI
Commits on Jan 18, 2016
  1. Merge pull request #112 from mcasper/readme_tweaks

    mcasper committed Jan 18, 2016
    Clean up old stuff in the README
  2. Merge pull request #103 from mcasper/fix_foreign_key_inference

    mcasper committed Jan 18, 2016
    Fix foreign key and module inference for multi word structs
Commits on Jan 17, 2016
Commits on Jan 11, 2016
  1. Remove DATABASE_URL_FOR_SCHEMA from .travis.yml

    mcasper committed Jan 11, 2016
    This env var doesn't seem to be used in tests anymore, so we shouldn't
    need it in travis.
Commits on Jan 1, 2016