gpt-cli icon indicating copy to clipboard operation
gpt-cli copied to clipboard

Solution to MacOS Overlapping Issue With An Existing Tool

Open atesahmet0 opened this issue 2 years ago • 1 comments

I installed gpt-cli via pip through the instructions. When I tried to run it in my terminal as gpt I found out it executes a different tool that exists in MacOS's called "GUID partition table maintenance utility" which located at "/usr/sbin".

Screenshot 2023-11-26 at 16 51 42

To solve this problem I changed gpt-cli's executable's name from "gpt" to "gpt-cli". Now I'm able to run gpt-cli via gpt-cli command in my terminal.

Solution:

Find executable. In my case it was located in "/usr/local/bin" folder. It was named "gpt". To see if it works you can run ./gpt inside the "/usr/local/bin" folder.

Change its name to something you want. I wanted to run gpt-cli via gpt-cli command in my terminal so I changed its name to "gpt-cli". To do this you can execute mv gpt gpt-cli or you can replace "gpt-cli" with something you want.

Screenshot 2023-11-26 at 16 55 46

atesahmet0 avatar Nov 26 '23 13:11 atesahmet0

Also if you don't want to rename things you can add alias git-cli="/usr/local/bin/gpt to your .zshrc file then you will be able to call git-cli with git-cli command.

atesahmet0 avatar Nov 26 '23 14:11 atesahmet0