[Tip] A better way to add neofetch to your .bashrc

Let me fix it for you:

figlet Hello > .greta
3 Likes

My way of doing the same things was a little more convoluted ;

Set to run on boot : neofetch > ~/.nfet
Line in bashrc : cat /home/canoe/.nfet

Having it run in stages means that I’m not actually waiting for anything to load when I launch the terminal as it’s just pulling the contents of the file, but I like your way better. Nice to see how other people frogs do things!

1 Like

Yes, exactly!

It doesn’t matter whether you run it on boot, or after starting the terminal emulator in a separate shell session (with setsid). The important thing is not to run it in your interactive shell session, as that is just painfully slow.

As far as I can tell, there are three options you can choose from:

  1. generate the output file by running neofetch in a separate, non-interactive shell session, like suggested in the OP
  2. generate the output file by running neofetch on boot
  3. have neofetch scheduled to run periodically to generate the output file, using cron or a systemd timer.

In all three cases you cat the output file in your .bashrc.

Apart from the forth option (which is what I do): do not run neofetch at all. :wink:

It could be worse… I used to have fortune | cowsay in my bashrc… :wink:

1 Like

Well, I do have

cat reminder.txt 2> /dev/null

So if I need to remember something I just run:

echo "Buy moar beer!" > reminder.txt

And when I’m done, I just delete reminder.txt.

I rarely use it, though. Always forget it’s there. :rofl:

1 Like

Of course - some can just ignore the time lost :grin:

real	0m0.151s
user	0m0.085s
sys	0m0.047s

The fact I only run it once is a left-over from an earlier build I guess…

That’s doesn’t seem like much, but it’s plenty of time for the loading of your terminal emulator to feel like windoze.

If I run

time cat .nf

I get:

real    0.001   (cpu: 76%, mem: 3k)
user    0.001
sys     0.000

So, even on your fast computer, it’s over 150 times slower than on my crappy laptop.

Playing around in the terminal with Neofetch, I noticed that the antergos logo still exists :grinning: “neofetch --ascii_distro antergos”.

Would you say screenfetch is a better choice?

rubbish

1 Like

Hahaha :rofl: No, I see no point in having anything displayed when you open a terminal.

@anon96028917 yeah, it is.

1 Like

nobody forces you to use neofetch – hä ?

Two years old thread?