https://github.com/sandwichlabs/duck-tape
A little tool for sql from the cli. Swiss army knife of data scripts, powered by duckdb.
https://github.com/sandwichlabs/duck-tape
cli postgresql sql tools
Last synced: 4 months ago
JSON representation
A little tool for sql from the cli. Swiss army knife of data scripts, powered by duckdb.
- Host: GitHub
- URL: https://github.com/sandwichlabs/duck-tape
- Owner: SandwichLabs
- License: mit
- Created: 2024-05-30T12:48:11.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2025-05-02T13:05:58.000Z (about 1 year ago)
- Last Synced: 2025-05-13T13:15:00.525Z (about 1 year ago)
- Topics: cli, postgresql, sql, tools
- Language: Go
- Homepage: https://github.com/SandwichLabs/duck-tape
- Size: 89.8 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: Readme.md
- License: LICENSE
Awesome Lists containing this project
README
# Duck Tape (dt)
[](https://choosealicense.com/licenses/mit/)[](https://github.com/zorndorff/duck-tape/actions/workflows/lint.dt.yaml)
Curl for databases, give your terminal sql super powers.
> Note This is extremely early in development and is not ready for production use.
## Installation
Prebuilt binaries are available from the [releases page](https://github.com/zorndorff/duck-tape/releases). You can also install the latest version from source using the following command:
```bash
git clone git@github.com:SandwichLabs/duck-tape.git
cd duck-tape
go build .
sudo mv dt /usr/local/bin/
```
## Usage
```bash
dt -h # Show help
dt init # Initialize your local dt config file
dt q "SELECT * FROM 1=1" # Run a query on the default local db
dt create connection # Follow the interactive prompts to create a new connection
dt query "SELECT * FROM connection_name.some_table" -c # Run a query on a specific connection
```
## Todo
**Database Support**
- [x] MySQL
- [x] Postgres
- [x] DuckDB
- [x] SQLite
**File Support**
- [x] CSV
- [x] JSON
- [x] Parquet
**Features**
- [x] Query Results to JSON
- [x] Query Results to File - Needs documentation
- [ ] Query Results to CSV
- [ ] Save Query aliases to config
- [ ] Interactive Query Builder?