summaryrefslogtreecommitdiff
path: root/jstmax_fish_prompts.fish
blob: e009db9daed1444cb4ae5d2fe85c93493f9a3fcb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# fish_prompt
function fish_prompt
    if test "$PWD" = "/home/maxlol"
      echo -e (set_color green)$USER(set_color white)"@"(set_color green)"~"(set_color white)" :: "
    else
      echo -e (set_color green)$USER(set_color white)"@"(set_color green)$PWD(set_color white)" :: "
    end
end

# fish_right_prompt
function fish_right_prompt
        set last_status $status

        # check for which color to use
        if test $last_status -eq 0
                set color green
        else
                set color red
        end
        echo -e (set_color $color)"[$last_status]"
end