DEV Community

Daniel Mayovsky
Daniel Mayovsky

Posted on • Edited on

Bash Script for meme lords of Linux

Maybe I am slightly late to the meme, but its still worth a laugh here and there. Its a "commit sudoku" meme. Sudoku, as a misspell of Sepuku (hara-kiri, suicide, etc.). So I wrote a little script for meme and someone to type more but have a little BATMN* while doing that.

commit(){
    if [[ "$1" == "sepuku" ]]; then
        logout
    fi
    if [[ "$1" == "sudoku" ]]; then
        sudo systemctl suspend
    fi
    if [[ "$1" == "lifent" ]]; then
        sudo shutdown -P now
    fi
    fi [[ "$1" == "tensei" ]]; then
        sudo shutdown -r now
    fi
}
Enter fullscreen mode Exit fullscreen mode

So now you can logout of your SSH like a boss commit sepuku
or shut down your computer commit lifent

If you're new to Linux/bash, to use this code, you have to paste the function I wrote above to the end of your ~/.bashrc file. And activate the change to the rc file just do source ~/.bashrc.

  • BATMN - Blow Air Through My Nose, since most of the time people do exactly this, not laughing out loud.

Update

You can install this script to your ~/.bashrc by copy-pasting this command:

curl https://gitlab.com/snippets/1787198/raw | cat >> ~/.bashrc
Enter fullscreen mode Exit fullscreen mode

Top comments (5)

Collapse
 
txai profile image
Txai

git commit -m "sepuku"
git push sword heart --force
dies

Collapse
 
moopet profile image
Ben Sinclair

You need something punny to deal with reincarnation which performs a reboot with shutdown -r now.

Collapse
 
weirdmayo profile image
Daniel Mayovsky • Edited

Its hard, but I have some remote idea lol.
Since we are talking about Japanese word "Sepuku". We can also take something out of the anime Naruto, which had reincarnation in it. One of the Path's of Pain can summon a Yama the Lord of Justice, who can repair any damage done to you by chewing you. Something close to a reboot. You die (you're chewed) and come out completely new and fixed. The wielder of that ability to summon Yama is Naraka path. Which is exactly Six characters, just as I planned.
All of these commands has six characters in their name and I find it neat for them to be so.

So I guess commit naraka would be a reboot.

This makes it even more of a meme, because it is from anime, it has to do with Japanese culture overall, and is six characters as all of them. Should I add it to the script?

Collapse
 
moopet profile image
Ben Sinclair

I commend your commitment.

Thread Thread
 
weirdmayo profile image
Daniel Mayovsky • Edited

Actually. I just read the word Reincarnation in Japanese romaji is Tensei (転生). So I don't have to link characters to it. Just an actual word. I will add that to the script I guess :)

The word translates to Reincarnation literally. What is interesting is that while there is a word for Rebirth in Japanese that is much longer than 6 characters in romaji alphabet, it is exactly 6 characters if written in Kanji as so: 生まれ変わり (Umarekawari - rebirth).

So if you're japanese you can put the more common word into the script. But I am not about to type Kanji in my bash terminal.