Add start-llm and stop-llm commands to Makefile
This commit is contained in:
20
Makefile
20
Makefile
@@ -1,4 +1,4 @@
|
|||||||
.PHONY: install uninstall status
|
.PHONY: install uninstall status start-llm stop-llm restart-llm
|
||||||
|
|
||||||
OPENCODE_DIR := $(HOME)/.config/opencode
|
OPENCODE_DIR := $(HOME)/.config/opencode
|
||||||
REPO_DIR := $(shell pwd)
|
REPO_DIR := $(shell pwd)
|
||||||
@@ -9,6 +9,8 @@ ITEMS := skills tools agents
|
|||||||
# LLM services to manage
|
# LLM services to manage
|
||||||
LLM_SERVICES := atlas forge swift
|
LLM_SERVICES := atlas forge swift
|
||||||
|
|
||||||
|
PLIST_PATH := ~/Library/LaunchAgents
|
||||||
|
|
||||||
install:
|
install:
|
||||||
@echo "Installing OpenCode config symlinks..."
|
@echo "Installing OpenCode config symlinks..."
|
||||||
@mkdir -p $(OPENCODE_DIR)
|
@mkdir -p $(OPENCODE_DIR)
|
||||||
@@ -49,9 +51,21 @@ status:
|
|||||||
fi \
|
fi \
|
||||||
done
|
done
|
||||||
|
|
||||||
|
stop-llm-%:
|
||||||
|
@echo "Stopping com.vllm-mlx-$*..."
|
||||||
|
@launchctl bootout gui/$$(id -u) $(PLIST_PATH)/com.vllm-mlx.$*.plist 2>/dev/null || true
|
||||||
|
|
||||||
|
stop-llm: $(patsubst %,stop-llm-%,$(LLM_SERVICES))
|
||||||
|
|
||||||
|
start-llm-%:
|
||||||
|
@echo "Starting com.vllm-mlx-$*..."
|
||||||
|
@launchctl bootstrap gui/$$(id -u) $(PLIST_PATH)/com.vllm-mlx.$*.plist
|
||||||
|
|
||||||
|
start-llm: $(patsubst %,start-llm-%,$(LLM_SERVICES))
|
||||||
|
|
||||||
restart-llm-%:
|
restart-llm-%:
|
||||||
@echo "Restarting com.vllm-mlx-$*..."
|
@echo "Restarting com.vllm-mlx-$*..."
|
||||||
@launchctl bootout gui/$$(id -u) ~/Library/LaunchAgents/com.vllm-mlx.$*.plist || true
|
@launchctl bootout gui/$$(id -u) $(PLIST_PATH)/com.vllm-mlx.$*.plist || true
|
||||||
@launchctl bootstrap gui/$$(id -u) ~/Library/LaunchAgents/com.vllm-mlx.$*.plist
|
@launchctl bootstrap gui/$$(id -u) $(PLIST_PATH)/com.vllm-mlx.$*.plist
|
||||||
|
|
||||||
restart-llm: $(patsubst %,restart-llm-%,$(LLM_SERVICES))
|
restart-llm: $(patsubst %,restart-llm-%,$(LLM_SERVICES))
|
||||||
Reference in New Issue
Block a user