Hacker News new | past | comments | ask | show | jobs | submit login
Fun at the Unix Terminal (regehr.org)
279 points by melqdusy on April 6, 2017 | hide | past | favorite | 55 comments



>Well, the rig utility can help, it creates a random identity. For some reason rig will never generate an identity that lives in Utah.

Heh, I was curious why that is. Was the author from UT? Afraid of breaking some laws? After looking at the source, the author has a list of 60 or so cities and they're spread across 25 states: SC, AZ, TX, OH, KS, IA, WI, MI, NJ, NY, PA, IN, VA, NC, RI, TN, WA, MS, CA, IL, CO, FL, GA, MN, NE. So UT was not the only one omitted.

Oh well, at least my curiosity was satisfied.


Is there something similar which also creates email adresses and stores the generated profiles in a database in order to retrieve them again later? May be even have the ability to store associated passwords?


Fakenamegenerator[1] will generate disposable email addresses based on the identity it cooked up. No https without paying, though...

[1]: http://www.fakenamegenerator.com


Good idea. This would occasionally be a valuable function to include in a password manager.


where can you actually find the code? For whatever reason, I can't get it from my centos distro (yum search rig, doesn't show anything related). And googling "linux rig command", I don't see any links to the actual source.



from the comment further down, you can browse Ubuntu packages, and I found it here:

http://packages.ubuntu.com/zesty/misc/rig


Instead of:

    $ fortune > my_fortune.txt
    $ say -f my_fortune.txt
One could use the underrated (bashism) process substitution:

    $ say -f <(fortune)
Which works wonders for e.g diff'ing live:

    $ diff <(ssh elvis ls -1 foo) <(ls -1 bar)


Why would you even bother with that when `say` can take a string or read from stdin?

Just use

    $ say $(fortune)
or

    $ fortune | say -f-

For bonus coolness, add "-i" (it prints the lines and highlights the current word during reading).


Because it's fun spawning a new process and watching the otherwise idle cores of your box reach 0.1% usage for a millisecond.


Don't all three of those commands spawn new processes?


Not _shell_ processes, no.


Not all commands accept input as arguments, so it's still a good trick to know.


Me having fun with true color and Unicode 9.0 characters:

https://github.com/daleroberts/tv


For those of a certain age, piping figlet into your local line printer was a fun, if noisy, way to make giant banners.


It was "banner" for me!


ERROR: lp0 on fire


I've seen a 'banner' command in some Unix versions. Often used to print the motd (message of the day) that you got when you logged in, and also by sysadmins to write a banner message to everyone's terminal like "System going down in 10 minutes" etc.


For fancy text Toilet is great too. It's like Figlet but supports colours, filters, and comes with more fonts.

https://i.stack.imgur.com/LbsmC.png


Where does the pink term border come from?


A tmux or screen theme possibly?


I had no clue about that!


Shameless plug for a CLI *say derivitive that a coworker and I made: RabbitSay. http://www.rabbitsay.wtf

  $ pip install rabbitsay
  $ rabbitsay "shameless plug"
  ┌───────────┐
  | shameless |
  |   plug    |
  └───────────┘
  (\__/) ||
  (•ㅅ•) ||
  /   づ


It is actually really easy to create custom cow templates for cowsay: https://github.com/schacon/cowsay/blob/master/cows/bunny.cow


sl [0] is always my favorite.

[0]https://github.com/mtoyoda/sl


Is there a way to lolcat sl?


> This is aimed at grade 6 students

I read through the whole thing with joy, and I am 20


Same, but I'm 36!


I can confirm that enjoyment can be found up to age 46.


Unix terminal can be endless fun with piping and process substitution. One of the reasons people like GUI is because recognition memory is usually better than recall memory.


I don't remember where did I get this from but it is a cool thing to add to your .bashrc

  #!/bin/bash
  #teach you some new commands every time you open a new terminal
  echo 'Did you know that:'
  echo $( whatis $(ls /bin | shuf | head -1))
  echo $( whatis $(ls /sbin | shuf | head -1))
  echo $( whatis $(ls /usr/bin | shuf | head -1))
edit: formatting


Does anyone have a place/site for browsing through new/popular utilities? I've been on Ubuntu for the last year and I love it, but reading this I just realised I don't have anywhere to browse or find things like this.


You can view a list of new Ubuntu packages from its website [0]. You might also want to check out the packages in the games [1], misc [2] and text [3] sections, which are full of fun utilities. You might also want to view the man pages from the games section [4].

[0] http://packages.ubuntu.com/zesty/newpkg?mode=byage

[1] http://packages.ubuntu.com/zesty/games/

[2] http://packages.ubuntu.com/zesty/misc/

[3] http://packages.ubuntu.com/zesty/text/

[4] https://linux.die.net/man/6/


Well, this is not specifically for utilities in the sense of scripts in a file, or compiled binaries, but commandlinefu.com has many Unix one-or-more-liners.

http://www.commandlinefu.com/commands/browse


I wonder if it is time for a freshmeat.net alternative?


You kids today and your fancy command lines. When I was in sixth grade, state of the art joking around with technology meant multiplying two numbers on a calculator with red LEDs and turning it upside down to (sort of) spell SHELL OIL


On Ubuntu, say isn't available by default, but I think `espeak` is, and it works mostly the same. At least, it's always been there on my Ubuntu systems, but I may have installed it manually and then forgot about it :)


For rot13, I've found it particularly helpful to have an alias set up to translate the contents of the clipboard. I basically always have a terminal on screen, so to read rot13 text I just have to copy and run a single command. On OS X:

    alias rot13='tr a-zA-Z n-za-mN-ZA-M'
    alias pbr13='pbpaste | rot13; echo'
(echo adds a newline to play well with bash; on linux I use xsel instead of pbpaste.)


Surprised nobody commented on bb yet. This thing is really impressive - and I thought that mplayer -vo caca is jaw-dropping!


and then realising the last time the BB project page was updated was 1997.. 20 years ago!

(http://aa-project.sourceforge.net/bb/)


bb is not a project, it is a demo[1] from the demoscene. It ranked 10th at abduction 1997[2].

The demoscene is an unending source of awesome and amazing. The 4k and 64k categories will blow your mind, if you ever wondered "can a FPS game could be done in under 100kB?", the answer has been released in 2004 and its name is .kkrieger[3]

[1]: http://www.pouet.net/prod.php?which=17468

[2]: http://www.pouet.net/party.php?which=75&when=1997

[3]: http://www.pouet.net/prod.php?which=12036


This is great, I've recently asked a related question about CLI commands that would be fit for kids: http://unix.stackexchange.com/questions/185988/linux-command...


A couple of days ago I created “jazzup” a fun cli utility that adds a soundtrack and movie quotes to your long running boring commands. Check it out on npm : https://www.npmjs.com/package/jazzup


Speaking of sound and CLI, I created this musical command-line alarm clock recently (in Python):

https://jugad2.blogspot.in/2016/12/jal-tarang-and-musical-al...


aafire(1) is fun too, especially in colour with fixed term font.

Likewise aaxine(1) which renders videos in ASCII art.


With friends using VLC on their linux box and unaware of the beauty of libaa/libcaca, I'd type:

    vlc --vout caca videofilename.ext
and then look at them being scared/curious/amazed in that order!


Hey, cool. Here's how to do that with `mpv` on macOS:

    $ brew install mpv --with-libcaca
    $ mpv --vo=caca --really-quiet videofilename.ext


asciiquarium and pipes, too.


I just discovered asciiworld. It can show you a worldmap with day/night shading, geodesic lines to IPs and satellites overhead. Amazing!


That's nice! I'll try to show them to my young brother (13). He's never used the Terminal before and he might find some fun in this. Thank you!


Surprised there is no fun with urandom. I clearly remember my first fun with cat'ing /dev/urandom > /dev/pcm0 back in 1999 :)


It's a shame the author polarizes having fun and learning. I've always thought of them as the same.


The same? That's pretty odd. You've never had fun without learning something at the same time, nor learned something without having fun.

For me only one of those things is true: I think I always have fun learning, but I certainly have had fun without learning anything, too.


Had no clue bc accepted new definitions.. RTFM strikes back.


He left out nyancat.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: