graph TD;
A[工作目录<br>本地改动区] -->|git add| B[暂存区];
B -->|git commit| C[本地仓库<br>本地提交区];
C -->|git push| D[远端仓库<br>远端提交区];
C -->|git stash| E[贮藏区];
E -->|git stash apply| A;
%% 新增流程线
Z[任意地方] -->|摘取文件到本地改动区| A;
Z -->|另存文件覆盖本地| A;
Z -->|另存文件覆盖提交| C;
style A fill:#333,stroke:#333,stroke-width:2px;
style B fill:#333,stroke:#333,stroke-width:2px;
style C fill:#333,stroke:#333,stroke-width:2px;
style D fill:#333,stroke:#333,stroke-width:2px;
style E fill:#333,stroke:#333,stroke-width:2px;
style Z fill:#333,stroke:#333,stroke-width:2px;
首先明确几个关键基础概念,除了常见的拉取、获取、推送外,还有
如果把错误文件,提交到了远端,此时要还原提交,必须确保: