diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index eb455fd..5b7dcc0 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -65,7 +65,7 @@ jobs: # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash - run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.21.1/cargo-dist-installer.sh | sh" + run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.22.1/cargo-dist-installer.sh | sh" - name: Cache cargo-dist uses: actions/upload-artifact@v4 with: @@ -307,6 +307,11 @@ jobs: name=$(echo "$filename" | sed "s/\.rb$//") version=$(echo "$release" | jq .app_version --raw-output) + export PATH="/home/linuxbrew/.linuxbrew/bin:$PATH" + brew update + # We avoid reformatting user-provided data such as the app description and homepage. + brew style --except-cops FormulaAudit/Homepage,FormulaAudit/Desc,FormulaAuditStrict --fix "Formula/${filename}" || true + git add "Formula/${filename}" git commit -m "${name} ${version}" done diff --git a/Cargo.lock b/Cargo.lock index b1ea9ac..3caa802 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -233,7 +233,7 @@ dependencies = [ [[package]] name = "tbll" -version = "0.2.0" +version = "0.2.1" dependencies = [ "clap", "tabled", diff --git a/Cargo.toml b/Cargo.toml index 2cbb940..1fddcd7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,10 +1,19 @@ [package] name = "tbll" -version = "0.2.0" +version = "0.2.1" edition = "2021" repository = "https://github.com/dhth/tbll" description = "tbll outputs data in tabular format" homepage = "https://github.com/dhth/tbll" +license-file = "LICENSE" +keywords = [ + "cli", + "table", +] +categories = [ + "command-line-utilities", + "text-processing" +] [dependencies] clap = { version = "4.5.18", features = ["derive"] } @@ -18,7 +27,7 @@ lto = "thin" # Config for 'cargo dist' [workspace.metadata.dist] # The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax) -cargo-dist-version = "0.21.1" +cargo-dist-version = "0.22.1" # CI backends to support ci = "github" # The installers to generate for each app diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..1159e75 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Dhruv Thakur + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md index 720d6d4..0b7604d 100644 --- a/README.md +++ b/README.md @@ -5,6 +5,30 @@ `tbll` outputs data in tabular format. +```bash +cat << EOF | tbll -s --headers 'Movie,Year,Director,Genre' +The Matrix,1999,Lana & Lilly Wachowski,Science Fiction +Fight Club,1999,David Fincher,Drama +Pulp Fiction,1994,Quentin Tarantino,Crime +The Shawshank Redemption,1994,Frank Darabont,Drama +Jurassic Park,1993,Steven Spielberg,Adventure +Forrest Gump,1994,Robert Zemeckis,Drama +EOF +``` + +```text +┌──────────────────────────┬──────┬────────────────────────┬─────────────────┐ +│ Movie │ Year │ Director │ Genre │ +├──────────────────────────┼──────┼────────────────────────┼─────────────────┤ +│ The Matrix │ 1999 │ Lana & Lilly Wachowski │ Science Fiction │ +│ Fight Club │ 1999 │ David Fincher │ Drama │ +│ Pulp Fiction │ 1994 │ Quentin Tarantino │ Crime │ +│ The Shawshank Redemption │ 1994 │ Frank Darabont │ Drama │ +│ Jurassic Park │ 1993 │ Steven Spielberg │ Adventure │ +│ Forrest Gump │ 1994 │ Robert Zemeckis │ Drama │ +└──────────────────────────┴──────┴────────────────────────┴─────────────────┘ +``` + 💾 Installation --- @@ -17,11 +41,13 @@ brew install dhth/tap/tbll **cargo**: ```sh +cargo install tbll cargo install --git https://github.com/dhth/tbll.git ``` -Or get the binaries directly from a [release][1]. Read more about verifying the -authenticity of released artifacts [here](#-verifying-release-artifacts). +Or get the binaries directly from a Github [release][1]. Read more about +verifying the authenticity of released artifacts +[here](#-verifying-release-artifacts). ⚡️ Usage --- @@ -47,30 +73,6 @@ Options: ### Basic Usage -```bash -cat << EOF | tbll -s --headers 'Movie,Year,Director,Genre' -The Matrix,1999,Lana & Lilly Wachowski,Science Fiction -Fight Club,1999,David Fincher,Drama -Pulp Fiction,1994,Quentin Tarantino,Crime -The Shawshank Redemption,1994,Frank Darabont,Drama -Jurassic Park,1993,Steven Spielberg,Adventure -Forrest Gump,1994,Robert Zemeckis,Drama -EOF -``` - -```text -┌──────────────────────────┬──────┬────────────────────────┬─────────────────┐ -│ Movie │ Year │ Director │ Genre │ -├──────────────────────────┼──────┼────────────────────────┼─────────────────┤ -│ The Matrix │ 1999 │ Lana & Lilly Wachowski │ Science Fiction │ -│ Fight Club │ 1999 │ David Fincher │ Drama │ -│ Pulp Fiction │ 1994 │ Quentin Tarantino │ Crime │ -│ The Shawshank Redemption │ 1994 │ Frank Darabont │ Drama │ -│ Jurassic Park │ 1993 │ Steven Spielberg │ Adventure │ -│ Forrest Gump │ 1994 │ Robert Zemeckis │ Drama │ -└──────────────────────────┴──────┴────────────────────────┴─────────────────┘ -``` - ```bash cat <