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

Get all the information #971

Open
Angelk90 opened this issue Feb 14, 2025 · 0 comments
Open

Get all the information #971

Angelk90 opened this issue Feb 14, 2025 · 0 comments

Comments

@Angelk90
Copy link

Hi @sebhildebrandt , I would like to get all the information possible, I went to read: https://systeminformation.io/general.html

But I am having some doubts.
I created the following example script to print everything.

I understood that using getStaticData, getDynamicData, getAllData, should return everything or not?

For example none of the three return detailed information about audio: '*'

What is the complete way to get everything?

Code:

const fs = require('fs');
const si = require('systeminformation');
const process = require('process');

async function getAllSystemInfo() {
    const valueObject = {
        audio: '*',
        bios: '*',
        baseboard: '*',
        chassis: '*',
        cpu: '*',
        diskLayout: '*',
        disksIO: '*',
        blockDevices: '*',
        fsOpenFiles: '*',
        fsSize: '*',
        fsStats: '*',
        graphics: '*',
        bluetoothDevices: '*',
        inetLatency: '*',
        inetChecksite: '*',
        cpuCurrentSpeed: '*',
        currentLoad: '*',
        fullLoad: '*',
        mem: '*',
        memLayout: '*',
        osInfo: '*',
        processes: '*',
        processLoad: '*',
        printer: '*',
        services: '*',
        shell: '*',
        time: '*',
        cpuTemperature: '*',
        usb: '*',
        uuid: '*',
        versions: '*',
        vboxInfo: '*',
        wifiNetworks: '*',
        wifiInterfaces: '*',
        wifiConnections: '*',
        system: '*',
        battery: '*',
        users: '*',
        networkInterfaceDefault: '*',
        networkGatewayDefault: '*',
        networkInterfaces: '*',
        networkStats: '*',
        networkConnections: '*',
        dockerInfo: '*',
        dockerImages: '*',
        dockerContainers: '*',
        dockerContainerStats: '*',
        dockerContainerProcesses: '*',
        dockerVolumes: '*',


        getStaticData: '*',
        getDynamicData: '*',
        getAllData: '*',
    };

    await si.get(valueObject).then((data) => {
        if (process.argv[2] && process.argv[2] === '-s' && process.argv[3]) {
            fs.writeFileSync(process.argv[3], JSON.stringify(data, null, 2), 'utf8');
            console.log(`Data has been saved to ${process.argv[3]}`);
        } else {
            console.log({ data });
        }
    });
}
getAllSystemInfo();
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

1 participant