{"id":21541,"date":"2024-11-19T15:53:03","date_gmt":"2024-11-19T07:53:03","guid":{"rendered":"https:\/\/fwq.ai\/blog\/21541\/"},"modified":"2024-11-19T15:53:03","modified_gmt":"2024-11-19T07:53:03","slug":"git-stash%e6%80%8e%e4%b9%88%e6%b8%85%e7%a9%ba","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/21541\/","title":{"rendered":"git stash\u600e\u4e48\u6e05\u7a7a"},"content":{"rendered":"<blockquote><p>\n  \u8981\u6e05\u7a7a git \u4ed3\u5e93\u4e2d\u7684\u6240\u6709 stash\uff0c\u8bf7\u6267\u884c\u4ee5\u4e0b\u6b65\u9aa4\uff1a1. \u68c0\u67e5\u662f\u5426\u5b58\u5728 stash\uff1b2. \u8fd0\u884c git stash clear \u547d\u4ee4\u6e05\u7a7a\u6240\u6709 stash\uff1b3. \u518d\u6b21\u8fd0\u884c git stash list \u547d\u4ee4\u9a8c\u8bc1 stash \u662f\u5426\u5df2\u6e05\u7a7a\u3002\n<\/p><\/blockquote>\n<p><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/202405\/30\/2024053023335767793.jpg\" class=\"aligncenter\" title=\"git stash\u600e\u4e48\u6e05\u7a7a\u63d2\u56fe\" alt=\"git stash\u600e\u4e48\u6e05\u7a7a\u63d2\u56fe\" \/><\/p>\n<p><strong>\u5982\u4f55\u6e05\u7a7a Git \u4ed3\u5e93\u4e2d\u7684\u6240\u6709 Stash<\/strong><\/p>\n<p>Git Stash \u547d\u4ee4\u53ef\u7528\u4e8e\u5c06\u5f53\u524d\u7684\u5de5\u4f5c\u6682\u5b58\uff0c\u4ee5\u4fbf\u7a0d\u540e\u6062\u590d\uff0c\u8fd9\u5bf9\u4e8e\u5728\u4e0d\u4e22\u5931\u66f4\u6539\u7684\u60c5\u51b5\u4e0b\u5207\u6362\u5206\u652f\u6216\u5904\u7406\u51b2\u7a81\u975e\u5e38\u6709\u7528\u3002\u4f46\u662f\uff0c\u6709\u65f6\u60a8\u53ef\u80fd\u5e0c\u671b\u6e05\u7a7a Git \u4ed3\u5e93\u4e2d\u7684\u6240\u6709 Stash\u3002<\/p>\n<p>\u8981\u6e05\u7a7a Git \u4ed3\u5e93\u4e2d\u7684\u6240\u6709 Stash\uff0c\u8bf7\u6267\u884c\u4ee5\u4e0b\u6b65\u9aa4\uff1a<\/p>\n<p><strong>1. \u68c0\u67e5 Stash \u5b58\u5728<\/strong><\/p>\n<p>\u9996\u5148\uff0c\u8fd0\u884c\u4ee5\u4e0b\u547d\u4ee4\u68c0\u67e5\u662f\u5426\u5b58\u5728\u4efb\u4f55 Stash\uff1a<\/p>\n<pre>git stash list<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<p>\u5982\u679c\u8f93\u51fa\u4e3a\u7a7a\uff0c\u5219\u6ca1\u6709 Stash \u53ef\u6e05\u7a7a\u3002\u7ee7\u7eed\u6b65\u9aa4 3\u3002<\/p>\n<p><strong>2. \u6e05\u7a7a\u6240\u6709 Stash<\/strong><\/p>\n<p>\u8981\u6e05\u7a7a\u6240\u6709 Stash\uff0c\u8bf7\u8fd0\u884c\u4ee5\u4e0b\u547d\u4ee4\uff1a<\/p>\n<pre>git stash clear<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<p>\u6b64\u547d\u4ee4\u5c06\u4ece\u4ed3\u5e93\u4e2d\u5220\u9664\u6240\u6709 Stash\u3002<\/p>\n<p><strong>3. \u9a8c\u8bc1 Stash \u5df2\u6e05\u7a7a<\/strong><\/p>\n<p>\u4e3a\u4e86\u9a8c\u8bc1 Stash \u5df2\u6e05\u7a7a\uff0c\u518d\u6b21\u8fd0\u884c  stash list \u547d\u4ee4\u3002\u8f93\u51fa\u73b0\u5728\u5e94\u8be5\u4e3a\u7a7a\u3002<\/p>\n<p>\u4ee5\u4e0a\u5c31\u662f stash\u600e\u4e48\u6e05\u7a7a\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u8981\u6e05\u7a7a git \u4ed3\u5e93\u4e2d\u7684\u6240\u6709 stash\uff0c\u8bf7\u6267\u884c\u4ee5\u4e0b\u6b65\u9aa4\uff1a1. \u68c0\u67e5\u662f\u5426\u5b58\u5728 stash\uff1b2. \u8fd0\u884c git stash clear \u547d\u4ee4\u6e05\u7a7a\u6240\u6709 stash\uff1b3. \u518d\u6b21\u8fd0\u884c git stash list \u547d\u4ee4\u9a8c\u8bc1 stash \u662f\u5426\u5df2\u6e05\u7a7a\u3002 \u5982\u4f55\u6e05\u7a7a Git \u4ed3\u5e93\u4e2d\u7684\u6240\u6709 Stash Git Stash \u547d\u4ee4\u53ef\u7528\u4e8e\u5c06\u5f53\u524d\u7684\u5de5\u4f5c\u6682\u5b58\uff0c\u4ee5\u4fbf\u7a0d\u540e\u6062\u590d\uff0c\u8fd9\u5bf9\u4e8e\u5728\u4e0d\u4e22\u5931\u66f4\u6539\u7684\u60c5\u51b5\u4e0b\u5207\u6362\u5206\u652f\u6216\u5904\u7406\u51b2\u7a81\u975e\u5e38\u6709\u7528\u3002\u4f46\u662f\uff0c\u6709\u65f6\u60a8\u53ef\u80fd\u5e0c\u671b\u6e05\u7a7a Git \u4ed3\u5e93\u4e2d\u7684\u6240\u6709 Stash\u3002 \u8981\u6e05\u7a7a Git \u4ed3\u5e93\u4e2d\u7684\u6240\u6709 Stash\uff0c\u8bf7\u6267\u884c\u4ee5\u4e0b\u6b65\u9aa4\uff1a 1. \u68c0\u67e5 Stash \u5b58\u5728 \u9996\u5148\uff0c\u8fd0\u884c\u4ee5\u4e0b\u547d\u4ee4\u68c0\u67e5\u662f\u5426\u5b58\u5728\u4efb\u4f55 Stash\uff1a git stash list \u767b\u5f55\u540e\u590d\u5236 \u5982\u679c\u8f93\u51fa\u4e3a\u7a7a\uff0c\u5219\u6ca1\u6709 Stash \u53ef\u6e05\u7a7a\u3002\u7ee7\u7eed\u6b65\u9aa4 3\u3002 2. \u6e05\u7a7a\u6240\u6709 Stash \u8981\u6e05\u7a7a\u6240\u6709 Stash\uff0c\u8bf7\u8fd0\u884c\u4ee5\u4e0b\u547d\u4ee4\uff1a git stash clear [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[16],"tags":[],"class_list":["post-21541","post","type-post","status-publish","format-standard","hentry","category-16"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/21541","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/comments?post=21541"}],"version-history":[{"count":0,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/21541\/revisions"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=21541"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=21541"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=21541"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}