Creates a desktop file and icon so that Bombadillo can show up in desktop environment menus and launchers #93
20
Makefile
20
Makefile
|
@ -26,7 +26,7 @@ build:
|
|||
${GOCMD} build ${LDFLAGS} -o ${BINARY}
|
||||
|
||||
.PHONY: install
|
||||
install: install-bin install-man clean
|
||||
install: install-bin install-man install-desktop clean
|
||||
|
||||
.PHONY: install-man
|
||||
install-man: bombadillo.1
|
||||
|
@ -34,6 +34,20 @@ install-man: bombadillo.1
|
|||
install -d ${DESTDIR}${MAN1DIR}
|
||||
install -m 0644 ./bombadillo.1.gz ${DESTDIR}${MAN1DIR}
|
||||
|
||||
.PHONY: install-desktop
|
||||
install-desktop:
|
||||
ifeq ($(shell uname), Linux)
|
||||
# These steps will not work on Darwin, Plan9, or Windows
|
||||
# They would likely work on BSD systems
|
||||
install -d ${DESTDIR}${DATAROOTDIR}/applications
|
||||
install -m 0644 ./bombadillo.desktop ${DESTDIR}${DATAROOTDIR}/applications
|
||||
install -d ${DESTDIR}${DATAROOTDIR}/pixmaps
|
||||
install -m 0644 ./bombadillo-icon.png ${DESTDIR}${DATAROOTDIR}/pixmaps
|
||||
-update-desktop-database 2> /dev/null
|
||||
else
|
||||
@echo "* Skipping protocol handler associations and desktop file creation for non-linux system *"
|
||||
endif
|
||||
|
||||
.PHONY: install-bin
|
||||
install-bin: build
|
||||
install -d ${DESTDIR}${BINDIR}
|
||||
|
@ -48,6 +62,10 @@ clean:
|
|||
uninstall: clean
|
||||
rm -f ${DESTDIR}${MAN1DIR}/bombadillo.1.gz
|
||||
rm -f ${DESTDIR}${BINDIR}/${BINARY}
|
||||
rm -f ${DESTDIR}${DATAROOTDIR}/applications/bombadillo.desktop
|
||||
rm -f ${DESTDIR}${DATAROOTDIR}/pixmaps/bombadillo-icon.png
|
||||
-update-desktop-database 2> /dev/null
|
||||
|
||||
|
||||
.PHONY: test
|
||||
test: clean build
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 1.3 KiB |
|
@ -0,0 +1,10 @@
|
|||
[Desktop Entry]
|
||||
Type=Application
|
||||
Name=Bombadillo
|
||||
GenericName=Non-Web Browser
|
||||
Comment=View gopher, gemini, finger, telnet, http(s) sites over the internet
|
||||
Terminal=true
|
||||
Categories=Network;WebBrowser;ConsoleOnly;
|
||||
Exec=bombadillo %U
|
||||
Icon=bombadillo-icon
|
||||
MimeType=x-scheme-handler/gopher;x-scheme-handler/gemini;x-scheme-handler/finger;
|
Loading…
Reference in New Issue