Git Product home page Git Product logo

linuxinfo's Introduction

Hey! 😁

  • πŸ‘ Enjoy: automation, coding, security, infrastructure
  • πŸŒ› SideProjects: Contributions to PowerShell-Docs and my blog
  • πŸ“« Contact: Twitter, LinkedIn
  • ⚑ FunFact: I'm a former Wow Glad (if you know you know) and have 3600+ hours in DoTA2 πŸ€“
  • πŸ“ Hobbies:
    • Powerlifting πŸ‹οΈ
    • Reading πŸ“™
    • Fishing 🎣
    • Metal 🀘
    • Software, Hardware, OSS, Linux πŸ–₯️

Stats

linuxinfo's People

Contributors

ehmiiz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

linuxinfo's Issues

issue: Cannot convert value "Hz" to type "System.Int32"

Running on Debian in lxc container on proxmox.
Powershell 7.3.3
Haven't looked into the src code yet.

PS /root> get-computerinfo
InvalidArgument: /root/.local/share/powershell/Modules/linuxinfo/0.0.1/public/Get-ComputerInfo.ps1:96
Line |
96 | CPUArchitecture = uname -p
| ~~~~~~~~
| Cannot convert value "Hz" to type "System.Int32". Error: "The input string 'Hz' was not in a correct
| format."

SystemBootTime should be [DateTime]

When running Get-SystemUptime, the SystemBootTime property is a string. To make it more PowerShell-friendly, I think it should be a [DateTime] object.

PS /home/jeff> (get-systemuptime).systemBootTime
2023-09-12 09:29:02
PS /home/jeff> (get-systemuptime).systemBootTime -as [datetime]

Tuesday, 12 September 2023 09:29:02

"Specify" output

feature request

Instead of returning a PSCustomObject, write a asci/retro console type output as default output, and allows a switch parameter to only get a PSCustomObject (so default is kind of like a cli speccy but it supports scripting/ci scenarios)

Get-BatteryInfo try/catch

On systems without battery, this cmdlet errors in its current state
Need to check if upower -e finds a battery, and if not, display it to the user

Get-ComputerInfo needs to be more robust

currently the text manipulation will break too easily
Also glxinfo should be replaced with a get-content approach since glxinfo is not guaranteed to be installed on all different distros

Disk Info returns an array

When I run Get-ComputerInfo I get this result.

BiosDate        :
BiosVendor      :
BiosVerson      :
CPU             : 1
CPUArchitecture : x86_64
CPUThreads      : 2
CPUCores        : 1
CPUSockets      : 1
DistName        : Ubuntu 22.04.3 LTS
DistSupportURL  : https://www.ubuntu.com/
DiskSizeGb      : {251, 931, 251}
DiskFreeGb      : {234, 542, 234}
DiskUsedGb      : {17, 389, 17}
GPU             :
DistVersion     : 22.04.3 LTS (Jammy Jellyfish)
KernelRelease   : 5.15.90.1-microsoft-standard-WSL2
OS              : GNU/Linux
RAM             : 4G

The disk info is an array, I think, because I have multiple filesystem PSDrives.

PS /home/jeff> get-psdrive -PSProvider FileSystem

Name           Used (GB)     Free (GB) Provider      Root                                CurrentL
                                                                                          ocation
----           ---------     --------- --------      ----                                --------
/                  17.02        233.91 FileSystem    /                                   …me/jeff
S                 389.41        542.08 FileSystem    /mnt/c/scripts
Temp               17.02        233.91 FileSystem    /tmp/

I think you need to modify your code to only use the / drive.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.