2024-05-02 00:43:43 +00:00
|
|
|
.PHONY: all install
|
2024-05-01 23:12:04 +00:00
|
|
|
|
|
|
|
|
SOURCES_SRC:=$(shell find src -type f )
|
2025-07-01 00:56:36 +00:00
|
|
|
LIBS_SRC:=$(shell find lib -type f )
|
2024-05-02 00:52:15 +00:00
|
|
|
REPOTOOL_PATH ?= ${HOME}/repo
|
2024-05-01 23:12:04 +00:00
|
|
|
|
|
|
|
|
|
2024-05-05 22:03:57 +00:00
|
|
|
all: dist/repotool
|
|
|
|
|
|
2025-07-06 17:57:04 +00:00
|
|
|
install: dist/repotool shell/repotool.zsh shell/repotool.plugin.zsh
|
2024-05-02 00:52:15 +00:00
|
|
|
mkdir -p ${REPOTOOL_PATH}/.bin/
|
2025-07-01 01:23:13 +00:00
|
|
|
mkdir -p ${REPOTOOL_PATH}/.shell/
|
|
|
|
|
install dist/repotool ${REPOTOOL_PATH}/.bin/
|
2025-07-01 01:24:21 +00:00
|
|
|
install shell/repotool.zsh shell/repotool.plugin.zsh ${REPOTOOL_PATH}/.shell/
|
2024-05-02 00:43:43 +00:00
|
|
|
|
2025-07-01 00:56:36 +00:00
|
|
|
dist/repotool: $(SOURCES_SRC) $(LIBS_SRC) main.lua
|
2025-06-30 23:46:08 +00:00
|
|
|
@mkdir -p dist
|
2025-07-01 00:56:36 +00:00
|
|
|
luabundler bundle main.lua -p "./src/?.lua" -p "./lib/?.lua" -o dist/repotool
|
|
|
|
|
@sed -i "1i#!/usr/bin/env luajit" "dist/repotool"
|
|
|
|
|
chmod +x dist/repotool
|