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

Not work in mac #5

Open
peng051410 opened this issue Feb 6, 2018 · 10 comments
Open

Not work in mac #5

peng051410 opened this issue Feb 6, 2018 · 10 comments

Comments

@peng051410
Copy link

I got you config to my mac! when i run ihsec set conifgname i found the config folder link in .emacs.d/,
the result bellow:
image
How can i fix it ?

@peng051410
Copy link
Author

I found i need to remove .emacs.d folder! it works! but some command not friendly for mac, can you make it better?

@daedreth
Copy link
Owner

daedreth commented Feb 6, 2018

You'd need to specify what you mean by making it better.
I do not use macOS nor do I have access to any devices that use it, so unless you tell me exactly what the issue is I might not be able to help.

@peng051410
Copy link
Author

ihsec/Makefile

Line 10 in a7d454a

install -D -m 755 ihsec.sh ${TARGET}

install -D option not in mac:
image

@daedreth
Copy link
Owner

daedreth commented Feb 6, 2018

if you do echo $OSTYPE in your terminal, what does it show?
Also, what version of macOS are you on?

@peng051410
Copy link
Author

echo $OSTYPE show me darwin17.0.
mac os version 10.13.3 (17D47)!

@daedreth
Copy link
Owner

daedreth commented Feb 6, 2018

pushed a fix, see if it works

@brookter
Copy link

brookter commented Apr 15, 2018

Hi

Thanks very much for making this public — it's a great solution to a big irritation!

FWIW, the fix was still failing to work on my Macs (both on High Sierra) — the problem seems to be the the $OSTYPE variable is stripped down to STYPE for some reason, so the actual line reads

if [[ "STYPE" == "darwin"* ]] etc

when it is run and it doesn't pick up it's on a Mac. No idea why...

The fix was simple for me (as I don't need it on Linux) — just delete everything apart from the mac relevant branch of the if statement, leaving just

cp ihsec.sh /usr/local/bin/ihsec; chmod 755 /usr/local/bin/ihsec

Everything then works as planned. (I've mentioned it here in case it helps debugging (it's a problem with the if statement, not the cp statement) and in case any other Mac user is reading this.)

Many thanks again for making it public — really appreciate it!

@daedreth
Copy link
Owner

I'll leave it open for people to see, great job figuring it out!

@brookter
Copy link

brookter commented Apr 15, 2018 via email

@IVXCVI
Copy link

IVXCVI commented May 23, 2018

The 1st problem I found with the 'if' statement is that the regex symbol $ is not escaped properly, thus giving us the output @brookter provides.

It seems there is another issue that I'm still researching on Linux. I don't think that the makefile is being interpreted by bash correctly (or when it is, it spits out the entire statement as if I appended echo before the statement). I will record anything else I find in issue #7 .

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

No branches or pull requests

4 participants