github.com/taubyte/tau-cli@v0.1.13-0.20240326000942-487f0d57edfc/README.md (about) 1 <h2 align="center"> 2 <a href="https://taubyte.com" target="_blank" rel="noopener noreferrer"> 3 <picture> 4 <source media="(prefers-color-scheme: dark)" srcset="images/tau-cli-logo-box-v2.png"> 5 <img width="80" src="images/tau-cli-logo-box-v2.png" alt="Tau CLI"> 6 </picture> 7 </a> 8 <br /> 9 Tau CLI 10 11 ***Local Coding Equals Global Production*** 12 </h2> 13 <div align="center"> 14 15 [![Release](https://img.shields.io/github/release/taubyte/tau-cli.svg)](https://github.com/taubyte/tau-cli/releases) 16 [![License](https://img.shields.io/github/license/taubyte/tau-cli)](LICENSE) 17 [![Go Report Card](https://goreportcard.com/badge/taubyte/tau-cli)](https://goreportcard.com/report/taubyte/tau-cli) 18 [![GoDoc](https://godoc.org/github.com/taubyte/tau-cli?status.svg)](https://pkg.go.dev/github.com/taubyte/tau-cli) 19 [![Discord](https://img.shields.io/discord/973677117722202152?color=%235865f2&label=discord)](https://discord.gg/wM8mdskh) 20 21 </div> 22 23 `tau` is a command-line interface (CLI) tool for interacting with [Taubyte-based Clouds](https://github.com/taubyte). It enables users to create, manage projects, applications, resources, and more directly from the terminal. 24 25 26 ## Installation 27 28 ### NPM 29 ```bash 30 npm i @taubyte/cli 31 ``` 32 33 ### Self extracting 34 ``` 35 curl https://get.tau.link/cli | sh 36 ``` 37 38 ### Fetch and Install with Go 39 ```shell 40 go install github.com/taubyte/tau-cli@latest 41 ``` 42 You can rename `tau-cli` to `tau` or create an alias. 43 44 ### Clone and Build 45 ```shell 46 git clone https://github.com/taubyte/tau-cli 47 cd tau 48 go build -o ~/go/bin/tau 49 ``` 50 51 ### Offline version (Optional) 52 Fails faster if exploring an unregistered project 53 ```shell 54 go build -o ~/go/bin/otau -tags=localAuthClient 55 ``` 56 57 ## Login 58 59 `tau login` 60 - opens selection with default already selected 61 - simply logs in if only default available 62 - will open new if no profiles found 63 `tau login --new` for new 64 - `--set-default` for making this new auth the default 65 `tau login <profile-name>` for using a specific profile 66 67 68 ## Environment Variables: 69 - `TAUBYTE_PROJECT` Selected project 70 - `TAUBYTE_PROFILE` Selected profile 71 - `TAUBYTE_APPLICATION` Selected application 72 - `TAUBYTE_CONFIG (default: ~/tau.yaml)` Config location 73 - `TAUBYTE_SESSION (default: /tmp/tau-<shell-pid>)` Session location 74 - `DREAM_BINARY (default: $GOPATH/dream)` Dream binary location 75 76 ## Testing 77 78 ### All tests 79 `go test -v ./...` 80 81 ### Hot reload tests 82 `$ cd tests` 83 84 Edit [air config](tests/.air.toml#L8) `cmd = "go test -v --run <Function|Database|...> [-tags=no_rebuild]` 85 86 (Optional) Add `debug: true,` to an individual test 87 88 `$ air` 89 90 ## Running Individual Prompts 91 92 `go run ./prompts/internal` 93 94 ## Measuring Coverage: 95 96 ### Calculate coverage for all packages 97 ```shell 98 go test -v ./... -tags=localAuthClient,projectCreateable,localPatrick,cover,noPrompt -coverprofile cover.out -coverpkg ./... 99 ``` 100 101 ### Display coverage for all packages 102 ``` 103 go tool cover -html=cover.out 104 go tool cover -func=cover.out 105 ``` 106 107 # Documentation 108 For documentation head to [tau.how](https://tau.how/docs/tau)