Skip to content

asdf install should exit with exit code of 0 when a tool version is set to uninstallable system version #2269

Description

@Stratus3D

asdf install still returns a non-zero exit code with postgres system in my ~/.tool-versions. I'd think it should only exit with a non-zero exit code when trying to install a system version directly, e.g.: asdf install postgres system as in this test case:

@test "install_command doesn't install system version" {
run asdf install dummy system
[ "$status" -eq 1 ]
[ "$output" = "error installing version: uninstallable version system of dummy" ]
[ ! -f "$ASDF_DIR/installs/dummy/system/version" ]
}

I think asdf install should skip over them and return success.

Currently:

➜ asdf install
[...]
skipping uninstallable version system of postgres
version [...] of ruby is already installed
[...]

➜ echo $?                     
1

➜ asdf install postgres system
error installing version: uninstallable version system of postgres

➜ echo $?                     
1

Originally posted by @ZimbiX in #1930

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions