autocomplete icon indicating copy to clipboard operation
autocomplete copied to clipboard

feat: add support for minikube, terragrunt, tgenv

Open yinchuandong opened this issue 3 years ago • 9 comments
trafficstars

What kind of change does this PR introduce? (Bug fix, feature, docs update, ...) New Features:

  1. Add minikube dashboard subcommand
  2. Add terragrunt support
  3. Add tgenv support

What is the current behavior? (You can also link to an open issue here)

What is the new behavior (if this is a feature change)? image

image

image

Additional info:

yinchuandong avatar Mar 08 '22 00:03 yinchuandong

Overview

src/terragrunt.ts:

Info:

src/tgenv.ts:

Info:

Script: tgenv list postProcess(function):

 function (out) {
      return out
        .trim()
        .split("\n")
        .map((tfversion) => {
          return { name: tfversion, description: "Version" };
        });
    }

Script: tgenv list-remote postProcess(function):

 function (out) {
      return out
        .trim()
        .split("\n")
        .map(function (line) {
          return { name: line, type: "option" };
        });
    }

src/minikube.ts:

Info:

withfig-bot avatar Mar 08 '22 00:03 withfig-bot

Hello @yinchuandong, thank you very much for creating a Pull Request! Here is a small checklist to get this PR merged as quickly as possible:

  • [ ] Do all subcommands / options which take arguments include the args property (args: {})?
  • [ ] Are all options modular? E.g. -a -u -x instead of -aux
  • [ ] Have all other checks passed?

Please add a 👍 as a reaction to this comment to show that you read this.

withfig-bot avatar Mar 08 '22 00:03 withfig-bot

Thanks for opening this PR!

fedeci avatar Mar 08 '22 14:03 fedeci

Are options with the equal valid when no equal is specified? If they are not we should add requiresEqual: true

Hi @fedeci , these terragrunt global options don't require equal. referring to https://terragrunt.gruntwork.io/docs/reference/cli-options/#all-terraform-built-in-commands

yinchuandong avatar Mar 15 '22 11:03 yinchuandong

Thanks for the changes @yinchuandong! If the equals are not mandatory can you remove the insertValues that insert those? I honestly find cleaner options without equals.

Hi @fedeci , thanks for your suggestion! I got what you mean. But terragrunt is a little bit tricky. It's a wrapper based on terraform which requires equal whileterragrunt itself doesn't require equal. Terragrunt needs to be compatible with Terraform and that's the reason why you see some options have equal while some don't have. I cleaned some commands based on your suggestions via directly importing from existing the terraform spec. Could you pls have a look again? It would be great if I can get this pr merged asap. We can make some improvements in the next branch. I have some DevOps friends who are keen to use the Terragrunt feature. And to be honest, most global options are not frequently used on a daily basis.

image

Reference

  1. https://terragrunt.gruntwork.io/docs/reference/cli-options/#all-terraform-built-in-commands

yinchuandong avatar Mar 15 '22 22:03 yinchuandong

Hey @yinchuandong! Sorry for the slow response here. I am not sure why this wasn't merged in. Could you sign our CLA (and ideally fix the conflicts) and I will merge this ASAP.

mschrage avatar Oct 12 '23 19:10 mschrage

recheck

mschrage avatar Oct 12 '23 19:10 mschrage

CLA Assistant Lite bot:
Thank you for your submission, we really appreciate it. Like many open-source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution. You can sign the CLA by just posting a Pull Request Comment same as the below format.


I have read the CLA Document and I hereby sign the CLA


You can retrigger this bot by commenting recheck in this Pull Request

withfig-bot avatar Oct 12 '23 19:10 withfig-bot

Hi @yinchuandong - know it's been a while, but we would love to get this merged! Could you please sign the CLA and get these small conflicts fixed? We'd love to give you merge credit :)

brendanfalk avatar Oct 27 '23 22:10 brendanfalk