Skip to content

Define your commands in a text file #24

Description

@tolicodes

It would be very useful if you could define your commands in a text file.

Through must searching I found where you store the data...

I also wrote a shell script to convert your zsh aliases to commands. Perhaps you can have an option )

$HOME/Library/Application Support/Code/User/globalStorage/yamajyn.commandlis

DATA_PATH="$HOME/Library/Application Support/Code/User/globalStorage/yamajyn.commandlist"

setopt sh_word_split # For zsh

comms=$(grep -oE 'alias [a-zA-Z-]+' ~/.zshrc | cut -d' ' -f2)

for  command  in  $comms; do
	echo  "{\"script\":\"$command\",\"label\":\"$command\"}" > "$DATA_PATH/$command.json"
done

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions