chore: reduce whitespace

This commit is contained in:
Daylin Morgan 2022-09-05 23:35:37 -05:00
parent 4e2a771b8c
commit 2070819393
4 changed files with 3 additions and 15 deletions

View file

@ -84,6 +84,8 @@ info:
$(call tprint,{a.b_magenta}This is task-print output:{a.end}) $(call tprint,{a.b_magenta}This is task-print output:{a.end})
$(call tprint,$(msg)) $(call tprint,$(msg))
task.mk:
./generate.py $(shell git describe --tags) > task.mk
define USAGE define USAGE
{a.$(HEADER_COLOR)}usage:{a.end} {a.$(HEADER_COLOR)}usage:{a.end}

View file

@ -1,5 +1,3 @@
define #% block name %##% endblock %#_py define #% block name %##% endblock %#_py
#% block script %##% endblock %# #% block script %##% endblock %#
endef endef

View file

@ -1,7 +1,6 @@
#% extends "py-script.mk" %# #% extends "py-script.mk" %#
#% block name %#vars#% endblock %# #% block name %#vars#% endblock %#
#% block script %# #% block script %#
import os import os
##- '$(ansi_py)' -## ##- '$(ansi_py)' -##

13
task.mk
View file

@ -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
# 22.9.5 # v22.9.5-3-g9c67418
# #
# task.mk should be included at the bottom of your Makefile. # task.mk should be included at the bottom of your Makefile.
# 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.
@ -103,7 +103,6 @@ pysh = printf "$(call create_string,$($(1)))" | python3
define help_py define help_py
import os import os
import re import re
@ -141,12 +140,10 @@ for goal, msg in goals:
print(f"""$(EPILOG)""") print(f"""$(EPILOG)""")
endef endef
define ansi_py define ansi_py
import os import os
import sys import sys
@ -197,22 +194,18 @@ class Ansi:
a = ansi = Ansi() a = ansi = Ansi()
endef endef
define info_py define info_py
$(ansi_py) $(ansi_py)
print(f"""$(2)""") print(f"""$(2)""")
endef endef
define print_ansi_py define print_ansi_py
$(ansi_py) $(ansi_py)
codes_names = { codes_names = {
@ -224,13 +217,10 @@ for code in sorted(codes_names.keys(), key=lambda item: (len(item), item)):
print("{:>20} {}".format(codes_names[code], code + "******" + ansi.end)) print("{:>20} {}".format(codes_names[code], code + "******" + ansi.end))
endef endef
define vars_py define vars_py
import os import os
$(ansi_py) $(ansi_py)
@ -245,6 +235,5 @@ for v in vars:
print() print()
endef endef