前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >Notes | GitHub Upload Large Files

Notes | GitHub Upload Large Files

作者头像
PyStaData
发布2020-07-21 11:02:59
6130
发布2020-07-21 11:02:59
举报
文章被收录于专栏:PyStaData

Source: https://git-lfs.github.com/

Step 01

Download[1] and install the Git command line extension. Once downloaded and installed, set up Git LFS for your user account by running:

代码语言:javascript
复制
git lfs install

Step 02

You only need to run this once per user account.

In each Git repository where you want to use Git LFS, select the file types you'd like Git LFS to manage (or directly edit your .gitattributes). You can configure additional file extensions at anytime.

代码语言:javascript
复制
git lfs track "*.psd"

Now make sure .gitattributes is tracked:

代码语言:javascript
复制
git add .gitattributes

Note that defining the file types Git LFS should track will not, by itself, convert any pre-existing files to Git LFS, such as files on other branches or in your prior commit history. To do that, use the git lfs migrate[2] command, which has a range of options designed to suit various potential use cases.

Step 03

There is no step three. Just commit and push to GitHub as you normally would.

代码语言:javascript
复制
git add file.psd
git commit -m "Add design file"
git push origin master

References

[1]

Download: https://github.com/git-lfs/git-lfs/releases/download/v2.11.0/git-lfs-windows-v2.11.0.exe

[2]

git lfs migrate: https://github.com/git-lfs/git-lfs/blob/master/docs/man/git-lfs-migrate.1.ronn?utm_source=gitlfs_site&utm_medium=doc_man_migrate_link&utm_campaign=gitlfs

本文参与 腾讯云自媒体同步曝光计划,分享自微信公众号。
原始发表:2020-05-28,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 PyStaData 微信公众号,前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
目录
  • Step 01
  • Step 02
  • Step 03
    • References
    领券
    问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档