跳转到主要内容

从文件配置您的 GitHub 仓库,无需在 UI 中点击。

项目描述

https://travis-ci.org/jacquerie/github-file.svg?branch=master https://coveralls.io/repos/github/jacquerie/github-file/badge.svg?branch=master

关于

从文件配置您的 GitHub 仓库,无需在 UI 中点击。

安装

github-file 已在 PyPI 上,所以您只需

$ pip install github-file

用法

首先,您需要通过环境提供您的 GitHub 凭据。由于 github-file 使用 python-dotenv,您可以通过创建包含以下内容的 .env 文件来实现这一点

GITHUB_USER=your_username
GITHUB_PASS=your_password

接下来,您需要创建一个有效的 Githubfile。以下是一个示例

[core]
owner = jacquerie
repo = github-file
description = Configure your GitHub repository from a file,
    without having to click around in the UI.
topics = github, configuration, file

[features]
has_issues = true
has_projects = false
has_wiki = false

[merges]
allow_squash_merge = false
allow_merge_commit = false
allow_rebase_merge = true

这些选项的含义已在 GitHub API 文档 中解释,尽管目前并非所有选项都受到支持(特别是您目前无法存档仓库或配置默认分支。)

最后,运行

$ github-file update -f Githubfile

将更新您的 GitHub 仓库配置,使其与文件中描述的内容相匹配。请注意,如果您没有提供文件名,它将默认在 .github/Githubfile 中查找。

作者

Jacopo Notarstefano (@Jaconotar)

许可证

MIT

项目详情


下载文件

下载适合您平台的文件。如果您不确定选择哪个,请了解更多关于 安装包 的信息。

源代码分发

github-file-0.5.2.tar.gz (4.3 kB 查看哈希值)

上传时间 源代码

由以下支持

AWS AWS 云计算和安全赞助商 Datadog Datadog 监控 Fastly Fastly CDN Google Google 下载分析 Microsoft Microsoft PSF 赞助商 Pingdom Pingdom 监控 Sentry Sentry 错误日志 StatusPage StatusPage 状态页面