diff --git a/lib/shared.mk b/lib/shared.mk index ebde197..effff21 100644 --- a/lib/shared.mk +++ b/lib/shared.mk @@ -11,7 +11,8 @@ LIB_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST)))) mk_link := $(LIB_DIR)/helper/mk_link rm_link := $(LIB_DIR)/helper/rm_link report := LAST_RETURN=$$? $(LIB_DIR)/helper/report -cmd_exist = $(shell (($$+commands[$1])) && echo true || echo false ) +return_val_truthy := && echo true || echo false +cmd_exist = $(shell (($$+commands[$1])) $(return_val_truthy) ) # Shortcut for the XDG dir if it exist. default to ~/.confg XDG_DIR := $${XDG_CONFIG_DIR:-~/.config}