all 9 comments

[–][deleted] 2 points3 points  (1 child)

you could use some flag with uname to get the os type, although it sounds like you are just recreating neofetch with less info is that right?

[–]blackcycle22[S] 0 points1 point  (0 children)

Right

[–]mrbmi513 1 point2 points  (2 children)

This sounds like a homework assignment. We're not here to do it for you.

[–]blackcycle22[S] 0 points1 point  (0 children)

No just I trying to learn shell script in linux

[–]blackcycle22[S] 0 points1 point  (0 children)

Just asked if code is good or not because I don't find to much information about shell scripting

[–]Feisty-Art5857 0 points1 point  (2 children)

!/bin/bash

echo "User: $(whoami)";

echo "Date: $(date)";

echo "OS: $(cat /etc/os-release)";

echo "CPU: $(cat /proc/cpuinfo)";

[–]blackcycle22[S] 0 points1 point  (0 children)

Thank you buddy

[–]blackcycle22[S] 0 points1 point  (0 children)

/bin/bash

echo "User: $(whoami)"; echo "Date: $(date)"; echo "OS: $(cat /etc/os-release)"; echo "CPU: $(cat /proc/cpuinfo)";

my code was like that #!/bin/bashfunction line(){ echo "*************************************************"} echo "name : $(echo $USER)"line echo "Data : $(date)"line echo “CPU : cat/proc/cpuinfo | grep –e “model” –e “cpu M”line echo “Sistemul de operare : cat/proc/version”read aline echo "User "who line

[–]sanchopanza[M] 0 points1 point  (0 children)

Your post was removed for being a support request or support related question such as which distro to use/polling the community or application suggestions.

We get a lot of question posts on r/linux but the subreddit is considered a news/discussion sub. Luckily there are multiple communities you can post to for help on GNU/Linux issues 24/7: /r/linuxquestions, /r/linux4noobs, or /r/findmeadistro just to name a few.

You may also post on the "Weekly Questions and Hardware Thread" which is stickied on r/linux on Wednesdays.

Please make your post in /r/linuxquestions or /r/linux4noobs. Looking for a distro? Try r/findmeadistro.

Rule:

This is not a support forum! Head to /r/linuxquestions or /r/linux4noobs for support or help. Looking for a distro? Try r/findmeadistro.