Gitfolio

每个 github 用户的个人网站 + 博客。(personal website + blog for every github user)

Github stars Tracking Chart

Gitfolio

每个 github 用户的个人网站 + 博客。

Gitfolio 将帮助你开始一个作品集网站,在那里你可以展示你的工作,还有一个博客,将帮助你把你的想法传播到现实世界。

请看这个 在线演示,看看 gitfolio 的实际操作。

入门

让我们来安装

安装 gitfolio

npm i gitfolio -g

让我们来构建

使用用户界面

$ gitfolio ui

提示:你可以使用 ui 来创建新的博客,也可以更新你的文件夹。

gitfolio build <username>

<username> 是你在 github 上的用户名。这将使用你的 GitHub 用户名建立你的网站,并将其放在 /dist 文件夹中。

要运行您的网站,请使用运行命令,默认端口为3000。

gitfolio run -p [port]

恭喜你,你刚刚为自己建立了一个个人网站!

让我们来定制

Forks

要在你的个人网站上加入 forks,只需在建立网站时提供 -f 或 -fork 参数。

$ gitfolio build <username> -f

Sorting Repos

要对仓库进行排序,需要在构建时提供 --sort [sortBy] 参数,其中 [sortBy] 可以是 star, created, updated, pushed, full_name。其中 [sortBy] 可以是 star, created, updated, pushed, full_name。默认:created

$ gitfolio build <username> --sort star

Ordering Repos

要对排序后的仓库进行排序,需要在构建时提供 --order [orderBy] 参数。其中 [orderBy] 可以是升序或降序。默认:asc

$ gitfolio build <username> --sort star --order desc

自定义主题

当运行编译命令时,可以使用 --theme [主题名称] 标志来指定主题。可用的主题有

  • light
  • dark

TODO: 增加更多主题

例如,下面的命令将建立一个深色主题的网站。

$ gitfolio build <username> --theme dark

自定义背景图片

要自定义背景图片,只需在构建时提供 --background [url] 参数。

$ gitfolio build <username> --background https://images.unsplash.com/photo-1557277770-baf0ca74f908?w=1634

你也可以在 index.css 中加入你的自定义 CSS,让它更有个性。

在你的个人资料上添加社交媒体链接

构建的同时,将 Twitter、LinkedIn、Medium 和 Dribbble 链接到你的个人资料,

gitfolio build <username> --twitter <twitter_username> --linkedin <linkedin_username> --medium <medium_username> --dribbble <dribbble_username>

让我们来发布

到 GitHub 上创建一个新的仓库,命名为 username.github.io,其中 username 是你的用户名。把里面的文件 /dist 文件夹推送到你刚刚创建的 repo。

转到 username.github.io,你的网站应该就可以了!

更新

要更新您的信息,只需运行

$ gitfolio update

或使用 gitfolio 用户界面中的更新选项。

这将更新你的信息和你的仓库信息。

要更新背景或主题,你需要再次运行构建命令。

添加博客

要添加你的第一个博客,请使用用户界面。

$ gitfolio ui

这将打开一个 UI 页面,你可以点击 "新建博客" 来创建一个新的博客。一旦你写完你的博客,你可以点击创建博客。

这将在 ./dist/blog 文件夹内创建一个博客。

在你的终端中寻找成功或错误。

这也将内容添加到 blog.json 文件中。这个文件有助于在你的个人网站上以 卡片 的形式展示你的博客。你可以自定义 JSON 对象,对应你当前的博客。

博客演示?在这里

博客的默认 JSON 格式

{
  "url_title": "my-first-blog", // the title you provide while creating a new blog, this appears in url
  "title": "Lorem ipsum dolor sit amet", // main title of blog
  "sub_title": "Lorem ipsum dolor sit amet, consectetur adipiscing elit.", // sub-title of blog
  "top_image": "https://images.unsplash.com/photo-1553748024-d1b27fb3f960?w=1450", // main image of blog
  "visible": true // don't worry about this
}

在 twitter 上关注我,获取更多更新信息 @imfunnieee

