mirror of
https://gitea.phreedom.club/localhost_frssoft/bloat.git
synced 2025-05-06 03:48:45 +00:00
Don't overwrite global config file on make install
This commit is contained in:
parent
4ef5e0daf2
commit
c2f237e901
3 changed files with 7 additions and 4 deletions
9
Makefile
9
Makefile
|
@ -18,6 +18,10 @@ all: bloat
|
|||
|
||||
bloat: $(SRC) $(TMPL)
|
||||
$(GO) build $(GOFLAGS) -o bloat main.go
|
||||
sed -e "s%=database%=/var/bloat%g" \
|
||||
-e "s%=templates%=$(SHAREPATH)/templates%g" \
|
||||
-e "s%=static%=$(SHAREPATH)/static%g" \
|
||||
< bloat.conf > bloat.gen.conf
|
||||
|
||||
install: bloat
|
||||
mkdir -p $(DESTDIR)$(BINPATH) \
|
||||
|
@ -29,10 +33,6 @@ install: bloat
|
|||
chmod 0644 $(DESTDIR)$(SHAREPATH)/templates/*
|
||||
cp -r static/* $(DESTDIR)$(SHAREPATH)/static
|
||||
chmod 0644 $(DESTDIR)$(SHAREPATH)/static/*
|
||||
sed -e "s%=database%=/var/bloat%g" \
|
||||
-e "s%=templates%=$(SHAREPATH)/templates%g" \
|
||||
-e "s%=static%=$(SHAREPATH)/static%g" \
|
||||
< bloat.conf > /etc/bloat.conf
|
||||
|
||||
uninstall:
|
||||
rm -f $(DESTDIR)$(BINPATH)/bloat
|
||||
|
@ -40,3 +40,4 @@ uninstall:
|
|||
|
||||
clean:
|
||||
rm -f bloat
|
||||
rm -f bloat.gen.conf
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue