{"action":"created","issue":{"url":"https://api.github.com/repos/fish-shell/fish-shell/issues/2410","labels_url":"https://api.github.com/repos/fish-shell/fish-shell/issues/2410/labels{/name}","comments_url":"https://api.github.com/repos/fish-shell/fish-shell/issues/2410/comments","events_url":"https://api.github.com/repos/fish-shell/fish-shell/issues/2410/events","html_url":"https://github.com/fish-shell/fish-shell/issues/2410","id":107395922,"number":2410,"title":"How do I convert this into fish?","user":{"login":"krzkrzkrz","id":390072,"avatar_url":"https://avatars.githubusercontent.com/u/390072?v=3","gravatar_id":"","url":"https://api.github.com/users/krzkrzkrz","html_url":"https://github.com/krzkrzkrz","followers_url":"https://api.github.com/users/krzkrzkrz/followers","following_url":"https://api.github.com/users/krzkrzkrz/following{/other_user}","gists_url":"https://api.github.com/users/krzkrzkrz/gists{/gist_id}","starred_url":"https://api.github.com/users/krzkrzkrz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krzkrzkrz/subscriptions","organizations_url":"https://api.github.com/users/krzkrzkrz/orgs","repos_url":"https://api.github.com/users/krzkrzkrz/repos","events_url":"https://api.github.com/users/krzkrzkrz/events{/privacy}","received_events_url":"https://api.github.com/users/krzkrzkrz/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/fish-shell/fish-shell/labels/question","name":"question","color":"cc317c"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-09-20T14:43:18Z","updated_at":"2015-09-20T19:24:58Z","closed_at":"2015-09-20T19:24:58Z","body":"How can I convert this into fish:\r\n\r\n```\r\n#!/bin/sh\r\n\r\nif [ \"${TERM%%-*}\" = \"screen\" ]; then\r\n\tif [ -n \"$TMUX\" ]; then\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;236;rgb:32/30/2f\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;234;rgb:1d/20/21\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;235;rgb:28/28/28\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;237;rgb:3c/38/36\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;239;rgb:50/49/45\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;241;rgb:66/5c/54\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;243;rgb:7c/6f/64\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;244;rgb:92/83/74\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;245;rgb:92/83/74\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;228;rgb:f4/e8/ba\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;230;rgb:ff/ff/c8\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;229;rgb:fd/f4/c1\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;223;rgb:eb/db/b2\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;250;rgb:d5/c4/a1\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;248;rgb:bd/ae/93\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;246;rgb:a8/99/84\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;167;rgb:fb/49/34\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;142;rgb:b8/bb/26\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;214;rgb:fa/bd/2f\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;109;rgb:83/a5/98\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;175;rgb:d3/86/9b\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;108;rgb:8e/c0/7c\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;208;rgb:fe/80/19\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;88;rgb:9d/00/06\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;100;rgb:79/74/0e\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;136;rgb:b5/76/14\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;24;rgb:07/66/78\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;96;rgb:8f/3f/71\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;66;rgb:42/7b/58\\007\\033\\\\\"\r\n\t\tprintf \"\\033Ptmux;\\033\\033]4;130;rgb:af/3a/03\\007\\033\\\\\"\r\n\telse\r\n\t\tprintf \"\\033P\\033]4;236;rgb:32/30/2f\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;234;rgb:1d/20/21\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033P\\033]4;235;rgb:28/28/28\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;237;rgb:3c/38/36\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;239;rgb:50/49/45\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;241;rgb:66/5c/54\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;243;rgb:7c/6f/64\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033P\\033]4;244;rgb:92/83/74\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;245;rgb:92/83/74\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033P\\033]4;228;rgb:f4/e8/ba\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;230;rgb:ff/ff/c8\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033P\\033]4;229;rgb:fd/f4/c1\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;223;rgb:eb/db/b2\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;250;rgb:d5/c4/a1\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;248;rgb:bd/ae/93\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;246;rgb:a8/99/84\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033P\\033]4;167;rgb:fb/49/34\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;142;rgb:b8/bb/26\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;214;rgb:fa/bd/2f\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;109;rgb:83/a5/98\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;175;rgb:d3/86/9b\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;108;rgb:8e/c0/7c\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;208;rgb:fe/80/19\\007\\033\\\\\"\r\n\r\n\t\tprintf \"\\033P\\033]4;88;rgb:9d/00/06\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;100;rgb:79/74/0e\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;136;rgb:b5/76/14\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;24;rgb:07/66/78\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;96;rgb:8f/3f/71\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;66;rgb:42/7b/58\\007\\033\\\\\"\r\n\t\tprintf \"\\033P\\033]4;130;rgb:af/3a/03\\007\\033\\\\\"\r\n\tfi\r\n\r\nelif [ \"$TERM\" != \"linux\" ] && [ \"$TERM\" != \"vt100\" ] && [ \"$TERM\" != \"vt220\" ]; then\r\n\r\n\tprintf \"\\033]4;236;rgb:32/30/2f\\033\\\\\"\r\n\tprintf \"\\033]4;234;rgb:1d/20/21\\033\\\\\"\r\n\r\n\tprintf \"\\033]4;235;rgb:28/28/28\\033\\\\\"\r\n\tprintf \"\\033]4;237;rgb:3c/38/36\\033\\\\\"\r\n\tprintf \"\\033]4;239;rgb:50/49/45\\033\\\\\"\r\n\tprintf \"\\033]4;241;rgb:66/5c/54\\033\\\\\"\r\n\tprintf \"\\033]4;243;rgb:7c/6f/64\\033\\\\\"\r\n\r\n\tprintf \"\\033]4;244;rgb:92/83/74\\033\\\\\"\r\n\tprintf \"\\033]4;245;rgb:92/83/74\\033\\\\\"\r\n\r\n\tprintf \"\\033]4;228;rgb:f4/e8/ba\\033\\\\\"\r\n\tprintf \"\\033]4;230;rgb:ff/ff/c8\\033\\\\\"\r\n\r\n\tprintf \"\\033]4;229;rgb:fd/f4/c1\\033\\\\\"\r\n\tprintf \"\\033]4;223;rgb:eb/db/b2\\033\\\\\"\r\n\tprintf \"\\033]4;250;rgb:d5/c4/a1\\033\\\\\"\r\n\tprintf \"\\033]4;248;rgb:bd/ae/93\\033\\\\\"\r\n\tprintf \"\\033]4;246;rgb:a8/99/84\\033\\\\\"\r\n\r\n\tprintf \"\\033]4;167;rgb:fb/49/34\\033\\\\\"\r\n\tprintf \"\\033]4;142;rgb:b8/bb/26\\033\\\\\"\r\n\tprintf \"\\033]4;214;rgb:fa/bd/2f\\033\\\\\"\r\n\tprintf \"\\033]4;109;rgb:83/a5/98\\033\\\\\"\r\n\tprintf \"\\033]4;175;rgb:d3/86/9b\\033\\\\\"\r\n\tprintf \"\\033]4;108;rgb:8e/c0/7c\\033\\\\\"\r\n\tprintf \"\\033]4;208;rgb:fe/80/19\\033\\\\\"\r\n\r\n\tprintf \"\\033]4;88;rgb:9d/00/06\\033\\\\\"\r\n\tprintf \"\\033]4;100;rgb:79/74/0e\\033\\\\\"\r\n\tprintf \"\\033]4;136;rgb:b5/76/14\\033\\\\\"\r\n\tprintf \"\\033]4;24;rgb:07/66/78\\033\\\\\"\r\n\tprintf \"\\033]4;96;rgb:8f/3f/71\\033\\\\\"\r\n\tprintf \"\\033]4;66;rgb:42/7b/58\\033\\\\\"\r\n\tprintf \"\\033]4;130;rgb:af/3a/03\\033\\\\\"\r\nfi\r\n```"},"comment":{"url":"https://api.github.com/repos/fish-shell/fish-shell/issues/comments/141822974","html_url":"https://github.com/fish-shell/fish-shell/issues/2410#issuecomment-141822974","issue_url":"https://api.github.com/repos/fish-shell/fish-shell/issues/2410","id":141822974,"user":{"login":"krzkrzkrz","id":390072,"avatar_url":"https://avatars.githubusercontent.com/u/390072?v=3","gravatar_id":"","url":"https://api.github.com/users/krzkrzkrz","html_url":"https://github.com/krzkrzkrz","followers_url":"https://api.github.com/users/krzkrzkrz/followers","following_url":"https://api.github.com/users/krzkrzkrz/following{/other_user}","gists_url":"https://api.github.com/users/krzkrzkrz/gists{/gist_id}","starred_url":"https://api.github.com/users/krzkrzkrz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krzkrzkrz/subscriptions","organizations_url":"https://api.github.com/users/krzkrzkrz/orgs","repos_url":"https://api.github.com/users/krzkrzkrz/repos","events_url":"https://api.github.com/users/krzkrzkrz/events{/privacy}","received_events_url":"https://api.github.com/users/krzkrzkrz/received_events","type":"User","site_admin":false},"created_at":"2015-09-20T19:24:58Z","updated_at":"2015-09-20T19:24:58Z","body":"Thanks for that explanation."}}