sorellabs / fuck-you

⚠[unmaintained]⚠ (╯°□°)╯︵sǝssǝɔoɹd oʎ llɐ llıʞǝɓɐɹ
MIT License
1.28k stars 30 forks source link

Support for apps with spaces or ability to add aliases #23

Open nrj opened 8 years ago

nrj commented 8 years ago

Ideally this would work.

$ fuck you chrome
    (; ̄Д ̄) . o O( I’ve got nothing on chrome )

Less ideal.

$ fuck you google chrome
    (; ̄Д ̄) . o O( I’ve got nothing on chrome )

Meh.

$ fuck you "google chrome"
    (╯°□°)╯︵ǝɯoɹɥɔ ǝlɓooɓ(x1: 50998)
danyshaanan commented 8 years ago

11 would solve this issue.

robotlolita commented 8 years ago

You can use wildcards for matching process names partially, so fuck you *chrome will match anything that ends with chrome, and fuck you *chrome* will match anything that has chrome somewhere.

How do you envision the alias thingie working?

danyshaanan commented 8 years ago

One way to go for aliases would be to have a default .fuck-you config file with key:value pairs that is overridden by a similar ~/.fuck-you user config file if exists. Config files could be YML or a better fitting format.

An alternative solution could be to have fuck-you find similarly named processes and prompt the user for verification:

$ fuck you chrome
Do you mean 'google chrome' ? [y/N]
>

With possibly also:

$ fuck you chrome -f
(╯°□°)╯︵ǝɯoɹɥɔ ǝlɓooɓ(x1: 61002)
$
nrj commented 8 years ago

+1 for a .fuck-you config file.

# ~/.fuck-you
alias chrome="google chrome"
danyshaanan commented 8 years ago

@nrj It would be best to use some standard format that can be read without a home made parser. Think JSON and require, or YML and yaml-js.

Br1ght0ne commented 8 years ago

+1 for config, as something like fuck you atom won't work, you need to fuck you electron, so aliases would be pretty nice.