静格格 發表於 2023-8-19 17:02:00

【13.0】路飞项目的Gitee

<h1 id="一管理路飞项目">【一】管理路飞项目</h1>
<ul>
<li>忽略一下文件夹及文件</li>
</ul>
<pre><code>
.idea

*.log

__pycache__

*.pyc

scripts
</code></pre>
<h1 id="二忽视部分文件">【二】忽视部分文件</h1>
<h2 id="初识化仓库">初识化仓库</h2>
<pre><code class="language-bash">git init
</code></pre>
<pre><code>Initialized empty Git repository in E:/Old Boy/luffy/luffyCity/.git/
</code></pre>
<h2 id="查看仓库状态">查看仓库状态</h2>
<pre><code class="language-bash">git status
</code></pre>
<pre><code>On branch master

No commits yet

Untracked files:
      .gitignore
      db.sqlite3
      logs/
      luffyCity/
</code></pre>
<p><img src="https://img2023.cnblogs.com/blog/2322215/202308/2322215-20230819170218258-1183756240.png" alt="" loading="lazy"></p>
<h2 id="添加管理文件">添加管理文件</h2>
<pre><code class="language-bash">git add .
</code></pre>
<pre><code>(venv) PS E:\Old Boy\luffy\luffyCity&gt; git add .
warning: in the working copy of '.gitignore', LF will be replaced by CRLF the next time Git
touches it
(venv) PS E:\Old Boy\luffy\luffyCity&gt; git status
On branch master
</code></pre>
<h2 id="查看仓库状态-1">查看仓库状态</h2>
<pre><code class="language-bash">git status
</code></pre>
<pre><code>(venv) PS E:\Old Boy\luffy\luffyCity&gt; git status
On branch master

No commits yet

Changes to be committed:
(use "git rm --cached &lt;file&gt;..." to unstage)
      new file:   .gitignore
      new file:   db.sqlite3
      new file:   logs/__init__.py
      new file:   luffyCity/__init__.py
      new file:   luffyCity/apps/__init__.py
      new file:   luffyCity/apps/home/__init__.py
      new file:   luffyCity/apps/home/admin.py
      new file:   luffyCity/apps/home/apps.py
      new file:   luffyCity/apps/home/migrations/0001_initial.py
      new file:   luffyCity/apps/home/migrations/__init__.py
      new file:   luffyCity/apps/home/models.py
      new file:   luffyCity/apps/home/serializers/Banner_serializer.py
      new file:   luffyCity/apps/home/tests.py
      new file:   luffyCity/apps/home/urls.py
      new file:   luffyCity/apps/home/views.py
      new file:   luffyCity/apps/user/__init__.py
      new file:   luffyCity/apps/user/admin.py
      new file:   luffyCity/apps/user/apps.py
      new file:   luffyCity/apps/user/migrations/0001_initial.py
      new file:   luffyCity/apps/user/migrations/__init__.py
      new file:   luffyCity/apps/user/models.py
      new file:   luffyCity/apps/user/tests.py
      new file:   luffyCity/apps/user/urls.py
      new file:   luffyCity/apps/user/views.py
      new file:   luffyCity/asgi.py
      new file:   luffyCity/db.sqlite3
      new file:   luffyCity/utils/common_middleware.py
      new file:   luffyCity/utils/common_mixin.py
      new file:   luffyCity/utils/common_models.py
      new file:   luffyCity/utils/common_response.py
      new file:   luffyCity/utils/common_settings.py
      new file:   luffyCity/wsgi.py
      new file:   manage.py
</code></pre>
<p><img src="https://img2023.cnblogs.com/blog/2322215/202308/2322215-20230819170210938-2022276933.png" alt="" loading="lazy"></p>
<h2 id="提交注释">提交注释</h2>
<ul>
<li>将所有文件提交到本地仓库</li>
</ul>
<pre><code class="language-bash">git commit -m '第一次路飞测试'
</code></pre>
<pre><code>(venv) PS E:\Old Boy\luffy\luffyCity&gt; git commit -m '第一次路飞测试'
第一次路飞测试                           
48 files changed, 748 insertions(+)                                    
create mode 100644 .gitignore                                          
create mode 100644 db.sqlite3                                          
create mode 100644 logs/__init__.py                                    
create mode 100644 luffyCity/__init__.py                              
create mode 100644 luffyCity/apps/__init__.py                        
create mode 100644 luffyCity/apps/home/__init__.py                     
create mode 100644 luffyCity/apps/home/admin.py                        
create mode 100644 luffyCity/apps/home/apps.py                        
create mode 100644 luffyCity/apps/home/migrations/0001_initial.py      
create mode 100644 luffyCity/apps/home/migrations/__init__.py         
create mode 100644 luffyCity/apps/home/models.py                     
create mode 100644 luffyCity/apps/home/serializers/Banner_serializer.py
create mode 100644 luffyCity/apps/home/tests.py                        
create mode 100644 luffyCity/apps/home/urls.py
create mode 100644 luffyCity/apps/home/views.py
create mode 100644 luffyCity/apps/user/__init__.py
create mode 100644 luffyCity/apps/user/admin.py
create mode 100644 luffyCity/apps/user/apps.py
create mode 100644 luffyCity/apps/user/migrations/0001_initial.py
create mode 100644 luffyCity/apps/user/migrations/__init__.py
create mode 100644 luffyCity/apps/user/models.py
create mode 100644 luffyCity/apps/user/tests.py
create mode 100644 luffyCity/apps/user/urls.py
create mode 100644 luffyCity/apps/user/views.py
create mode 100644 luffyCity/asgi.py
create mode 100644 luffyCity/db.sqlite3
create mode 100644 luffyCity/libs/__init__.py
create mode 100644 luffyCity/media/banner/1.jpg
create mode 100644 luffyCity/media/banner/2.jpg
create mode 100644 luffyCity/media/banner/banner1.png
create mode 100644 luffyCity/media/banner/banner2.png
create mode 100644 luffyCity/media/banner/banner3.png
create mode 100644 luffyCity/media/banner/banner4.png
create mode 100644 luffyCity/media/icon/1.jpg
create mode 100644 luffyCity/settings/__init__.py
create mode 100644 luffyCity/settings/dev.py
create mode 100644 luffyCity/settings/prod.py
create mode 100644 luffyCity/urls.py
create mode 100644 luffyCity/utils/__init__.py
create mode 100644 luffyCity/utils/common_exceptions.py
create mode 100644 luffyCity/utils/common_logger.py
create mode 100644 luffyCity/utils/common_middleware.py
create mode 100644 luffyCity/utils/common_mixin.py
create mode 100644 luffyCity/utils/common_models.py
create mode 100644 luffyCity/utils/common_response.py
create mode 100644 luffyCity/utils/common_settings.py
create mode 100644 luffyCity/wsgi.py
create mode 100644 manage.py
</code></pre>
<p><img src="https://img2023.cnblogs.com/blog/2322215/202308/2322215-20230819170203630-305173867.png" alt="" loading="lazy"></p>
<h2 id="查看仓库状态-2">查看仓库状态</h2>
<pre><code class="language-bash">git status
</code></pre>
<pre><code>(venv) PS E:\Old Boy\luffy\luffyCity&gt; git status
On branch master
nothing to commit, working tree clean
</code></pre>
<h1 id="三推送路飞项目至远程仓库">【三】推送路飞项目至远程仓库</h1>
<h2 id="1建立远程仓库">【1】建立远程仓库</h2>
<h2 id="2添加远程仓库地址">【2】添加远程仓库地址</h2>
<pre><code class="language-shell">git remote add origin https://gitee.com/chi-meng/luffy-project.git
</code></pre>
<h2 id="3推送项目">【3】推送项目</h2>
<ul>
<li>注意这里上面我已经在本地仓库缓存过了
<ul>
<li>所以直接推上去</li>
</ul>
</li>
</ul>
<pre><code class="language-shell">git push origin master
</code></pre>
<h2 id="4远端仓库推送成功">【4】远端仓库推送成功</h2>
<p><img src="https://img2023.cnblogs.com/blog/2322215/202308/2322215-20230819170155883-636781611.png" alt="" loading="lazy"></p>


</div>
<div id="MySignature" role="contentinfo">
    <p>本文来自博客园,作者:Chimengmeng,转载请注明原文链接:https://www.cnblogs.com/dream-ze/p/17642711.html</p><br><br>
来源:https://www.cnblogs.com/dream-ze/p/17642711.html
頁: [1]
查看完整版本: 【13.0】路飞项目的Gitee