-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
36 lines (28 loc) · 756 Bytes
/
Makefile
File metadata and controls
36 lines (28 loc) · 756 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
BINARY=claude-remote
INSTALL_PATH=$(HOME)/bin/$(BINARY)
PLIST_NAME=com.claude-remote.plist
PLIST_SRC=launchd/$(PLIST_NAME)
PLIST_DST=$(HOME)/Library/LaunchAgents/$(PLIST_NAME)
.PHONY: build run test clean install uninstall
build:
go build -o $(BINARY) .
run: build
./$(BINARY) serve
test:
go test ./... -v -count=1
test-race:
go test -race ./... -v -count=1
clean:
rm -f $(BINARY)
install: build
mkdir -p $(HOME)/bin
cp $(BINARY) $(INSTALL_PATH)
mkdir -p $(HOME)/Library/LaunchAgents
sed 's|__HOME__|$(HOME)|g' $(PLIST_SRC) > $(PLIST_DST)
launchctl load $(PLIST_DST)
@echo "Installed. Run 'claude-remote setup' if first time."
uninstall:
-launchctl unload $(PLIST_DST)
-rm -f $(PLIST_DST)
-rm -f $(INSTALL_PATH)
@echo "Uninstalled."