Skip to content

Aliases are not supported by --execute #231

@nikelborm

Description

@nikelborm

Describe the bug

freeze --execute doesn't interpret aliases or functions

To Reproduce

  1. Open the terminal and enter this
alias ll='eza -labgM --group-directories-first --no-time --octal-permissions --classify=always --icons=always --color-scale=size --color-scale-mode=gradient --color=always --hyperlink --smart-group --no-quotes -h'

freeze --execute ll
  1. Observe error
                              
   ERROR  Something went wrong
                              
  could not execute: exec: "ll": executable file not found in $PATH

Expected behavior

Makes a screenshot.

Workaround

# paste this function into .bashrc
plain_alias () 
{ 
    alias $1 | grep --color=never -oP "(?<=').*(?=')"
}

# run 
freeze --execute "$(plain_alias ll) /"

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