-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathmakefile
More file actions
39 lines (34 loc) · 1.06 KB
/
makefile
File metadata and controls
39 lines (34 loc) · 1.06 KB
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
37
38
39
all: clean build
.PHONY: clean
clean:
rm -rf build
.PHONY: build
build:
go build -ldflags="-w -s" -o build/ .
dev:
go run .
.PHONY: test-manual
test-manual: clean build
echo "=====[TEST HELP]====="
./build/daylight --help
echo "=====[TEST SHORT]====="
./build/daylight --short
echo "=====[TEST SHORT, XMAS DAY]====="
./build/daylight --short --date="2025-12-25"
echo "=====[TEST SHORT, POLAR DAY]====="
./build/daylight --short --date="2025-12-25" --latitude="-89.925" --longitude "1.427"
echo "=====[TEST POLAR DAY]====="
./build/daylight --latitude -90 --longitude 0 --date="2025-01-02"
echo "=====[TEST POLAR NIGHT]====="
./build/daylight --latitude="82.4" --longitude -14.3 --date="2025-01-02"
echo "=====[TEST CAPE TOWN, OFFLINE]====="
./build/daylight --date="2025-02-03" --latitude="-33.92" --longitude 18.42 --timezone "Africa/Johannesburg"
echo "=====[TEST NOCOLOR]====="
NO_COLOR=true ./build/daylight
echo "=====[TEST JSON MODE]====="
./build/daylight --json
echo "=====[TEST HERE/NOW]====="
./build/daylight
.PHONY: test
test:
go test ./internal