{"id":923,"date":"2022-02-07T02:57:55","date_gmt":"2022-02-07T02:57:55","guid":{"rendered":"https:\/\/262235.xyz\/?p=923"},"modified":"2022-02-07T02:57:55","modified_gmt":"2022-02-07T02:57:55","slug":"923","status":"publish","type":"post","link":"https:\/\/lyvba.com\/index.php\/2022\/02\/07\/923\/","title":{"rendered":"tmux_for_windows  \u5728windows\u4e2d\u4e00\u4e2agit bash\u5f00\u591a\u4e2a\u7a97\u53e3"},"content":{"rendered":"<h1>tmux_for_windows   <a href=\"https:\/\/github.com\/hongwenjun\/tmux_for_windows\">https:\/\/github.com\/hongwenjun\/tmux_for_windows<\/a><\/h1>\n<p>tmux\u662f\u4e00\u4e2a\u5f00\u6e90\u5de5\u5177\uff0c\u7528\u4e8e\u5728\u4e00\u4e2a\u7ec8\u7aef\u7a97\u53e3\u4e2d\u8fd0\u884c\u591a\u4e2a\u7ec8\u7aef\u4f1a\u8bdd\u3002\u672c\u5de5\u5177\u4ecemsys2\u91cc\u63d0\u53d6\uff0c\u53ef\u4ee5\u5728Git for Windows\u7684Git Bash (MingW64)\u4e0b\u6b63\u5e38\u4f7f\u7528\u3002<\/p>\n<p>\u862d\u96c5sRGB \u9f99\u82af\u5c0f\u672c\u670d\u52a1\u5668 | <a href=\"https:\/\/lyvba.com\">https:\/\/lyvba.com<\/a><\/p>\n<h3>tmux\u5728windows\u7cfb\u7edf\u4e0b\u5b89\u88c5\u4f7f\u7528<\/h3>\n<p><a href=\"https:\/\/youtu.be\/zSUwczhdtKI\">https:\/\/youtu.be\/zSUwczhdtKI<\/a><\/p>\n<p><img decoding=\"async\" src=\"https:\/\/raw.githubusercontent.com\/hongwenjun\/tmux_for_windows\/master\/tmux_for_windows.gif\" alt=\"\" title=\"\"><\/p>\n<h3>\u9996\u5148\u4f60\u8981\u4fdd\u8bc1\u5df2\u7ecf\u5b89\u88c5\u6709 Git for Windows<\/h3>\n<p>\u4e0b\u8f7d\u5730\u5740 <a href=\"https:\/\/git-scm.com\/download\/win\">https:\/\/git-scm.com\/download\/win<\/a><\/p>\n<h3>tmux for Git Bash (MingW64) \u5b89\u88c5\u5305\u4f7f\u7528<\/h3>\n<ul>\n<li>\u4e0b\u8f7d  <a href=\"https:\/\/github.com\/hongwenjun\/tmux_for_windows\/raw\/master\/tmux_for_git-bash.zip\">tmux_for_git-bash.zip<\/a><\/li>\n<li>\u91ca\u653e\u6587\u4ef6\u5230 D:Gitusr<\/li>\n<li>\u5b9e\u9645\u53ef\u6267\u884c\u6587\u4ef6\u5728 D:Gitusr\bin    mux.exe<\/li>\n<\/ul>\n<h3>tmux \u4f7f\u7528<\/h3>\n<ul>\n<li>Windows \u5f00\u59cb\u83dc\u5355 \u8fd0\u884c D:Gitgit-bash.exe<\/li>\n<li>\u547d\u4ee4\u884c\u8f93\u5165 tmux<\/li>\n<\/ul>\n<h3>git-bash\u73af\u5883\u4e0b\u547d\u4ee4\u884c\u5b89\u88c5<\/h3>\n<pre><code class=\"lang-bash\">git clone https:\/\/github.com\/hongwenjun\/tmux_for_windows.git\ncd tmux_for_windows\/\nunzip -x tmux_for_git-bash.zip  -d \/usr<\/code><\/pre>\n<h3>\u539f\u59cb\u7684 tmux for msys2 \u7684\u5b89\u88c5\u5305\uff0c\u4e0d\u9700\u8981\u4e0b\u8f7d<\/h3>\n<pre><code># tmux-2.7-1 \u65e7\u7248\u672c   tmux_for_windows\/tmux_271\na31b2636ff7540ec11a38ac4d9c95dc9  libevent-2.1.8-1-x86_64.pkg.tar.xz\na7ac01f4ccef1ecedf9ef346fb2c818e  tmux-2.7-1-x86_64.pkg.tar.xz\nba061b3687f77dde53658a95793e952e  tmux_for_git-bash.zip   # \u65e7\u7248\u672c\n\n# tmux-3.1-c1 \u65b0\u7248\u672c   tmux_for_windows\/tmux_311\n9abfa52145cf5a7e591847f58a5253e3  libevent-2.1.12-2-x86_64.pkg.tar.zst\nb433f58e1267f5582de43d2e9d78d82d  tmux-3.1.c-1-x86_64.pkg.tar.zst\n  <\/code><\/pre>\n<p><img decoding=\"async\" src=\"https:\/\/raw.githubusercontent.com\/hongwenjun\/tmux_for_windows\/master\/tmux_for_windows.png\" alt=\"\" title=\"\"><\/p>\n<h1>tmux \u542f\u7528\u9f20\u6807\u64cd\u4f5c<\/h1>\n<h3>.tmux.conf \u8bbe\u5b9a<\/h3>\n<pre><code># https:\/\/www.youtube.com\/watch?v=xTplsyQaGFs\n\n# tmux \u542f\u7528\u9f20\u6807\u64cd\u4f5c\nsetw -g mouse\nset-option -g history-limit 20000\nset-option -g mouse on\nbind -n WheelUpPane select-pane -t= ; copy-mode -e ; send-keys -M\nbind -n WheelDownPane select-pane -t= ; send-keys -M<\/code><\/pre>\n<p><img decoding=\"async\" src=\"https:\/\/raw.githubusercontent.com\/hongwenjun\/tmux_for_windows\/master\/tmux_mouse.gif\" alt=\"\" title=\"\"><\/p>\n<hr \/>\n<p><img decoding=\"async\" src=\"http:\/\/fishshell.com\/assets\/img\/Terminal_Logo2_CRT_Flat.png\" alt=\"\" title=\"\"><\/p>\n<h2>fish_for_git-bash<\/h2>\n<p>Fish \u662f<code>the friendly interactive shell<\/code>\u7684\u7b80\u79f0\uff0c\u6700\u5927\u7279\u70b9\u5c31\u662f\u65b9\u4fbf\u6613\u7528\u3002\u5f88\u591a\u5176\u4ed6 Shell \u9700\u8981\u914d\u7f6e\u624d\u6709\u7684\u529f\u80fd\uff0cFish \u9ed8\u8ba4\u63d0\u4f9b\uff0c\u4e0d\u9700\u8981\u4efb\u4f55\u914d\u7f6e\u3002<\/p>\n<h3>fish for Git Bash (MingW64) \u5b89\u88c5\u5305\u4f7f\u7528<\/h3>\n<ul>\n<li>\u4e0b\u8f7d  <a href=\"https:\/\/github.com\/hongwenjun\/tmux_for_windows\/raw\/master\/fish_for_git-bash.7z\">fish_for_git-bash.7z<\/a><\/li>\n<li>\u91ca\u653e\u6587\u4ef6\u5230 D:Git<\/li>\n<li>\u5b9e\u9645\u53ef\u6267\u884c\u6587\u4ef6\u5728 D:Gitusr\binfish.exe<\/li>\n<\/ul>\n<h3>fish \u4f7f\u7528\u6559\u7a0b<\/h3>\n<ul>\n<li><a href=\"http:\/\/fishshell.com\/docs\/current\/tutorial.html\">http:\/\/fishshell.com\/docs\/current\/tutorial.html<\/a><\/li>\n<\/ul>\n<h3>\u539f\u59cb\u7684 fish for msys2 \u7684\u5b89\u88c5\u5305\uff0c\u4e0d\u9700\u8981\u4e0b\u8f7d<\/h3>\n<pre><code>Path:  tmux_for_windows\/fish_312\n9cb0219a335d2b54c388cbf25c2ea456  bc-1.07.1-2-x86_64.pkg.tar.xz\n4fd6c824c616709966167fdc5f1a5195  fish-3.1.2-1-x86_64.pkg.tar.zst\nb882faf644ccd4770f7c3002e1dc6d71  groff-1.22.4-1-x86_64.pkg.tar.xz\n0d78c572a6cd9f0bf88e2b0ceedf62e6  libpcre2_16-10.35-1-x86_64.pkg.tar.zst\nf3d45b93b85a9d57c978224bd8111c09  libpipeline-1.5.2-1-x86_64.pkg.tar.xz\n4dd5d447bb0e160502afe95a1bafe044  man-db-2.9.3-1-x86_64.pkg.tar.zst\n<\/code><\/pre>\n<h2>\u628afish\u8bbe\u4e3a\u4ea4\u4e92\u5f0fshell<\/h2>\n<p>\u5982\u679c\u4e0d\u5c06fish\u8bbe\u4e3a\u9ed8\u8ba4shell\uff0c\u5c31\u80fd\u7167\u5e38\u8fd0\u884cBash\u7684\u521d\u59cb\u5316\u811a\u672c\u3002\u8fd9\u80fd\u591f\u4fdd\u8bc1\u7528\u6237\u5f53\u524d\u7684\u73af\u5883\u53d8\u91cf\u4e0d\u53d7\u5f71\u54cd\u5e76\u4e14\u5728fish\u4e2d\u4e5f\u80fd\u4f7f\u7528\uff0c\u56e0\u4e3afish\u662f\u4f5c\u4e3aBash\u7684\u5b50\u8fdb\u7a0b\u8fd0\u884c\u7684\u3002\u4e0b\u9762\u662f\u51e0\u79cd\u53ea\u628afish\u8bbe\u4e3a\u4ea4\u4e92\u5f0fshell\u7684\u65b9\u6cd5\u3002<\/p>\n<h3>\u901a\u8fc7.bashrc\u542f\u52a8fish<\/h3>\n<p>\u4fdd\u6301\u9ed8\u8ba4shell\u4e3aBash\u4e0d\u53d8\uff0c\u7136\u540e\u6dfb\u52a0\u4e00\u884c<strong>exec fish<\/strong>\u5230\u5408\u9002\u7684Bash\u914d\u7f6e\u6587\u4ef6\u4e2d\uff0c\u6bd4\u5982.bashrc\u3002\u5728\u8fd9\u79cd\u65b9\u6cd5\u4e2d\uff0cBash\u4f1a\u6b63\u5e38\u6267\u884c\/etc\/profile\u548c\/etc\/profile.d\u4e2d\u7684\u6240\u6709\u914d\u7f6e\u6587\u4ef6\u3002\u76f8\u5bf9\u4e8e\u4e4b\u540e\u51e0\u79cd\u65b9\u6cd5\uff0c\u8fd9\u79cd\u662f\u6700\u901a\u7528\u7684\uff0c\u56e0\u4e3a\u8fd9\u79cd\u65b9\u6cd5\u5728\u672c\u673a\u8ba1\u7b97\u673a\u548cSSH\u8fdc\u7a0b\u8ba1\u7b97\u673a\u4e0a\u90fd\u80fd\u4f7f\u7528\u3002<\/p>\n<h3>\u4f7f\u7528\u7ec8\u7aef\u590d\u7528\u5668\u7684\u9009\u9879<\/h3>\n<p>\u8981\u5c06fish\u8bbe\u4e3atmux\u542f\u52a8\u7684\u9ed8\u8ba4shell\uff0c\u5728~\/.tmux.conf\u4e2d\u52a0\u5165\u8fd9\u884c\uff1a<\/p>\n<p>set-option -g default-shell <code>\/usr\/bin\/fish<\/code><\/p>\n<h3>\u5173\u95ed\u95ee\u5019\u8bed<\/h3>\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u6bcf\u6b21\u542f\u52a8fish\uff0cfish\u90fd\u4f1a\u6253\u5370\u95ee\u5019\u8bed\u3002\u8981\u5173\u95ed\u95ee\u5019\u8bed\uff0c\u53ef\u4ee5\u5728fish\u4e2d\u8fd0\u884c\uff1a<\/p>\n<p>set -U fish_greeting<\/p>\n<h3>\u7f51\u9875\u754c\u9762<\/h3>\n<p>\u901a\u8fc7\u4e0b\u9762\u547d\u4ee4\u5373\u53ef\u7528\u6d4f\u89c8\u5668\u6253\u5f00fish\u7684\u914d\u7f6e\u9875\u9762\u3002<\/p>\n<p>fish_config<\/p>\n","protected":false},"excerpt":{"rendered":"<p>tmux_for_windows https:\/\/github.com\/hongwenjun\/tmu [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[22],"class_list":["post-923","post","type-post","status-publish","format-standard","hentry","category-linux","tag-tmux"],"_links":{"self":[{"href":"https:\/\/lyvba.com\/index.php\/wp-json\/wp\/v2\/posts\/923","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lyvba.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lyvba.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lyvba.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lyvba.com\/index.php\/wp-json\/wp\/v2\/comments?post=923"}],"version-history":[{"count":0,"href":"https:\/\/lyvba.com\/index.php\/wp-json\/wp\/v2\/posts\/923\/revisions"}],"wp:attachment":[{"href":"https:\/\/lyvba.com\/index.php\/wp-json\/wp\/v2\/media?parent=923"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lyvba.com\/index.php\/wp-json\/wp\/v2\/categories?post=923"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lyvba.com\/index.php\/wp-json\/wp\/v2\/tags?post=923"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}