{"action":"created","issue":{"url":"https://api.github.com/repos/fish-shell/fish-shell/issues/1141","labels_url":"https://api.github.com/repos/fish-shell/fish-shell/issues/1141/labels{/name}","comments_url":"https://api.github.com/repos/fish-shell/fish-shell/issues/1141/comments","events_url":"https://api.github.com/repos/fish-shell/fish-shell/issues/1141/events","html_url":"https://github.com/fish-shell/fish-shell/issues/1141","id":23227300,"number":1141,"title":"fish_config doesn't seem to install vars in prompts","user":{"login":"nafg","id":98384,"avatar_url":"https://avatars.githubusercontent.com/u/98384?v=3","gravatar_id":"","url":"https://api.github.com/users/nafg","html_url":"https://github.com/nafg","followers_url":"https://api.github.com/users/nafg/followers","following_url":"https://api.github.com/users/nafg/following{/other_user}","gists_url":"https://api.github.com/users/nafg/gists{/gist_id}","starred_url":"https://api.github.com/users/nafg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nafg/subscriptions","organizations_url":"https://api.github.com/users/nafg/orgs","repos_url":"https://api.github.com/users/nafg/repos","events_url":"https://api.github.com/users/nafg/events{/privacy}","received_events_url":"https://api.github.com/users/nafg/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/fish-shell/fish-shell/milestones/7","html_url":"https://github.com/fish-shell/fish-shell/milestones/next-major","labels_url":"https://api.github.com/repos/fish-shell/fish-shell/milestones/7/labels","id":339734,"number":7,"title":"next-major","description":"Fixes for the next major release.\r\n\r\nFixes that break backward compatibility must be targeted to this release.","creator":{"login":"ridiculousfish","id":920838,"avatar_url":"https://avatars.githubusercontent.com/u/920838?v=3","gravatar_id":"","url":"https://api.github.com/users/ridiculousfish","html_url":"https://github.com/ridiculousfish","followers_url":"https://api.github.com/users/ridiculousfish/followers","following_url":"https://api.github.com/users/ridiculousfish/following{/other_user}","gists_url":"https://api.github.com/users/ridiculousfish/gists{/gist_id}","starred_url":"https://api.github.com/users/ridiculousfish/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ridiculousfish/subscriptions","organizations_url":"https://api.github.com/users/ridiculousfish/orgs","repos_url":"https://api.github.com/users/ridiculousfish/repos","events_url":"https://api.github.com/users/ridiculousfish/events{/privacy}","received_events_url":"https://api.github.com/users/ridiculousfish/received_events","type":"User","site_admin":false},"open_issues":77,"closed_issues":1,"state":"open","created_at":"2013-05-22T20:34:40Z","updated_at":"2015-08-28T04:01:16Z","due_on":null,"closed_at":null},"comments":3,"created_at":"2013-11-25T08:15:45Z","updated_at":"2015-08-28T11:32:10Z","closed_at":null,"body":"e.g. I run fish_config, under Informative Git Prompt I see:\r\n\r\n````\r\nset -g __fish_git_prompt_show_informative_status 1\r\nset -g __fish_git_prompt_hide_untrackedfiles 1\r\n\r\nset -g __fish_git_prompt_color_branch magenta bold\r\nset -g __fish_git_prompt_showupstream \"informative\"\r\nset -g __fish_git_prompt_char_upstream_ahead \"↑\"\r\nset -g __fish_git_prompt_char_upstream_behind \"↓\"\r\nset -g __fish_git_prompt_char_upstream_prefix \"\"\r\n\r\nset -g __fish_git_prompt_char_stagedstate \"●\"\r\nset -g __fish_git_prompt_char_dirtystate \"✚\"\r\nset -g __fish_git_prompt_char_untrackedfiles \"…\"\r\nset -g __fish_git_prompt_char_conflictedstate \"✖\"\r\nset -g __fish_git_prompt_char_cleanstate \"✔\"\r\n\r\nset -g __fish_git_prompt_color_dirtystate blue\r\nset -g __fish_git_prompt_color_stagedstate yellow\r\nset -g __fish_git_prompt_color_invalidstate red\r\nset -g __fish_git_prompt_color_untrackedfiles $fish_color_normal\r\nset -g __fish_git_prompt_color_cleanstate green bold\r\n\r\n\r\nfunction fish_prompt --description 'Write out the prompt'\r\n\r\n  set -l last_status $status\r\n\r\n  if not set -q __fish_prompt_normal\r\n    set -g __fish_prompt_normal (set_color normal)\r\n  end\r\n\r\n  # PWD\r\n  set_color $fish_color_cwd\r\n  echo -n (prompt_pwd)\r\n  set_color normal\r\n\r\n  printf '%s ' (__fish_git_prompt)\r\n\r\n  if not test $last_status -eq 0\r\n  set_color $fish_color_error\r\n  end\r\n\r\n  echo -n '$ '\r\n\r\nend\r\n````\r\n\r\nAfter clicking Use Prompt, the prompt is somewhat changed but the colors and symbols seem to be missing. The function has been added to ~/.config/fish/functions/fish_prompt.fish but not the `set` lines. Adding them to that file fixes the prompt.\r\nRestarting fish did not seem to help.\r\n"},"comment":{"url":"https://api.github.com/repos/fish-shell/fish-shell/issues/comments/135745319","html_url":"https://github.com/fish-shell/fish-shell/issues/1141#issuecomment-135745319","issue_url":"https://api.github.com/repos/fish-shell/fish-shell/issues/1141","id":135745319,"user":{"login":"walles","id":158201,"avatar_url":"https://avatars.githubusercontent.com/u/158201?v=3","gravatar_id":"","url":"https://api.github.com/users/walles","html_url":"https://github.com/walles","followers_url":"https://api.github.com/users/walles/followers","following_url":"https://api.github.com/users/walles/following{/other_user}","gists_url":"https://api.github.com/users/walles/gists{/gist_id}","starred_url":"https://api.github.com/users/walles/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/walles/subscriptions","organizations_url":"https://api.github.com/users/walles/orgs","repos_url":"https://api.github.com/users/walles/repos","events_url":"https://api.github.com/users/walles/events{/privacy}","received_events_url":"https://api.github.com/users/walles/received_events","type":"User","site_admin":false},"created_at":"2015-08-28T11:32:10Z","updated_at":"2015-08-28T11:32:10Z","body":"I have the same issue with fish 2.2.0 on Mac OS X and \"Informative Git Prompt\".\r\n\r\nThe global vars aren't written to neither `~/.config/fish/functions/fish_prompt.fish` nor `~/.config/fish/fishd.*`.\r\n\r\nIt did work with the \"Debian chroot\" prompt, which makes me think it's the definition of Informative Git Prompt that is wrong in some way.\r\n\r\nThose set commands for example, should they be \"-g\" or \"-U\"?"}}