Skip to content

v0.0.14

Compare
Choose a tag to compare
@joereynolds joereynolds released this 23 Jun 14:34
· 96 commits to typescript since this release

This version sees many updated and improvements made so let's dig in:

  • sql-lint now recurses over directories. A simple sql-lint . will
    lint all .sql files in your current directory
    NOTE: this will not work in the packaged executable. The pacakged executable
    is a snapshotted filesystem. Use the version from npm if you want this behaviour.
  • The --file and -f flag has been removed. Now you can specify it right
    away without a flag i.e. `sql-lint my-file.sql
  • The --query and -q flag has been removed. These were unneccessary and
    if you want to lint a fixed string, you can do so via the stdin i.e.
    `echo | 'DELETE FROM person;' | sql-lint
  • A new check for hungarian notation has been created. This will warn of
    any sp_ or tbl_ prefixes
  • Linting errors now carry extra information about them. If you want to
    see this information, pass the -v flag through on the command line
  • ALTER COLUMN statements now work for postgres users
  • The wording around a missing config file has been updated to give you
    better guidance
  • The warning about missing a config file will only show if -v is set
  • sql-lint will correctly fail if a file is not found that was specified
  • An extremely basic sql formatter is in place. Do not expect much
    you can experiment with it using the --fix flag

There are many other changes that can be glanced at through the commit
history but those are the main ones. As you can see, a lot of work has
been put in to make the CLI easier and more intuitive to use.