Git Product home page Git Product logo

Comments (5)

timvink avatar timvink commented on August 28, 2024

Hi @PaulHofma ,

Thanks for opening an issue on this! The good news is that it works on my machine 😄 I used export DOING_PR_CREATE_AUTO_COMPLETE="False" just like you.

The bad news is we now need to do some more digging to find out why it doesn't work for you:

  • What version of doing-cli are you running? (doing --version)
  • What version of python are you running? (python -V)
  • What version of az are you running? (az --version, lookup 'azure-cli' and ' azure-devops')
  • What operating system are you running on?

If you're not on the latest version, you can try upgrading (pip install --upgrade doing-cli and az --upgrade).

It might be that you're on windows, and the environment variable is not properly persistent. You can try:

  • doing pr create --no-auto-complete. If that works:
  • You can set a command default in the configuration file as well (see docs). In short, update your .doing-cli-config.yml file with:
defaults:
    DOING_PR_CREATE_AUTO_COMPLETE: False

Is this a user error on my part, or is this var simply not being read properly?

Well the difference doesn't really matter, either bad docs or bad code, so a fix is needed anyway. Once we figure out the root cause of the export not working, I need to figure out how to prevent people getting stuck on this!

from doing-cli.

PaulHofma avatar PaulHofma commented on August 28, 2024
  • doing: most recent version (1.1.7)
  • python: 3.9.4
  • az: most recent (2.22.1, devops: 0.18.0)
  • MacOS Catalina 10.15.7

I think I've realised what the issue is, because doing pr create ... works as expected.

Basically, the thing is I never use the plain doing pr create ... command - I really only ever make use of doing workon. However, I then immediately realized two things:

  1. There is no option at all to set/unset autocomplete for workon. (does not take that param)
  2. While many options (used to?) carry over from pr create to workon, as it's calling that under the hood (at least I'm fairly certain that's how it used to work? Haven't really checked out the code in while), this one ceretainly does not.

So I guess, really, that my issue isn't that the option isn't being recognized. It's that the option doesn't exist to begin with :p

As such, I'd turn this into a feature request (I can create a separate issue if you like): can we create a --no-auto-complete option for workon, or, alternatively, track the defaults for pr create when using workon?

from doing-cli.

operte avatar operte commented on August 28, 2024

On a somewhat related issue, from reading the documentation I thought that I could add pr_create_auto_complete: False to the .doing-cli-config.yml but from what I see from Tim's comment above, it should be

defaults:
    DOING_PR_CREATE_AUTO_COMPLETE: False

When I ran doing pr create ..., auto complete was still on, so I knew I did something wrong :)

The way I interpreted the docs, I thought the env vars should be added to e.g. .bash_aliases and that when adding settings to .doing-cli-config.yml the syntax was different (i.e. small caps, without the DOING_ prefix`).

Update: I see I misinterpreted the docs. I understood that the "Optional parameters" on .doing-cli-config.yml were just a different syntax for the env variables, but they are different, from what I see now 😅

from doing-cli.

timvink avatar timvink commented on August 28, 2024

I've been focussing any spare time on skorecard. Time to revisit this.

It's confusing that doing workon uses doing create pr under the hood, so as suggested by @PaulHofma I've chosen to simply add all options to doing workon as well. Explicit > implicit. You would now have to overwrite defaults twice, but that is probably clearer:

defaults:
    DOING_PR_CREATE_AUTO_COMPLETE: False
    DOING_WORKON_CREATE_AUTO_COMPLETE: False

I also agree with @operte that the docs on config / env vars are somewhat confusing. Refactored the docs, and now have a separate 'config' menu item.

from doing-cli.

timvink avatar timvink commented on August 28, 2024

Released v1.1.9 that should address this. Let me know :)

from doing-cli.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.