Giter VIP home page Giter VIP logo

sqruff's Introduction

sqruff

SQRUFF is an innovative SQL linter and formatter for modern development environments, written in Rust. Key features include:

  • Linting: Advanced, customizable SQL linting capabilities to ensure query quality.
  • Formatting: Automated, configurable formatting for SQL code consistency.
  • Portability: Designed to be easily integrated into various development workflows.

Getting Started

Installation

macOS

You can use brew to install sqruff easily on macOS.

brew install quarylabs/quary/sqruff

Linux

Using bash:

curl -fsSL https://raw.githubusercontent.com/quarylabs/sqruff/main/install.sh | bash

For other platforms

Either download the binary from the releases page or compile it yourself and with cargo with the following commands.

rustup override set nightly
cargo install sqruff
sqruff --help

Usage

Linting

To lint a SQL file or set of files, run the following command:

sqruff lint <file>
sqruff lint <file1> <file2> <file3>
sqruff lint <directory>

Fixing

To fix a single or or set of files, run the following command:

sqruff fix <file/paths/directory>

Help

To get help on the available commands and options, run the following command:

sqruff --help

Contributing

Contributions are welcome! See CONTRIBUTING.md for guidelines on how to contribute.

Releasing

  1. Bump the versions in sqruff-lib/Cargo.toml and sqruff/Cargo.toml.
  2. Commit the changes.
  3. Push the changes.
  4. Tag the commit with the new version
  5. Release sqruff-lib crate
cargo publish -p sqruff-lib
  1. Release sqruff crate
cargo publish -p sqruff

Community

Join the sqruff community on GitHub Discussions to ask questions, suggest features, or share your projects.

sqruff's People

Contributors

gvozdvmozgu avatar benfdking avatar louisjoecodes avatar dependabot[bot] avatar quied avatar tsirysndr avatar

Stargazers

Boyd Johnson avatar Luckas avatar tomoya_edzuka avatar Radek Tomšej avatar Max Natthawut Adulyanukosol avatar Jordi Rivero avatar  avatar Kevin Mingtarja avatar  avatar Jonathan Bowman avatar Denis Maciel avatar  avatar Matthew Fainman avatar trijuhari avatar Everet Rummel avatar Tuan Nguyen avatar Lucas Smith avatar Jonas avatar Ludwig Ostrowski avatar robin avatar earle avatar Luis Alberto avatar Darius Nicholson avatar Mahamadi NIKIEMA avatar Siddharth Sudhakar avatar Johnny Dang avatar baggiponte avatar Daniel Bartley avatar Can Özmen avatar Badreddine Lejmi avatar Guilhem de Viry avatar  avatar Seve Martinez avatar winnie avatar Shahadat Hossain avatar Oliver Tosky avatar  avatar AM avatar  avatar Lars Sjöberg avatar Nick Vazquez avatar Adrien Wald avatar Gabriel Stechschulte avatar Arjit Jain avatar Mohamad Hallak avatar Max Halford avatar Saulius Grigaliunas avatar Gaspard Charles avatar Hugh Cameron avatar Sergi de Pablos avatar Georvic Tur avatar ben8t avatar Leonardo Natale avatar Joon Kang avatar Guillaume Le Floch avatar Evgeny Postnov avatar PJGaetan avatar  avatar Hugo VASSELIN avatar Lubomir Anastasov avatar Wesley Moore avatar Dat Nguyen avatar Charles Kornoelje avatar Cory Grinstead avatar Sung Won Chung avatar Lucel Da Silva avatar Muhammad Jarir Kanji avatar Matthew Aylward  avatar M Lincon avatar  avatar  avatar Lukas Welsch avatar Thomas avatar  avatar Jared Noynaert avatar Ajith Aravind avatar Umur Cubukcu avatar Adrian A avatar Chinmay Pramod Bharti avatar Pasquale Antonante avatar David Hu avatar  avatar  avatar Tim Vergenz avatar  avatar Zsombor Foldesi avatar sonny avatar Jimmy Shah avatar  avatar

Watchers

 avatar earle avatar  avatar

sqruff's Issues

Add Cargo.lock file

Given that we are deploying a CLI, I think for it to be deterministic we should include a lockfile

Brew - download link is broken

Hi,

The download URL is not correct:

haithem@dbt-ultimile % brew install quarylabs/quary/sqruff
==> Fetching quarylabs/quary/sqruff
==> Downloading https://github.com/quarylabs/quary/releases/download/0.0.6/sqruff-darwin-aarch64.tar.gz
curl: (22) The requested URL returned error: 404

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.