auto-set user and group in config.h

only works if set to nobody and nogroup in config.def.h
This commit is contained in:
Jakub 2023-01-02 22:40:35 -05:00
parent f581fd9f1a
commit 25907a1c07

View File

@ -23,6 +23,8 @@ ${OBJ}: config.h config.mk arg.h util.h
config.h:
@echo creating $@ from config.def.h
@cp config.def.h $@
@sed -i 's/static const char \*user = "nobody";/static const char \*user = "'${USER}'";/' config.h
@sed -i 's/static const char \*group = "nogroup";/static const char *group = "users";/' config.h
slock: ${OBJ}
@echo CC -o $@