kardolus / chatgpt-cli

ChatGPT CLI is a versatile tool for interacting with LLM models through OpenAI and Azure, as well as models from Perplexity AI and Llama. It supports prompts and history tracking for seamless, context-aware interactions. With extensive configuration options, it’s designed for both users and developers to create a customized GPT experience.
MIT License
569 stars 39 forks source link

Enable FreeBSD builds #65

Closed depau closed 2 months ago

depau commented 2 months ago

Hi! Could you please enable building for FreeBSD? It works with no changes required

root@frigo-bsd ~/chatgpt-cli (main)# go build -C cmd/chatgpt/
go: downloading go1.22.0 (freebsd/amd64)
root@frigo-bsd ~/chatgpt-cli (main)# file ./cmd/chatgpt/chatgpt
./cmd/chatgpt/chatgpt: ELF 64-bit LSB executable, x86-64, version 1 (FreeBSD), dynamically linked, interpreter /libexec/ld-elf.so.1, for FreeBSD 12.3, FreeBSD-style, Go BuildID=Tw-YvpCDazcvTorIWinj/ZTW_fIwqsvUiMjZgI6gP/FF-18SCGzCU0aGTcKtNi/ymAF9KQek8MWcBYHXSqf, with debug_info, not stripped
root@frigo-bsd ~/chatgpt-cli (main)# ./cmd/chatgpt/chatgpt 
missing environment variable: OPENAI_API_KEY
kardolus commented 2 months ago

@depau done! :)

https://github.com/kardolus/chatgpt-cli/releases/tag/v1.6.5

Future releases will have them automatically: https://github.com/kardolus/chatgpt-cli/commit/0c7d14f6089f5c5425ce3be8e2488e45290d5a11

Any chance you can test the BSD build I added to the 1.6.5 release?

kardolus commented 2 months ago

Here are some one liners if that's easier.

ARM:

curl -L -o chatgpt https://github.com/kardolus/chatgpt-cli/releases/latest/download/chatgpt-freebsd-arm64 && chmod +x chatgpt && sudo mv chatgpt /usr/local/bin/

AMD:

curl -L -o chatgpt https://github.com/kardolus/chatgpt-cli/releases/latest/download/chatgpt-freebsd-amd64 && chmod +x chatgpt && sudo mv chatgpt /usr/local/bin/
depau commented 2 months ago

Thanks!