Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: build settings; add: installation management; #6

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

kendfss
Copy link

@kendfss kendfss commented May 5, 2022

Fixes #5


mansrc?=$(root)/README.md
ifeq ($(shell uname),Linux)
mandir?=/usr/local/man/man1
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

manpath does not include this path, why did you choose this path?

➜  dicterm git:(makefile) ✗ make   
go mod tidy
go clean
mkdir -p /home/murat/dev/dicterm/bin
GOOS=linux GOARCH=amd64 go build -ldflags "-s -w" -o /home/murat/dev/dicterm/bin/dicterm /home/murat/dev/dicterm/cmd/dicterm
make: *** No rule to make target '/usr/local/man/man1', needed by 'man'.  Stop.
➜  dicterm git:(makefile) ✗ manpath
/home/murat/.nvm/versions/node/v14.18.2/share/man:/usr/local/man:/usr/local/share/man:/usr/share/man
➜  dicterm git:(makefile) ✗ uname
Linux

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I misread a howtogeek article months ago, and because I've never actually tested this on linux (I'm on osx) I'm only just finding that out.

Does it not show up at all when you man dicterm? It might, because /man1 is just a section of your manpages (though I'm assuming it's even laid out like that on your system).

Do you have write access to /usr/local/man by default, or would you need sudo/doas or something?

Also, when you put something in there, does callingman something work immediately or do you need to update the database first?

article: https://www.howtogeek.com/682871/how-to-create-a-man-page-on-linux/

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can list manpage paths via manpath command as far as I know. But actually, I'm not sure about putting the readme file as a manpage, it does not look like a manpage.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

makefile: hard-set GOOS and GOARCH
2 participants