许可证

GitHub


(First version translated and edited by vz on 2020.12.19)

Overview

Name With Ownerimfunniee/gitfolio
Primary LanguageJavaScript
Program languageHTML (Language Count: 4)
PlatformLinux, Mac, Windows
License:GNU General Public License v3.0
Release Count6
Last Release Namev0.1.5 (Posted on )
First Release Namev0.1.0 (Posted on )
Created At2019-05-06 16:50:05
Pushed At2022-02-19 12:44:41
Last Commit At2022-02-19 18:14:18
Stargazers Count6.3k
Watchers Count60
Fork Count677
Commits Count129
Has Issues Enabled
Issues Count56
Issue Open Count0
Pull Requests Count31
Pull Requests Open Count0
Pull Requests Close Count43
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private

Gitfolio

Tweet GitHub release npm GitHub top language GitHub last commit GitHub code style: prettier

personal website + blog for every github user

Gitfolio will help you get started with a portfolio website where you could showcase your work + a blog that will help you spread your ideas into real world.

Check out this live demo to see gitfolio in action.

Getting Started

Let's Install

Install gitfolio

npm i gitfolio -g

Let's Build

Using the UI

$ gitfolio ui

Tip: You can use ui to create new blogs and for updating your folio too.

or

gitfolio build <username>

<username> is your username on github. This will build your website using your GitHub username and put it in the /dist folder.

To run your website use run command, Default port is 3000

gitfolio run -p [port]

? Congrats, you just made yourself a personal website!

Let's Customize

Forks

To include forks on your personal website just provide -f or --fork argument while building

$ gitfolio build <username> -f

Sorting Repos

To sort repos provide --sort [sortBy] argument while building. Where [sortBy] can be star, created, updated, pushed,full_name. Default: created

$ gitfolio build <username> --sort star

Ordering Repos

To order the sorted repos provide --order [orderBy] argument while building. Where [orderBy] can be asc or desc. Default: asc

$ gitfolio build <username> --sort star --order desc

Customize Themes

Themes are specified using the --theme [theme-name] flag when running the build command. The available themes are

  • light
  • dark

TODO: Add more themes

For example, the following command will build the website with the dark theme

$ gitfolio build <username> --theme dark

Customize background image

To customize the background image just provide --background [url] argument while building

$ gitfolio build <username> --background https://images.unsplash.com/photo-1557277770-baf0ca74f908?w=1634

You could also add in your custom CSS inside index.css to give it a more personal feel.

Twitter, LinkedIn, Medium & Dribbble links to your profile while building

gitfolio build <username> --twitter <twitter_username> --linkedin <linkedin_username> --medium <medium_username> --dribbble <dribbble_username>

Let's Publish

Head over to GitHub and create a new repository named username.github.io, where username is your username. Push the files inside/dist folder to repo you just created.

Go To username.github.io your site should be up!!

Updating

To update your info, simply run

$ gitfolio update

or use the Update options in gitfolio's UI

This will update your info and your repository info.

To Update background or theme you need to run build command again.

Add a Blog

To add your first blog use the UI.

$ gitfolio ui

This will open up a UI page and you can click on New Blog to create a new blog. Once you are done writing your blog you can hit the Create Blog.

This will create a blog inside ./dist/blog folder.

Look for success or error in your terminal.

This also adds content to blog.json file. This file helps in showcasing your blogs on your personal website as cards. You could customize the JSON object that corresponds your current blog.

Blog Demo? here

Blog's default JSON Format

{
  "url_title": "my-first-blog", // the title you provide while creating a new blog, this appears in url
  "title": "Lorem ipsum dolor sit amet", // main title of blog
  "sub_title": "Lorem ipsum dolor sit amet, consectetur adipiscing elit.", // sub-title of blog
  "top_image": "https://images.unsplash.com/photo-1553748024-d1b27fb3f960?w=1450", // main image of blog
  "visible": true // don't worry about this
}

Follow me on twitter for more updates @imfunnieee

License

GitHub

To the top