Skip to content

Insulta l'utente quando digita comandi sbagliati

License

Notifications You must be signed in to change notification settings

Fastbyte01/ti-insulto

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

64 Commits
 
 
 
 
 
 

Repository files navigation

Ti insulto

Codacy Badge

Insulta l'utente quando scrive comandi sbagliati.

Cambia gli insulti come preferisci :)

fastbyte01@fastbyte:~ $ sl

  Lascia stare non fa per te

-bash: sl: command not found
fastbyte01@fastbyte:~ $ gti status

  Non hai niente di meglio da fare?!

-bash: gti: command not found
fastbyte01@fastbyte:~ $ sp aux

  A volte mi fai davvero paura

-bash: sp: command not found

Compatibilità

  • Bash v4 e successivo
  • Zsh

Installazione

# Metodo 1 - Sai quello che stai facendo
git clone https://github.com/Fastbyte01/ti-insulto.git ti-insulto
sudo cp ti-insulto/src/bash.command-not-found /etc/

Per utilizzare lo script al login bisogna aggiungere il seguente codice nel file /etc/bash.bashrc o in una posizione differente dove puoi configurare automaticamente la tua shell durante il login (zsh ha dei file di configurazione diversi):

if [ -f /etc/bash.command-not-found ]; then
    . /etc/bash.command-not-found
fi

Esegui il logout e poi di nuovo il login. A questo punto, quando digiti dei comandi sbagliati l'effetto sarà visibile.

Configurazione

Ti insulto può essere personalizzato inserendo delle nuove frasi nelle variabili d'ambientec CMD_NOT_FOUND_MSGS o CMD_NOT_FOUND_MSGS_APPEND. I valori devono essere degli array. CMD_NOT_FOUND_MSGS rimpiazza i messaggi di default, mentre CMD_NOT_FOUND_MSGS_APPEND aggiunge altri messaggi a quelli esistenti.

About

Insulta l'utente quando digita comandi sbagliati

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages

  • Shell 100.0%