<commit_before># Mostly tasken from https://github.com/guserav/dotfiles

function fish_prompt --description 'Write out the prompt'
	set laststatus $status

    set -l nix_shell_info (
      # Variable can be empty, "impure" or "pure"
      if test -n "$IN_NIX_SHELL"
        echo -n "<nix>"
      end
    )

    function _git_branch_name
        echo (git symbolic-ref HEAD ^/dev/null | sed -e 's|^refs/heads/||')
    end
    function _is_git_dirty
        echo (git status -s --ignore-submodules=dirty ^/dev/null)
    end


    #if [ (_git_branch_name) ]
    #    set -l git_branch (set_color -o blue)(_git_branch_name)
    #    if [ (_is_git_dirty) ]
    #        for i in (git branch -qv --no-color| string match -r '\*'|cut -d' ' -f4-|cut -d] -f1|tr , '\n')\
    #            (git status --porcelain | cut -c 1-2 | uniq)
    #            switch $i
    #                case "*[ahead *"
    #                    set git_status "$git_status"(set_color red)⬆
    #                case "*behind *"
    #                    set git_status "$git_status"(set_color red)⬇
    #                case "."
    #                    set git_status "$git_status"(set_color green)✚
    #                case " D"
    #                    set git_status "$git_status"(set_color red)✖<commit_msg>fish: Show when in guix environment<commit_after># Mostly tasken from https://github.com/guserav/dotfiles

function fish_prompt --description 'Write out the prompt'
	set laststatus $status

    set -l nix_shell_info (
      # Variable can be empty, "impure" or "pure"
      if test -n "$IN_NIX_SHELL"
        echo -n "<nix>"
      end
      if test -n "$GUIX_ENVIRONMENT"
        echo -n "<guix>"
      end
    )

    function _git_branch_name
        echo (git symbolic-ref HEAD ^/dev/null | sed -e 's|^refs/heads/||')
    end
    function _is_git_dirty
        echo (git status -s --ignore-submodules=dirty ^/dev/null)
    end


    #if [ (_git_branch_name) ]
    #    set -l git_branch (set_color -o blue)(_git_branch_name)
    #    if [ (_is_git_dirty) ]
    #        for i in (git branch -qv --no-color| string match -r '\*'|cut -d' ' -f4-|cut -d] -f1|tr , '\n')\
    #            (git status --porcelain | cut -c 1-2 | uniq)
    #            switch $i
    #                case "*[ahead *"
    #                    set git_status "$git_status"(set_color red)⬆
    #                case "*behind *"
    #                    set git_status "$git_status"(set_color red)⬇
    #                case "."
    #                    set git_status "$git_status"(set_color green)✚
    #                case " D"
    #                    set git_status "$git_status"(set_color red)✖
{'fraction_non_alphanumeric': 0.1256583897667419, 'fraction_numerical': 0.0030097817908201654, 'mean_word_length': 1.6696787148594376, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1679991', 'n_tokens_mistral': 935, 'n_tokens_neox': 878, 'n_words': 234}