mirror of
https://github.com/daylinmorgan/task.mk.git
synced 2024-11-15 05:27:53 -06:00
Compare commits
3 commits
b0f7493dc0
...
a1285a03ef
Author | SHA1 | Date | |
---|---|---|---|
a1285a03ef | |||
38a741b20e | |||
f8b1a00c50 |
4 changed files with 18 additions and 6 deletions
|
@ -11,5 +11,5 @@ PHONIFY = 1
|
||||||
|
|
||||||
-include .task.mk
|
-include .task.mk
|
||||||
.task.mk: $(TEMPLATES) generate.py
|
.task.mk: $(TEMPLATES) generate.py
|
||||||
$(call msg,re-jinjaing the local {a.b_cyan}.task.mk{a.end})
|
$(call msg,re-jinjaing the local $(if $(tprint),{a.b_cyan}.task.mk{a.end},.task.mk))
|
||||||
@./generate.py $(VERSION) > .task.mk || (echo "generator failed!!" && rm .task.mk)
|
@./generate.py $(VERSION) > .task.mk || (echo "generator failed!!" && rm .task.mk)
|
||||||
|
|
4
Makefile
4
Makefile
|
@ -25,8 +25,8 @@ assets: ## generate assets
|
||||||
define release_sh
|
define release_sh
|
||||||
./generate.py $(subst v,,$(VERSION)) > task.mk
|
./generate.py $(subst v,,$(VERSION)) > task.mk
|
||||||
sed -i 's/task.mk\/.*\/task.mk/task.mk\/$(VERSION)\/task.mk/g' README.md docs/index.md
|
sed -i 's/task.mk\/.*\/task.mk/task.mk\/$(VERSION)\/task.mk/g' README.md docs/index.md
|
||||||
sed -i 's/TASKMK_VERSION=.*/TASKMK_VERSION=$(VERSION)/' docs/init
|
sed -i 's/TASKMK_VERSION=.*/TASKMK_VERSION="$(VERSION)"/' docs/init
|
||||||
git add task.mk README.md docs/index.md
|
git add task.mk README.md docs/{index.md,init}
|
||||||
git commit -m "release: $(VERSION)" --no-verify
|
git commit -m "release: $(VERSION)" --no-verify
|
||||||
git tag $(VERSION)
|
git tag $(VERSION)
|
||||||
endef
|
endef
|
||||||
|
|
|
@ -14,7 +14,13 @@ def check_item(item):
|
||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
items = " ".join((i["goal"] for i in parse_help(gen_makefile(),require_msg=False) if check_item(i)))
|
items = " ".join(
|
||||||
|
(
|
||||||
|
i["goal"]
|
||||||
|
for i in parse_help(gen_makefile(), require_msg=False)
|
||||||
|
if check_item(i)
|
||||||
|
)
|
||||||
|
)
|
||||||
sys.stdout.write(".PHONY: " + items)
|
sys.stdout.write(".PHONY: " + items)
|
||||||
|
|
||||||
|
|
||||||
|
|
10
task.mk
10
task.mk
|
@ -1,7 +1,7 @@
|
||||||
# }> [github.com/daylinmorgan/task.mk] <{ #
|
# }> [github.com/daylinmorgan/task.mk] <{ #
|
||||||
# Copyright (c) 2022 Daylin Morgan
|
# Copyright (c) 2022 Daylin Morgan
|
||||||
# MIT License
|
# MIT License
|
||||||
TASKMK_VERSION ?= v23.1.1-10-ge85d61c-dev
|
TASKMK_VERSION ?= v23.1.1-12-gb0f7493-dev
|
||||||
# task.mk should be included at the bottom of your Makefile with `-include .task.mk`
|
# task.mk should be included at the bottom of your Makefile with `-include .task.mk`
|
||||||
# See below for the standard configuration options that should be set prior to including this file.
|
# See below for the standard configuration options that should be set prior to including this file.
|
||||||
# You can update your .task.mk with `make _update-task.mk`
|
# You can update your .task.mk with `make _update-task.mk`
|
||||||
|
@ -330,7 +330,13 @@ def check_item(item):
|
||||||
args = parseargs(item.get("msgargs", ""))
|
args = parseargs(item.get("msgargs", ""))
|
||||||
return not args.not_phony
|
return not args.not_phony
|
||||||
def main():
|
def main():
|
||||||
items = " ".join((i["goal"] for i in parse_help(gen_makefile(),require_msg=False) if check_item(i)))
|
items = " ".join(
|
||||||
|
(
|
||||||
|
i["goal"]
|
||||||
|
for i in parse_help(gen_makefile(), require_msg=False)
|
||||||
|
if check_item(i)
|
||||||
|
)
|
||||||
|
)
|
||||||
sys.stdout.write(".PHONY: " + items)
|
sys.stdout.write(".PHONY: " + items)
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
main()
|
main()
|
||||||
|
|
Loading…
Reference in a new issue