{"id":423595,"date":"2021-04-03T21:08:07","date_gmt":"2021-04-03T13:08:07","guid":{"rendered":"http:\/\/4563.org\/?p=423595"},"modified":"2021-04-03T21:08:07","modified_gmt":"2021-04-03T13:08:07","slug":"%e5%85%b3%e4%ba%8e-phpstorm-%e7%9a%84-git-%e5%8a%9f%e8%83%bd%e7%9a%84%e5%87%a0%e4%b8%aa%e9%97%ae%e9%a2%98","status":"publish","type":"post","link":"http:\/\/4563.org\/?p=423595","title":{"rendered":"\u5173\u4e8e PhpStorm \u7684 Git \u529f\u80fd\u7684\u51e0\u4e2a\u95ee\u9898"},"content":{"rendered":"<div>\n<div>\n<div>\n<h1>                  \u5173\u4e8e PhpStorm \u7684 Git \u529f\u80fd\u7684\u51e0\u4e2a\u95ee\u9898               <\/h1>\n<p> <\/p>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : tlerbao <\/span>  <span><i><\/i> 0<\/span> <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<\/p><\/div>\n<div isfirst=\"1\"> <\/p>\n<p>\u5f53\u5e74\u4ece PhpStorm \u8f6c\u5230 VSCode \u662f\u56e0\u4e3a\u7535\u8111\u914d\u7f6e\u4f4e\uff0c\u73b0\u5728\u914d\u7f6e\u4e0a\u6765\u4e86\uff0c\u60f3\u56de\u6765\u770b\u770b\uff0c\u4eca\u665a\u5728\u6298\u817e PhpStorm \u7684 Git \u76f8\u5173\u529f\u80fd\uff0c\u6709\u4ee5\u4e0b\u51e0\u4e2a\u95ee\u9898\uff0c\u8bf7\u6307\u6559(\u6211\u88c5\u4e86\u6c49\u5316\u63d2\u4ef6\u6240\u4ee5\u4ee5\u6c49\u5316\u540e\u7684\u63d0\u95ee)\uff1a<\/p>\n<p>\u622a\u56fe\uff1a https:\/\/shengxin.oss-cn-qingdao.aliyuncs.com\/temp\/1617203802409.jpg<\/p>\n<ul>\n<li>\u201c\u53d8\u66f4\u5217\u8868\u201d\u529f\u80fd\u662f\u5426\u5c31\u662f\u8ba9\u53d8\u66f4\u5f52\u7c7b\u7684\u7c7b\u4f3c\u6587\u4ef6\u5939\u529f\u80fd\u3002<\/li>\n<li>\u4f3c\u4e4e PhpStorm \u5f31\u5316\u4e86 git add \u6982\u5ff5\uff0c\u8981\u4e48\u5728\u5de5\u4f5c\u533a\uff0c\u8981\u4e48\u5c31 commit \u4e86\uff08\u867d\u7136\u4f9d\u7136\u53ef\u4ee5 add\uff0c\u4f46\u662f\u83dc\u5355\u91cc\u5c31\u6ca1\u6709\u62c9\u56de\u5de5\u4f5c\u533a\u7684\u5feb\u6377\u65b9\u5f0f\u4e86\uff09\u3002<\/li>\n<li>\u201c\u6401\u7f6e\u529f\u80fd\u201d\uff0c\u662f\u5426\u662f PhpStorm \u5f00\u53d1\u7684\u7c7b\u4f3c git stash \u6682\u5b58\u529f\u80fd\uff0c\u53ef\u4ee5\u66f4\u6539\u6401\u7f6e\u8d77\u6765\uff08\u6682\u5b58\uff09\uff0c\u7136\u540e\u53d6\u6d88\u6401\u7f6e\uff08\u53d6\u6d88\u6682\u5b58\uff09\uff0c\u90a3\u4e48\u662f\u7528\u8fd9\u4e2a\u8fd8\u662f\u7528\u4f20\u7edf\u7684 git stash \u5462\uff1f<\/li>\n<li>\u4f3c\u4e4e phpstorm \u9ed8\u8ba4\u65e0\u6cd5\u5bf9\u5df2\u7ecf push \u5230\u8fdc\u7a0b\u4ed3\u5e93\u7684\u63d0\u4ea4\u8fdb\u884c\u64cd\u4f5c\u4e86<\/li>\n<li>\u201c\u64a4\u9500\u63d0\u4ea4\u201d\u4f3c\u4e4e\u6267\u884c\u7684\u662f reset &#8211;soft \uff1f\u4e0d\u8fc7\u53ea\u80fd\u64a4\u9500\u6700\u540e\u4e00\u6761<\/li>\n<li>\u201c\u5220\u9664\u63d0\u4ea4\u201d\u662f reset &#8211;hard \uff1f<\/li>\n<li>&#8220;\u6062\u590d\u63d0\u4ea4&#8221; \u8fd9\u4e2a\u4f3c\u4e4e\u662f revert\uff0c\u4ee5\u524d\u90fd\u6ca1\u7528\u8fc7\uff0c\u4e0d\u77e5\u9053\u662f\u5e72\u4ec0\u4e48\u7684<\/li>\n<li>squash \u63d0\u4ea4\u6211\u662f\u77e5\u9053\u662f\u5408\u5e76\u591a\u6761\u63d0\u4ea4\uff0c\u4f46\u662f \u201csquash \u5230..\u201d \u8fd9\u4e2a\u529f\u80fd\u5230\u5e95\u662f\u5e72\u4ec0\u4e48\u7684\uff1f <\/li>\n<\/ul>\n<p>\u6682\u65f6\u8fd9\u4e48\u591a\uff0c\u6709\u7ecf\u5e38\u7528\u8fd9\u4e2a\u529f\u80fd\u7684\u5c0f\u54e5\u4ecb\u7ecd\u4e0b\u6280\u5de7\u6700\u597d\u4e86\uff0c\u4ee5\u524d\u90fd\u662f\u4e60\u60ef\u547d\u4ee4\u884c\uff0c\u7528\u754c\u9762\u603b\u611f\u89c9\u4e0d\u5b89\u5168\uff0c\u5f97\u77e5\u9053\u5177\u4f53\u6267\u884c\u7684\u662f\u4ec0\u4e48\u547d\u4ee4\u54c8\u3002<\/p>\n<\/p><\/div>\n<div> <b>\u5927\u4f6c\u6709\u8a71\u8aaa<\/b> (<span>2<\/span>)        <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<ul>\n<li data-pid=\"5626791\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : xupefei <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u6211\u63a8\u8350\u7528\u7b2c\u4e09\u65b9\u5de5\u5177\u6bd4\u5982 sourcetree \u6216 fork \u3002<br \/>Intellij \u7cfb\u7684\u51b2\u7a81\u89e3\u51b3\u9875\u9762\u5b9e\u5728\u592a\u8fc7\u5783\u573e\uff0c\u6211\u76f4\u5230\u73b0\u5728\u4e5f\u641e\u4e0d\u61c2\u5230\u5e95\u54ea\u8fb9\u88ab\u91c7\u7eb3\u4e86\u54ea\u8fb9\u88ab\u629b\u5f03\u4e86\u3002                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"5626792\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u4e3b<\/span> <span>\u8cc7\u6df1\u5927\u4f6c : tlerbao <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @xupefei \u54c7 \u6628\u665a \u6211\u5c1d\u8bd5\u4e86\u4e00\u4e0b \u4e5f\u6ca1\u641e\u660e\u767d\u54c8\u54c8 \u90a3\u4e2a\u5904\u7406\u51b2\u7a81\u754c\u9762\u770b\u4e0d\u61c2                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li>\n","protected":false},"excerpt":{"rendered":"<p>\u5173\u4e8e PhpStorm \u7684 Git&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[],"tags":[],"_links":{"self":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/423595"}],"collection":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=423595"}],"version-history":[{"count":0,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/423595\/revisions"}],"wp:attachment":[{"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=423595"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=423595"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=423595"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}