How to change the name of a gist in github?

北城余情 提交于 2019-12-02 15:41:52
VonC

Considering the order of files within a gist is asciibetical, you can try and add one file in uppercase.

That file will come before any other and will define the name of your gist.

Note that it won't change the url of said gist, as explained in "Namespaced Gists".

Even better, you can add a file with a leading space in its name. It's virtually invisible and gives you more freedom when choosing the title and names for the files:

What I do is creating a first file with leading underscore example : '_simple gist.md' and set it's type as markdown so it also serves as description of my gist .. after reading this post, I will prefix a leading space.

An even better way is to use an ! (exclamation) in front of the name of the file that you always want to be the first in the order. That way you avoid having to add a space everytime you edit the file, as well as adding a tilde ~ to all the remaining files which can be an arbitrary long list.

My gist contained a .gitignore which sorts above a leading underscore. I ending up using two leading periods: ..FutureProcessorWithShinyExample.md

If you edit the Gist an input box with the filename appears. That can be used to change the filename.

SUNGRAIZ FARYAD

There is no need to play with file names or spaces etc. You can just set or change the name of a gist or project by editing the readme.md file.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!