opencommit
opencommit copied to clipboard
Add an environment variable to hold ollama instance
trafficstars
…mmitlint/utils.ts):
- update hardcoded URLs with configurable OCO_AI_HOST variable
- add isValidHttpUrl utility function to validate the OCO_AI_HOST value in utils.ts file
- use getConfig() function from commands/config.ts to access OCO_AI_HOST and other config values
- update OllamaAi class in engine/ollama.ts to use the new OCO_AI_HOST configuration value.
Why ?
I tried the tool, and wanted to put llama on a personnal server.
I didn't give much time to test it, only generated this commit with the new export OCO_AI_HOST='http://192.168.1.2:11434'.
I'm not a typescript dev, so please be kind :smile: