Skip to content

Documentation: command for installing the latest AppImage version #975

@benelan

Description

@benelan

Hi! I put together a command for installing the latest AppImage version of vifm for my dotfiles:

curl -Lo ~/.local/bin/vifm \
    "https://github.com/vifm/vifm/releases/latest/download/vifm-v$(
        curl -s "https://api.github.com/repos/vifm/vifm/releases/latest" |
            grep '"tag_name":' |
            sed -E 's/.*"v*([^"]+)".*/\1/'
    )-x86_64.AppImage" &&
    chmod +x ~/.local/bin/vifm

I thought I'd share since it may be worth documenting somewhere for others to use. Feel free to close the issue when you see it, thanks!

Edit: you could also use jq to grab the version, but that's less portable

curl -Lo ~/.local/bin/vifm \
    "https://github.com/vifm/vifm/releases/latest/download/vifm-$(
        curl -s "https://api.github.com/repos/vifm/vifm/releases/latest" |
            jq -r ".tag_name"
    )-x86_64.AppImage" &&
    chmod +x ~/.local/bin/vifm

Edit 2: with the GitHub CLI for good measure

curl -Lo ~/.local/bin/vifm \
    "https://github.com/vifm/vifm/releases/latest/download/vifm-$(
        gh api repos/vifm/vifm/releases/latest --jq ".tag_name"
    )-x86_64.AppImage" &&
    chmod +x ~/.local/bin/vifm

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions