• 【Vegas原创】vscode使用github



    1, vscode打开terminal,生成RSA密钥,并查看蜜月

    PS D:codeSQL> git init
    Reinitialized existing Git repository in D:/code/SQL/.git/
    PS D:codeSQL> git config --global user.name amadeus
    PS D:codeSQL> git config --global user.email vegas_lee@163.com
    PS D:codeSQL> ssh-keygen -t rsa -C "vegas_lee@163.com"
    Generating public/private rsa key pair.
    Enter file in which to save the key (C:Usersvegas/.ssh/id_rsa): 
    Enter passphrase (empty for no passphrase): 
    Enter same passphrase again: 
    Your public key has been saved in C:Usersvegas/.ssh/id_rsa.pub.
    The key fingerprint is:
    SHA256:JTEfU8+j6+dxrYqoiCy+jbUNHUXCQGvF3rY/6FFjC5E vegas_lee@163.com
    The key's randomart image is:
    +---[RSA 3072]----+
    |  .o+o .o o..    |
    |    ooo .+ o o   |
    |   o. .E. o   +  |
    |  .  ..o.o   . . |
    |     ...S+  .    |
    |    . ..+ o  .  .|
    |   o . .o.  . . o|
    |..+.+. ..+ o  .+ |
    |.=+o..oo. o o+o  |
    +----[SHA256]-----+
    PS D:codeSQL> cat ~/.ssh/id_rsa.pub
    ssh-rsa me5Aomus6IQmsIRT+tGpWsSSuKhe7WrJhPQmuDl vegas_lee@163.com
    PS D:codeSQL>

    image


    2,打开github网站,进入仓库,进入setting,设置deploy keys,将id_rsa.pub中的内容粘贴进去即可。

    image


    3,terminal绑定本地文件夹和GitHub仓库,并做连接测试:

    PS D:codeSQL> git remote add ztsql git@github.com:vegaslee/sql.git
    PS D:codeSQL> ssh -T git@github.com
    Hi vegaslee/sql! You've successfully authenticated, but GitHub does not provide shell access.


    4,做一次推送

    PS D:codeSQL> git push --force ztsql master 
    Enumerating objects: 110, done.
    Counting objects: 100% (110/110), done.
    Delta compression using up to 8 threads
    Compressing objects: 100% (107/107), done.
    Writing objects: 100% (110/110), 68.98 KiB | 255.00 KiB/s, done.
    Total 110 (delta 18), reused 0 (delta 0), pack-reused 0
    remote: Resolving deltas: 100% (18/18), done.
    To github.com:vegaslee/sql.git
     * [new branch]      master -> master
    PS D:codeSQL>
    喜欢请赞赏一下啦^_^
  • 相关阅读:
    CSS经典实用技巧10招
    分析与设计数据库模型的简单过程
    MS SQL数据类型及长度限制
    firefox与IE的nextSibling
    DIV+CSS布局总结
    Sql Server查找临时表,并删除
    powerDesigner15.1破解
    分别使用函数及游标实现SQL多行转一列
    生命的帐单
    北京有380万“北漂族” 没有归属感但不离不弃!
  • 原文地址:https://www.cnblogs.com/amadeuslee/p/15405898.html
Copyright © 2020-2023  润新知