From 1f4058df4028b41db4035d51af15d73ddf69b785 Mon Sep 17 00:00:00 2001 From: fabriciojs Date: Sat, 3 Dec 2022 15:58:55 -0300 Subject: [PATCH 1/8] build minor tweak --- .gitignore | 1 + kool.yml | 5 ++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 5602d644..e42d2686 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ /kool +/kool-cli /dist/ /.env Output/ diff --git a/kool.yml b/kool.yml index 22612f69..b797ada7 100644 --- a/kool.yml +++ b/kool.yml @@ -12,9 +12,8 @@ scripts: # file properly setting GOOS=darwin so you will be able to use the binary. compile: - kool run fmt - - kool run go build -o kool - install: - - mv kool /usr/local/bin/kool + - kool run go build -o kool-cli + install: mv ./kool-cli /usr/local/bin/kool fmt: kool run go:linux fmt ./... lint: kool docker --volume=kool_gopath:/go golangci/golangci-lint:v1.47.3 golangci-lint run -v test: kool run test:path ./... From 9e5e1564628039aa2abce5156ed0ef5d7c6e4d53 Mon Sep 17 00:00:00 2001 From: fabriciojs Date: Sat, 3 Dec 2022 15:59:26 -0300 Subject: [PATCH 2/8] Add working_dir global option --- commands/root.go | 47 +++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 45 insertions(+), 2 deletions(-) diff --git a/commands/root.go b/commands/root.go index 25da7eaf..1c17b9c3 100644 --- a/commands/root.go +++ b/commands/root.go @@ -6,7 +6,9 @@ import ( "kool-dev/kool/core/environment" "kool-dev/kool/core/parser" "kool-dev/kool/core/shell" + "os" "path" + "path/filepath" "strings" "github.com/spf13/cobra" @@ -47,6 +49,8 @@ var version string = DEV_VERSION var rootCmd = NewRootCmd(environment.NewEnvStorage()) +var originalWorkingDir = "" + func init() { AddCommands(rootCmd) } @@ -67,7 +71,7 @@ Complete documentation is available at https://kool.dev/docs`, Version: version, DisableAutoGenTag: true, DisableFlagsInUseLine: true, - PersistentPreRun: func(cmd *cobra.Command, args []string) { + PersistentPreRunE: func(cmd *cobra.Command, args []string) (err error) { if verbose := cmd.Flags().Lookup("verbose"); verbose != nil && verbose.Value.String() == "true" { env.Set("KOOL_VERBOSE", verbose.Value.String()) } @@ -76,6 +80,44 @@ Complete documentation is available at https://kool.dev/docs`, shell.NewShell().Warning("Warning: you are executing a development version of kool.") hasWarnedDevelopmentVersion = true } + + workDirFlag := cmd.Flags().Lookup("working_dir") + if workDirFlag != nil && workDirFlag.Value.String() != "" { + workDir := workDirFlag.Value.String() + + if originalWorkingDir != "" { + // having an original working dir set means we have + // already changed the working dir before and we are in + // a recursive kool call. We need to restore the original + // working dir before changing it again. + if err = os.Chdir(originalWorkingDir); err != nil { + return + } + } + + if !path.IsAbs(workDir) { + if workDir, err = filepath.Abs(workDir); err != nil { + return + } + } + + if err = os.Chdir(workDir); err != nil { + return + } + + if originalWorkingDir == "" { + // we only set the original working dir if it is not set + // yet. This is to avoid overriding the original working + // dir in recursive calls. + if originalWorkingDir, err = os.Getwd(); err != nil { + return + } + } + + environment.NewEnvStorage().Set("PWD", workDir) + } + + return }, RunE: func(cmd *cobra.Command, args []string) (err error) { if len(args) == 0 { @@ -106,7 +148,8 @@ Complete documentation is available at https://kool.dev/docs`, }, } - cmd.PersistentFlags().Bool("verbose", false, "increases output verbosity") + cmd.PersistentFlags().Bool("verbose", false, "Increases output verbosity") + cmd.PersistentFlags().StringP("working_dir", "w", "", "Changes the working directory for the command") return } From 1a3ca734970e024fd64a0431b2edbc6a411218ab Mon Sep 17 00:00:00 2001 From: fabriciojs Date: Sat, 3 Dec 2022 15:59:58 -0300 Subject: [PATCH 3/8] enable running kool.yml commands right in the preset after creation --- commands/create.go | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/commands/create.go b/commands/create.go index 427f6b5f..c3c8a332 100644 --- a/commands/create.go +++ b/commands/create.go @@ -5,6 +5,8 @@ import ( "kool-dev/kool/core/environment" "kool-dev/kool/core/presets" "os" + "path" + "path/filepath" "github.com/spf13/cobra" ) @@ -59,10 +61,18 @@ func (c *KoolCreate) Execute(args []string) (err error) { c.Shell().Println("Initializing", preset, "preset...") + if !path.IsAbs(createDirectory) { + if createDirectory, err = filepath.Abs(createDirectory); err != nil { + return + } + } + if err = os.Chdir(createDirectory); err != nil { return } + c.env.Set("PWD", createDirectory) + if err = c.parser.Install(preset, c.Shell()); err != nil { return } From e29b1ed5f726032e170627c66432104dbd51bb42 Mon Sep 17 00:00:00 2001 From: fabriciojs Date: Sat, 3 Dec 2022 16:00:19 -0300 Subject: [PATCH 4/8] Add Laravel Octane preset with Swoole --- presets/laravel+octane/config.yml | 36 +++++++++++++++++++++++++++ presets/laravel+octane/vite.config.js | 15 +++++++++++ presets/laravel/vite.config.js | 2 +- recipes/php-8.1-swoole.yml | 3 +++ templates/app/php81-swoole.yml | 14 +++++++++++ 5 files changed, 69 insertions(+), 1 deletion(-) create mode 100644 presets/laravel+octane/config.yml create mode 100644 presets/laravel+octane/vite.config.js create mode 100644 recipes/php-8.1-swoole.yml create mode 100644 templates/app/php81-swoole.yml diff --git a/presets/laravel+octane/config.yml b/presets/laravel+octane/config.yml new file mode 100644 index 00000000..3e7db3e4 --- /dev/null +++ b/presets/laravel+octane/config.yml @@ -0,0 +1,36 @@ +# Which tags are related to this preset; used for branching the choices on preset wizard +tags: [ 'PHP' ] + +# Create defines the workflow for creating a new Project where this preset can then be installed +create: + - name: Creating new Laravel Application with Octane powered by Swoole + actions: + - scripts: + - docker pull -q kooldev/php:8.1-nginx-swoole + - kool docker kooldev/php:8.1-nginx-swoole composer create-project --no-install --no-scripts --prefer-dist laravel/laravel $CREATE_DIRECTORY + +# Preset defines the workflow for installing this preset in the current working directory +preset: + - name: 'Copy basic config files' + actions: + - copy: docker-compose.yml + - copy: kool.yml + - copy: vite.config.js + - merge: scripts/laravel.yml + dst: kool.yml + + - name: 'Set up Laravel Octane' + actions: + - recipe: php-8.1-swoole + - scripts: + - kool docker kooldev/php:8.1-nginx-swoole composer install + - kool docker kooldev/php:8.1-nginx-swoole composer require laravel/octane + - kool docker kooldev/bash -c "cp .env.example .env" + - kool docker kooldev/php:8.1-nginx-swoole php artisan key:generate + - kool docker kooldev/php:8.1-nginx-swoole php artisan octane:install --server=swoole + + - name: 'Customize your setup' + actions: + - recipe: pick-db + - recipe: pick-cache + - recipe: pick-laravel-node diff --git a/presets/laravel+octane/vite.config.js b/presets/laravel+octane/vite.config.js new file mode 100644 index 00000000..d2214328 --- /dev/null +++ b/presets/laravel+octane/vite.config.js @@ -0,0 +1,15 @@ +import { defineConfig } from 'vite'; +import laravel from 'laravel-vite-plugin'; + +export default defineConfig({ + plugins: [ + laravel({ + input: ['resources/css/app.css', 'resources/js/app.js'], + refresh: true, + }), + ], + server: { + host: '0.0.0.0', + port: 3001, + }, +}); diff --git a/presets/laravel/vite.config.js b/presets/laravel/vite.config.js index 4ec23129..d2214328 100644 --- a/presets/laravel/vite.config.js +++ b/presets/laravel/vite.config.js @@ -8,7 +8,7 @@ export default defineConfig({ refresh: true, }), ], - server: { + server: { host: '0.0.0.0', port: 3001, }, diff --git a/recipes/php-8.1-swoole.yml b/recipes/php-8.1-swoole.yml new file mode 100644 index 00000000..ef92cd78 --- /dev/null +++ b/recipes/php-8.1-swoole.yml @@ -0,0 +1,3 @@ +actions: + - merge: app/php81-swoole.yml + dst: docker-compose.yml diff --git a/templates/app/php81-swoole.yml b/templates/app/php81-swoole.yml new file mode 100644 index 00000000..b171abfb --- /dev/null +++ b/templates/app/php81-swoole.yml @@ -0,0 +1,14 @@ +services: + app: + image: kooldev/php:8.1-nginx-swoole + command: php artisan octane:start --server=swoole --host=0.0.0.0 --port=80 + ports: + - "${KOOL_APP_PORT:-80}:80" + environment: + ASUSER: "${KOOL_ASUSER:-0}" + UID: "${UID:-0}" + volumes: + - .:/app:delegated + networks: + - kool_local + - kool_global From 198bdf0cf8a3f1e9802d0ef0b098e3c410e4685f Mon Sep 17 00:00:00 2001 From: fabriciojs Date: Sun, 4 Dec 2022 21:32:17 -0300 Subject: [PATCH 5/8] add docs for Laravel Octane --- docs/2-Presets/Laravel+Octane.md | 222 ++++++++++++++++++++++++++++++ docs/2-Presets/Laravel.md | 2 +- presets/laravel+octane/config.yml | 2 + 3 files changed, 225 insertions(+), 1 deletion(-) create mode 100644 docs/2-Presets/Laravel+Octane.md diff --git a/docs/2-Presets/Laravel+Octane.md b/docs/2-Presets/Laravel+Octane.md new file mode 100644 index 00000000..0c4d06aa --- /dev/null +++ b/docs/2-Presets/Laravel+Octane.md @@ -0,0 +1,222 @@ +# Start a Laravel Octane Project with Docker in 3 Easy Steps + +1. Run `kool create laravel+octane my-project` +2. Update **.env.example** +3. Run `kool run setup` + +> Yes, using **kool** + Docker to create and work on new Laravel Octane projects is that easy! + +## Requirements + +If you haven't done so already, you first need to [install Docker and the kool CLI](/docs/getting-started/installation). + +Also, make sure you're running the latest version of **kool**. Run the following command to compare your local version of **kool** with the latest release, and, if a newer version is available, automatically download and install it. + +```bash +$ kool self-update +``` + +> Please note that it helps to have a basic understanding of how Docker and Docker Compose work to use Kool with Docker. + +## 1. Run `kool create laravel+octane my-project` + +Use the [`kool create PRESET FOLDER` command](/docs/commands/kool-create) to create your new Laravel Octane project: + +```bash +$ kool create laravel+octane my-project +``` + +Under the hood, this command will run do the same as the standar Laravel preset to get a fresh install of latest Laravel using a customized **kool** Docker image with Swoole: kooldev/php:8.1-nginx-swoole. + +After installing Laravel, `kool create` automatically requires `laravel/octane` and runs `artisan octane:install`. After that you will have the options for including a database or cache service, all of which helps you easily set up the initial tech stack for your project using an interactive wizard. + +--- + +Now, move into your new Laravel Octane with Swoole project: + +```bash +$ cd my-project +``` + +The [`kool preset` command](/docs/commands/kool-preset) auto-generated the following configuration files and added them to your project, which you can modify and extend. + +```bash ++docker-compose.yml ++kool.yml +``` + +> Now's a good time to review the **docker-compose.yml** file and verify the services match the choices you made earlier using the wizard. + +## 2. Update .env.example + +You need to update some default values in Laravel's **.env.example** file to match the services in your **docker-compose.yml** file. + +### Database Services + +MySQL 5.7 and 8.0 or MariaDB 10.5 + +```diff +-DB_HOST=127.0.0.1 ++DB_HOST=database +``` + +PostgreSQL 13.0 + +```diff +-DB_CONNECTION=mysql ++DB_CONNECTION=pgsql + +-DB_HOST=127.0.0.1 ++DB_HOST=database + +-DB_PORT=3306 ++DB_PORT=5432 +``` + +> In order to avoid permission issues with mysql and mariaDB, add a user other than root and a password to your **.env.example** file + +```diff +-DB_USERNAME=root ++DB_USERNAME= + +-DB_PASSWORD= ++DB_PASSWORD= +``` + +### Cache Services + +Redis + +```diff +-REDIS_HOST=127.0.0.1 ++REDIS_HOST=cache +``` + +Memcached + +```diff +-MEMCACHED_HOST=127.0.0.1 ++MEMCACHED_HOST=cache +``` + +## 3. Run `kool run setup` + +> Say hello to **kool.yml**, say goodbye to custom shell scripts! + +As mentioned above, the [`kool preset` command](/docs/commands/kool-preset) added a **kool.yml** file to your project. Think of **kool.yml** as a super easy-to-use task _helper_. Instead of writing custom shell scripts, add your own scripts to **kool.yml** (under the `scripts` key), and run them with `kool run SCRIPT` (e.g. `kool run artisan`). You can add your own single line commands (see `composer` below), or add a list of commands that will be executed in sequence (see `setup` below). + +To help get you started, **kool.yml** comes prebuilt with an initial set of scripts (based on the choices you made earlier using the **preset** wizard), including a script called `setup`, which helps you spin up a project for the first time. + +```yaml +scripts: + artisan: kool exec app php artisan + composer: kool exec app composer + mysql: kool exec -e MYSQL_PWD=$DB_PASSWORD database mysql -uroot + node: kool docker kooldev/node:16 node + npm: kool docker kooldev/node:16 npm # or yarn + npx: kool exec app npx + + setup: + - kool run before-start + - kool start + - kool run composer install + - kool run artisan key:generate + + reset: + - kool run composer install + - kool run artisan migrate:fresh --seed + - kool run yarn install + + before-start: + - kool docker kooldev/bash -c "cp .env.example .env" + - kool run yarn install +``` + +Go ahead and run `kool run setup` to start your Docker environment and finish setting up your project: + +```bash +# CAUTION: this script will reset your `.env` file with `.env.example` +$ kool run setup +``` + +> As you can see in **kool.yml**, the `setup` script will do the following in sequence: copy your updated **.env.example** file to **.env**; start your Docker environment; use Composer to install vendor dependencies; generate your `APP_KEY` (in `.env`); and then build your Node packages and assets. + +Once `kool run setup` finishes, you should be able to access your new site at [http://localhost](http://localhost) and see the Laravel welcome page. Hooray! + +Verify your Docker container is running using the [`kool status` command](/docs/commands/kool-status). + +Run `kool logs app` to see the logs from the running `app` container. + +> Use `kool logs` to see the logs from all running containers. Add the `-f` option after `kool logs` to follow the logs (i.e. `kool logs -f app`). + +--- + +### Run Commands in Docker Containers + +Use [`kool exec`](/docs/commands/kool-exec) to execute a command inside a running service container: + +```bash +# kool exec [OPTIONS] SERVICE COMMAND [--] [ARG...] + +$ kool exec app ls +``` + +Try `kool run artisan --help` to execute the `kool exec app php artisan --help` command in your running `app` container and print out information about Laravel's CLI commands. + +### Open Sessions in Docker Containers + +Similar to SSH, if you want to open a Bash session in your `app` container, run `kool exec app bash`, where `app` is the name of the service container in **docker-compose.yml**. If you prefer, you can use `sh` instead of `bash` (`kool exec app sh`). + +```bash +$ kool exec app bash +bash-5.1# + +$ kool exec app sh +/app # +``` + +### Connect to Docker Database Container + +You can easily start a new SQL client session inside your running `database` container by executing `kool run mysql` (MySQL) or `kool run psql` (PostgreSQL) in your terminal. This runs the single-line `mysql` or `psql` script included in your **kool.yml**. + +### Access Private Repos and Packages in Docker Containers + +If you need your `app` container to use your local SSH keys to pull private repositories and/or install private packages (which have been added as dependencies in your `composer.json` or `package.json` file), you can simply add `$HOME/.ssh:/home/kool/.ssh:delegated` under the `volumes` key of the `app` service in your **docker-compose.yml** file. This maps a `.ssh` folder in the container to the `.ssh` folder on your host machine. + +```diff +volumes: + - .:/app:delegated ++ - $HOME/.ssh:/home/kool/.ssh:delegated +``` + +## Staying kool + +When it's time to stop working on the project: + +```bash +$ kool stop +``` + +And when you're ready to start work again: + +```bash +$ kool start +``` + +## Additional Presets + +We have more presets to help you start projects with **kool** in a standardized way across different frameworks. + +- **[AdonisJs](/docs/2-Presets/AdonisJs.md)** +- **[CodeIgniter](/docs/2-Presets/CodeIgniter.md)** +- **[Express.js](/docs/2-Presets/ExpressJS.md)** +- **[Hugo](/docs/2-Presets/Hugo.md)** +- **[NestJS](/docs/2-Presets/NestJS.md)** +- **[Next.js](/docs/2-Presets/NextJS.md)** +- **[Node.js](/docs/2-Presets/NodeJS.md)** +- **[Nuxt.js](/docs/2-Presets/NuxtJS.md)** +- **[PHP](/docs/2-Presets/PHP.md)** +- **[Symfony](/docs/2-Presets/Symfony.md)** +- **[WordPress](/docs/2-Presets/WordPress.md)** + +Missing a preset? **[Make a request](https://github.com/kool-dev/kool/issues/new)**, or contribute by opening a Pull Request. Go to [https://github.com/kool-dev/kool/tree/main/presets](https://github.com/kool-dev/kool/tree/main/presets) and browse the code to learn more about how presets work. diff --git a/docs/2-Presets/Laravel.md b/docs/2-Presets/Laravel.md index 7a2aed13..cd5aaba9 100644 --- a/docs/2-Presets/Laravel.md +++ b/docs/2-Presets/Laravel.md @@ -26,7 +26,7 @@ Use the [`kool create PRESET FOLDER` command](/docs/commands/kool-create) to cre $ kool create laravel my-project ``` -Under the hood, this command will run `composer create-project --no-install --no-scripts --prefer-dist laravel/laravel my-project` using a customized **kool** Docker image: kooldev/php:7.4. +Under the hood, this command will run `composer create-project --no-install --no-scripts --prefer-dist laravel/laravel my-project` using a customized **kool** Docker image: kooldev/php:8.1. After installing Laravel, `kool create` automatically runs the `kool preset laravel` command, which helps you easily set up the initial tech stack for your project using an interactive wizard. diff --git a/presets/laravel+octane/config.yml b/presets/laravel+octane/config.yml index 3e7db3e4..17f4a8dc 100644 --- a/presets/laravel+octane/config.yml +++ b/presets/laravel+octane/config.yml @@ -27,6 +27,8 @@ preset: - kool docker kooldev/php:8.1-nginx-swoole composer require laravel/octane - kool docker kooldev/bash -c "cp .env.example .env" - kool docker kooldev/php:8.1-nginx-swoole php artisan key:generate + # making sure that .env.example always have an APP_KEY, otherwise octane won't start + - kool docker kooldev/bash -c "cp .env .env.example" - kool docker kooldev/php:8.1-nginx-swoole php artisan octane:install --server=swoole - name: 'Customize your setup' From f6ff2b2de925d47754091358eec675df81a204e2 Mon Sep 17 00:00:00 2001 From: fabriciojs Date: Sun, 4 Dec 2022 21:32:34 -0300 Subject: [PATCH 6/8] update cobra auto-generated cli docs --- docs/4-Commands/0-kool.md | 5 +++-- docs/4-Commands/kool-completion.md | 3 ++- docs/4-Commands/kool-create.md | 3 ++- docs/4-Commands/kool-docker.md | 3 ++- docs/4-Commands/kool-exec.md | 3 ++- docs/4-Commands/kool-info.md | 3 ++- docs/4-Commands/kool-init.md | 3 ++- docs/4-Commands/kool-logs.md | 3 ++- docs/4-Commands/kool-preset.md | 3 ++- docs/4-Commands/kool-recipe.md | 3 ++- docs/4-Commands/kool-restart.md | 3 ++- docs/4-Commands/kool-run.md | 3 ++- docs/4-Commands/kool-self-update.md | 3 ++- docs/4-Commands/kool-share.md | 3 ++- docs/4-Commands/kool-start.md | 3 ++- docs/4-Commands/kool-status.md | 3 ++- docs/4-Commands/kool-stop.md | 3 ++- 17 files changed, 35 insertions(+), 18 deletions(-) diff --git a/docs/4-Commands/0-kool.md b/docs/4-Commands/0-kool.md index f8a7f8ae..4916350b 100644 --- a/docs/4-Commands/0-kool.md +++ b/docs/4-Commands/0-kool.md @@ -17,8 +17,9 @@ kool ### Options ``` - -h, --help help for kool - --verbose increases output verbosity + -h, --help help for kool + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-completion.md b/docs/4-Commands/kool-completion.md index 2d93c033..c63d722c 100644 --- a/docs/4-Commands/kool-completion.md +++ b/docs/4-Commands/kool-completion.md @@ -60,7 +60,8 @@ kool completion [bash|zsh|fish|powershell] ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-create.md b/docs/4-Commands/kool-create.md index 2045c36d..6d3fb99d 100644 --- a/docs/4-Commands/kool-create.md +++ b/docs/4-Commands/kool-create.md @@ -19,7 +19,8 @@ kool create PRESET FOLDER ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-docker.md b/docs/4-Commands/kool-docker.md index afc41be1..25544330 100644 --- a/docs/4-Commands/kool-docker.md +++ b/docs/4-Commands/kool-docker.md @@ -27,7 +27,8 @@ kool docker [OPTIONS] IMAGE [COMMAND] [--] [ARG...] ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-exec.md b/docs/4-Commands/kool-exec.md index 3b056ad6..d313a11d 100644 --- a/docs/4-Commands/kool-exec.md +++ b/docs/4-Commands/kool-exec.md @@ -22,7 +22,8 @@ kool exec [OPTIONS] SERVICE COMMAND [--] [ARG...] ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-info.md b/docs/4-Commands/kool-info.md index 1c746fcb..c741ed6d 100644 --- a/docs/4-Commands/kool-info.md +++ b/docs/4-Commands/kool-info.md @@ -19,7 +19,8 @@ kool info ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-init.md b/docs/4-Commands/kool-init.md index 7c16f2f9..c6885ad0 100644 --- a/docs/4-Commands/kool-init.md +++ b/docs/4-Commands/kool-init.md @@ -21,7 +21,8 @@ kool init [PRESET] ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-logs.md b/docs/4-Commands/kool-logs.md index 42efcc6a..522e10ed 100644 --- a/docs/4-Commands/kool-logs.md +++ b/docs/4-Commands/kool-logs.md @@ -23,7 +23,8 @@ kool logs [OPTIONS] [SERVICE...] ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-preset.md b/docs/4-Commands/kool-preset.md index 6e2034cc..cb42accb 100644 --- a/docs/4-Commands/kool-preset.md +++ b/docs/4-Commands/kool-preset.md @@ -21,7 +21,8 @@ kool preset [PRESET] ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-recipe.md b/docs/4-Commands/kool-recipe.md index 069e35ea..bb90e63e 100644 --- a/docs/4-Commands/kool-recipe.md +++ b/docs/4-Commands/kool-recipe.md @@ -19,7 +19,8 @@ kool recipe [RECIPE] ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-restart.md b/docs/4-Commands/kool-restart.md index a9b3fb1b..7da72459 100644 --- a/docs/4-Commands/kool-restart.md +++ b/docs/4-Commands/kool-restart.md @@ -17,7 +17,8 @@ kool restart ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-run.md b/docs/4-Commands/kool-run.md index a3af854c..4784372a 100644 --- a/docs/4-Commands/kool-run.md +++ b/docs/4-Commands/kool-run.md @@ -21,7 +21,8 @@ kool run SCRIPT [--] [ARG...] ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-self-update.md b/docs/4-Commands/kool-self-update.md index 51e195fc..8729ad33 100644 --- a/docs/4-Commands/kool-self-update.md +++ b/docs/4-Commands/kool-self-update.md @@ -19,7 +19,8 @@ kool self-update ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-share.md b/docs/4-Commands/kool-share.md index 3d5a1a2a..0350b46a 100644 --- a/docs/4-Commands/kool-share.md +++ b/docs/4-Commands/kool-share.md @@ -18,7 +18,8 @@ kool share ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-start.md b/docs/4-Commands/kool-start.md index 6416c871..96c63ede 100644 --- a/docs/4-Commands/kool-start.md +++ b/docs/4-Commands/kool-start.md @@ -23,7 +23,8 @@ kool start [SERVICE...] ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-status.md b/docs/4-Commands/kool-status.md index 3c8349f6..29be5f73 100644 --- a/docs/4-Commands/kool-status.md +++ b/docs/4-Commands/kool-status.md @@ -15,7 +15,8 @@ kool status ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO diff --git a/docs/4-Commands/kool-stop.md b/docs/4-Commands/kool-stop.md index f3e5a2ef..095f3df5 100644 --- a/docs/4-Commands/kool-stop.md +++ b/docs/4-Commands/kool-stop.md @@ -21,7 +21,8 @@ kool stop [SERVICE...] ### Options inherited from parent commands ``` - --verbose increases output verbosity + --verbose Increases output verbosity + -w, --working_dir string Changes the working directory for the command ``` ### SEE ALSO From 15556b0fbda80325b46f2d44753a60550766a654 Mon Sep 17 00:00:00 2001 From: fabriciojs Date: Sun, 4 Dec 2022 22:05:09 -0300 Subject: [PATCH 7/8] general upgrade to third part dependencies --- go.mod | 36 ++++++++++++++++++------------------ go.sum | 38 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 56 insertions(+), 18 deletions(-) diff --git a/go.mod b/go.mod index a3570e5b..1d3fd914 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module kool-dev/kool go 1.19 require ( - github.com/AlecAivazis/survey/v2 v2.3.5 + github.com/AlecAivazis/survey/v2 v2.3.6 github.com/agnivade/levenshtein v1.1.1 github.com/blang/semver v3.5.1+incompatible github.com/briandowns/spinner v1.19.0 @@ -11,20 +11,20 @@ require ( github.com/fireworkweb/godotenv v1.3.1-0.20200525231918-bdecbe8dfc58 github.com/golang/protobuf v1.5.2 // indirect github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 - github.com/gookit/color v1.5.1 - github.com/jedib0t/go-pretty/v6 v6.3.6 + github.com/gookit/color v1.5.2 + github.com/jedib0t/go-pretty/v6 v6.4.3 github.com/leaanthony/debme v1.2.1 github.com/mitchellh/go-homedir v1.1.0 - github.com/moby/term v0.0.0-20220808134915-39b0c02b01ae + github.com/moby/term v0.0.0-20221128092401-c43b287e0e0f github.com/onsi/gomega v1.7.0 // indirect github.com/rhysd/go-github-selfupdate v1.2.3 - github.com/spf13/afero v1.9.2 - github.com/spf13/cobra v1.5.0 - golang.org/x/net v0.0.0-20220812174116-3211cb980234 // indirect - golang.org/x/oauth2 v0.0.0-20220808172628-8227340efae7 // indirect - golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab - golang.org/x/term v0.0.0-20220722155259-a9ba230a4035 - golang.org/x/text v0.3.7 // indirect + github.com/spf13/afero v1.9.3 + github.com/spf13/cobra v1.6.1 + golang.org/x/net v0.2.0 // indirect + golang.org/x/oauth2 v0.2.0 // indirect + golang.org/x/sys v0.3.0 + golang.org/x/term v0.2.0 + golang.org/x/text v0.5.0 // indirect google.golang.org/appengine v1.6.7 // indirect google.golang.org/protobuf v1.28.1 // indirect gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f // indirect @@ -39,19 +39,19 @@ require ( github.com/google/go-github/v30 v30.1.0 // indirect github.com/google/go-querystring v1.1.0 // indirect github.com/inconshreveable/go-update v0.0.0-20160112193335-8152e7eb6ccf // indirect - github.com/inconshreveable/mousetrap v1.0.1 // indirect + github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 // indirect github.com/kr/text v0.2.0 // indirect - github.com/mattn/go-colorable v0.1.12 // indirect - github.com/mattn/go-isatty v0.0.14 // indirect - github.com/mattn/go-runewidth v0.0.13 // indirect + github.com/mattn/go-colorable v0.1.13 // indirect + github.com/mattn/go-isatty v0.0.16 // indirect + github.com/mattn/go-runewidth v0.0.14 // indirect github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d // indirect github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e // indirect - github.com/rivo/uniseg v0.3.4 // indirect + github.com/rivo/uniseg v0.4.3 // indirect github.com/russross/blackfriday/v2 v2.1.0 // indirect github.com/spf13/pflag v1.0.5 // indirect github.com/tcnksm/go-gitconfig v0.1.2 // indirect github.com/ulikunitz/xz v0.5.10 // indirect - github.com/xo/terminfo v0.0.0-20210125001918-ca9a967f8778 // indirect - golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa // indirect + github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e // indirect + golang.org/x/crypto v0.3.0 // indirect ) diff --git a/go.sum b/go.sum index d0ba749c..a7a5ff38 100644 --- a/go.sum +++ b/go.sum @@ -38,6 +38,8 @@ cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3f dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= github.com/AlecAivazis/survey/v2 v2.3.5 h1:A8cYupsAZkjaUmhtTYv3sSqc7LO5mp1XDfqe5E/9wRQ= github.com/AlecAivazis/survey/v2 v2.3.5/go.mod h1:4AuI9b7RjAR+G7v9+C4YSlX/YL3K3cWNXgWXOhllqvI= +github.com/AlecAivazis/survey/v2 v2.3.6 h1:NvTuVHISgTHEHeBFqt6BHOe4Ny/NwGZr7w+F8S9ziyw= +github.com/AlecAivazis/survey/v2 v2.3.6/go.mod h1:4AuI9b7RjAR+G7v9+C4YSlX/YL3K3cWNXgWXOhllqvI= github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1 h1:UQHMgLO+TxOElx5B5HZ4hJQsoJ/PvUvKRhJHDQXO8P8= github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= @@ -158,6 +160,8 @@ github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5m github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= github.com/gookit/color v1.5.1 h1:Vjg2VEcdHpwq+oY63s/ksHrgJYCTo0bwWvmmYWdE9fQ= github.com/gookit/color v1.5.1/go.mod h1:wZFzea4X8qN6vHOSP2apMb4/+w/orMznEzYsIHPaqKM= +github.com/gookit/color v1.5.2 h1:uLnfXcaFjlrDnQDT+NCBcfhrXqYTx/rcCa6xn01Y8yI= +github.com/gookit/color v1.5.2/go.mod h1:w8h4bGiHeeBpvQVePTutdbERIUf3oJE5lZ8HM0UgXyg= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hinshun/vt10x v0.0.0-20220119200601-820417d04eec h1:qv2VnGeEQHchGaZ/u7lxST/RaJw+cv273q79D81Xbog= @@ -171,10 +175,14 @@ github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NH github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc= github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= +github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= +github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/jedib0t/go-pretty/v6 v6.3.3 h1:shEWoyXqldeP54byATY3IczSfMC1b/UziOISaSxcvMQ= github.com/jedib0t/go-pretty/v6 v6.3.3/go.mod h1:MgmISkTWDSFu0xOqiZ0mKNntMQ2mDgOcwOkwBEkMDJI= github.com/jedib0t/go-pretty/v6 v6.3.6 h1:A6w2BuyPMtf7M82BGRBys9bAba2C26ZX9lrlrZ7uH6U= github.com/jedib0t/go-pretty/v6 v6.3.6/go.mod h1:MgmISkTWDSFu0xOqiZ0mKNntMQ2mDgOcwOkwBEkMDJI= +github.com/jedib0t/go-pretty/v6 v6.4.3 h1:2n9BZ0YQiXGESUSR+6FLg0WWWE80u+mIz35f0uHWcIE= +github.com/jedib0t/go-pretty/v6 v6.4.3/go.mod h1:MgmISkTWDSFu0xOqiZ0mKNntMQ2mDgOcwOkwBEkMDJI= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 h1:Z9n2FFNUXsshfwJMBgNA0RU6/i7WVaAegv3PtuIHPMs= @@ -196,12 +204,18 @@ github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVc github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.12 h1:jF+Du6AlPIjs2BiUiQlKOX0rt3SujHxPnksPKZbaA40= github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= +github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= +github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= github.com/mattn/go-isatty v0.0.14 h1:yVuAays6BHfxijgZPzw+3Zlu5yQgKGP2/hcQbHb7S9Y= github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= +github.com/mattn/go-isatty v0.0.16 h1:bq3VjFmv/sOjHtdEhmkEV4x1AJtvUvOJ2PFAZ5+peKQ= +github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= github.com/mattn/go-runewidth v0.0.13 h1:lTGmDsbAYt5DmK6OnoV7EuIF1wEIFAcxld6ypU4OSgU= github.com/mattn/go-runewidth v0.0.13/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= +github.com/mattn/go-runewidth v0.0.14 h1:+xnbZSEeDbOIg5/mE6JF0w6n9duR1l3/WmbinWVwUuU= +github.com/mattn/go-runewidth v0.0.14/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b/go.mod h1:01TrycV0kFyexm33Z7vhZRXopbI8J3TDReVlkTgMUxE= github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d h1:5PJl274Y63IEHC+7izoQE9x6ikvDFZS2mDVS3drnohI= github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d/go.mod h1:01TrycV0kFyexm33Z7vhZRXopbI8J3TDReVlkTgMUxE= @@ -211,6 +225,8 @@ github.com/moby/term v0.0.0-20210619224110-3f7ff695adc6 h1:dcztxKSvZ4Id8iPpHERQB github.com/moby/term v0.0.0-20210619224110-3f7ff695adc6/go.mod h1:E2VnQOmVuvZB6UYnnDB0qG5Nq/1tD9acaOpo6xmt0Kw= github.com/moby/term v0.0.0-20220808134915-39b0c02b01ae h1:O4SWKdcHVCvYqyDV+9CJA1fcDN2L11Bule0iFy3YlAI= github.com/moby/term v0.0.0-20220808134915-39b0c02b01ae/go.mod h1:E2VnQOmVuvZB6UYnnDB0qG5Nq/1tD9acaOpo6xmt0Kw= +github.com/moby/term v0.0.0-20221128092401-c43b287e0e0f h1:J/7hjLaHLD7epG0m6TBMGmp4NQ+ibBYLfeyJWdAIFLA= +github.com/moby/term v0.0.0-20221128092401-c43b287e0e0f/go.mod h1:15ce4BGCFxt7I5NQKT+HV0yEDxmf6fSysfEDiVo3zFM= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e h1:fD57ERR4JtEqsWbfPhv4DMiApHyliiK5xCTNVSPiaAs= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= @@ -231,6 +247,8 @@ github.com/rivo/uniseg v0.2.0 h1:S1pD9weZBuJdFmowNwbpi7BJ8TNftyUImj/0WQi72jY= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rivo/uniseg v0.3.4 h1:3Z3Eu6FGHZWSfNKJTOUiPatWwfc7DzJRU04jFUqJODw= github.com/rivo/uniseg v0.3.4/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= +github.com/rivo/uniseg v0.4.3 h1:utMvzDsuh3suAEnhH0RdHmoPbU648o6CvXxTx4SBMOw= +github.com/rivo/uniseg v0.4.3/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= @@ -238,8 +256,12 @@ github.com/spf13/afero v1.8.2 h1:xehSyVa0YnHWsJ49JFljMpg1HX19V6NDZ1fkm1Xznbo= github.com/spf13/afero v1.8.2/go.mod h1:CtAatgMJh6bJEIs48Ay/FOnkljP3WeGUG0MC1RfAqwo= github.com/spf13/afero v1.9.2 h1:j49Hj62F0n+DaZ1dDCvhABaPNSGNkt32oRFxI33IEMw= github.com/spf13/afero v1.9.2/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y= +github.com/spf13/afero v1.9.3 h1:41FoI0fD7OR7mGcKE/aOiLkGreyf8ifIOQmJANWogMk= +github.com/spf13/afero v1.9.3/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y= github.com/spf13/cobra v1.5.0 h1:X+jTBEBqF0bHN+9cSMgmfuvv2VHJ9ezmFNf9Y/XstYU= github.com/spf13/cobra v1.5.0/go.mod h1:dWXEIy2H428czQCjInthrTRUg7yKbok+2Qi/yBIJoUM= +github.com/spf13/cobra v1.6.1 h1:o94oiPyS4KD1mPy2fmcYYHHfCxLqYjJOhGsCHFZtEzA= +github.com/spf13/cobra v1.6.1/go.mod h1:IOw/AERYS7UzyrGinqmz6HLUo219MORXGxhbaJUqzrY= github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= @@ -253,6 +275,8 @@ github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/ github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals= github.com/stretchr/testify v1.7.4 h1:wZRexSlwd7ZXfKINDLsO4r7WBt3gTKONc6K/VesHvHM= github.com/stretchr/testify v1.7.4/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= +github.com/stretchr/testify v1.8.0 h1:pSgiaMZlXftHpm5L7V1+rVB+AZJydKsMxsQBIJw4PKk= +github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/tcnksm/go-gitconfig v0.1.2 h1:iiDhRitByXAEyjgBqsKi9QU4o2TNtv9kPP3RgPgXBPw= github.com/tcnksm/go-gitconfig v0.1.2/go.mod h1:/8EhP4H7oJZdIPyT+/UIsG87kTzrzM4UsLGSItWYCpE= github.com/ulikunitz/xz v0.5.9/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= @@ -260,6 +284,8 @@ github.com/ulikunitz/xz v0.5.10 h1:t92gobL9l3HE202wg3rlk19F6X+JOxl9BBrCCMYEYd8= github.com/ulikunitz/xz v0.5.10/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= github.com/xo/terminfo v0.0.0-20210125001918-ca9a967f8778 h1:QldyIu/L63oPpyvQmHgvgickp1Yw510KJOqX7H24mg8= github.com/xo/terminfo v0.0.0-20210125001918-ca9a967f8778/go.mod h1:2MuV+tbUrU1zIOPMxZ5EncGwgmMJsa+9ucAQZXxsObs= +github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e h1:JVG44RsyaB9T2KIHavMF/ppJZNG9ZpyihvCd0w101no= +github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e/go.mod h1:RbqR21r5mrJuqunuUZ/Dhy/avygyECGrLceyNeo4LiM= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= @@ -282,6 +308,8 @@ golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d h1:sK3txAijHtOK88l68nt020 golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa h1:zuSxTR4o9y82ebqCUJYNGJbGPo6sKVl54f/TVDObg1c= golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +golang.org/x/crypto v0.3.0 h1:a06MkbcxBrEFc0w0QIZWXrH/9cCX6KJyWbBOIwAn+7A= +golang.org/x/crypto v0.3.0/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -351,6 +379,8 @@ golang.org/x/net v0.0.0-20220630215102-69896b714898 h1:K7wO6V1IrczY9QOQ2WkVpw4JQ golang.org/x/net v0.0.0-20220630215102-69896b714898/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220812174116-3211cb980234 h1:RDqmgfe7SvlMWoqC3xwQ2blLO3fcWcxMa3eBLRdRW7E= golang.org/x/net v0.0.0-20220812174116-3211cb980234/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= +golang.org/x/net v0.2.0 h1:sZfSu1wtKLGlWI4ZZayP0ck9Y73K1ynO6gqzTdBVdPU= +golang.org/x/net v0.2.0/go.mod h1:KqCZLdyyvdV855qA2rE3GC2aiw5xGR5TEjj8smXukLY= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20181106182150-f42d05182288/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -365,6 +395,8 @@ golang.org/x/oauth2 v0.0.0-20220630143837-2104d58473e0 h1:VnGaRqoLmqZH/3TMLJwYCE golang.org/x/oauth2 v0.0.0-20220630143837-2104d58473e0/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.0.0-20220808172628-8227340efae7 h1:dtndE8FcEta75/4kHF3AbpuWzV6f1LjnLrM4pe2SZrw= golang.org/x/oauth2 v0.0.0-20220808172628-8227340efae7/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= +golang.org/x/oauth2 v0.2.0 h1:GtQkldQ9m7yvzCL1V+LrYow3Khe0eJH0w7RbX/VbaIU= +golang.org/x/oauth2 v0.2.0/go.mod h1:Cwn6afJ8jrQwYMxQDTpISoXmXW9I6qF6vDeuuoX3Ibs= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -422,6 +454,8 @@ golang.org/x/sys v0.0.0-20220701225701-179beb0bd1a1 h1:+Lm8wRwJpsVpTHuM4tHTwgxjP golang.org/x/sys v0.0.0-20220701225701-179beb0bd1a1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab h1:2QkjZIsXupsJbJIdSjjUOgWK3aEtzyuh2mPt3l/CkeU= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.3.0 h1:w8ZOecv6NaNa/zC8944JTU3vz4u6Lagfk4RPQxv92NQ= +golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210503060354-a79de5458b56/go.mod h1:tfny5GFUkzUvx4ps4ajbZsCe5lw1metzhBm9T3x7oIY= @@ -429,6 +463,8 @@ golang.org/x/term v0.0.0-20220526004731-065cf7ba2467 h1:CBpWXWQpIRjzmkkA+M7q9Fqn golang.org/x/term v0.0.0-20220526004731-065cf7ba2467/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.0.0-20220722155259-a9ba230a4035 h1:Q5284mrmYTpACcm+eAKjKJH48BBwSyfJqmmGDTtT8Vc= golang.org/x/term v0.0.0-20220722155259-a9ba230a4035/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= +golang.org/x/term v0.2.0 h1:z85xZCsEl7bi/KwbNADeBYoOP0++7W1ipu+aGnpwzRM= +golang.org/x/term v0.2.0/go.mod h1:TVmDHMZPmdnySmBfhjOoOdhjzdE1h4u1VwSiw2l1Nuc= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -438,6 +474,8 @@ golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= +golang.org/x/text v0.5.0 h1:OLmvp0KP+FVG99Ct/qFiL/Fhk4zp4QQnZ7b2U+5piUM= +golang.org/x/text v0.5.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= From 26c3b26a019c85a8077e9d60bb35e3959b790b56 Mon Sep 17 00:00:00 2001 From: fabriciojs Date: Tue, 6 Dec 2022 17:59:01 -0300 Subject: [PATCH 8/8] fix deprecated api usage --- commands/completion.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commands/completion.go b/commands/completion.go index 2b5e4461..1bfb7100 100644 --- a/commands/completion.go +++ b/commands/completion.go @@ -89,7 +89,7 @@ $ kool completion fish > ~/.config/fish/completions/kool.fish `, DisableFlagsInUseLine: true, ValidArgs: []string{"bash", "zsh", "fish", "powershell"}, - Args: cobra.ExactValidArgs(1), + Args: cobra.MatchAll(cobra.ExactArgs(1)), Hidden: true, RunE: DefaultCommandRunFunction(completion), }