Comments (5)
Thanks @Itxaka for your contributions. Since commit 6782e1f, and thanks to your other contribution in 812ca38 GitHub CI reveals that we now happily compile and run on Mac OS, too. Even some info there, considering this is essentially Linux specific library, I guess not too bad. 😄
{
"sysinfo": {
"version": "1.0.0",
"timestamp": "2023-05-28T17:09:21.898824Z"
},
"node": {
"machineid": "02041e1addf614c549e2b33c64738ac1",
"hypervisor": "vmware"
},
"os": {},
"kernel": {},
"product": {},
"board": {},
"chassis": {},
"bios": {},
"cpu": {
"threads": 3
},
"memory": {}
}
So, I'll close this issue now.
from sysinfo.
Hello @MihaiBojin.
I get where you're going. Even if the library is basically useless on Mac OS, you'd like it to at least compile, so that you can use the same code on multiple platform. Am I right?
Now, even if I would be willing to add some build constraints to help that specific case, the trouble is I don't have access to any Mac OS machine. So, I wouldn't be able to test the changes. Meaning, you or somebody else would need to step in and do the grunt work.
In the meantime, you could do that even in your project, basically having sysinfo_linux.go, and sysinfo_other.go, persuading Go compiler to compile sysinfo_linux on Linux, and sysinfo_other on any other sysinfo unsupported architecture. Then make a real call to GetSysInfo() in the Linux version, and just return nil in the other version. Basically, the same idea, just implemented in your project, where you really need it.
from sysinfo.
Hi, yes you are correct.
Yup, I can help with testing on a mac.
from sysinfo.
Came here to post on this. Would be nice if the library just compiled on mac to make app writing easier, even if there isn't any mac info to show.
from sysinfo.
Should now compile on Macos
from sysinfo.
Related Issues (20)
- Memory info should be more detail ? HOT 3
- Network can get ip address? HOT 3
- Title HOT 1
- When sysinfo is a global variable, when si.GetSysInfo () is executed multiple times, the slice will increase repeatedly. HOT 1
- Stray os.Exit(0) call at end of func getSetMachineID HOT 1
- When getting the time zone, something unexpected happened on my host, so I changed it to this
- Support for net interfaces on FreeBSD and macOS
- RFE to allow for container usage HOT 2
- Any chance of pulling simple GPU data? HOT 1
- Feature: compile via a docker container HOT 1
- Error on armv7 architecture HOT 2
- Unable to use library to pull Computer/Bios/CPU/etc. data from virtual Arm server HOT 1
- GetSysInfo segfaults HOT 5
- Couldn't compile on Mac OS HOT 2
- Version semantics HOT 5
- Cannot get mem info HOT 2
- Add fedora 28 to the list of supported distros HOT 1
- Thank you! HOT 1
- Detect kernel modules? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sysinfo.