Closed gaocegege closed 6 years ago
进阶需求:
实现一个诸如 michael/github 的 API 抽象,便于之后为 bot 加 feature
这个 idea 可以分为两个部分
一部分是建立一个类似 hook 的机制,能够捕捉到 @ bot 的comment,然后拿到相应的 issue
另外一个部分是拿到 issue 所有的按照 https://github.com/dyweb/mos/issues/1#issue-186110914 的格式的 comment,把他们全部合并成一个 markdown,作为周报提交一个 PR
目标 repo 是 https://github.com/dyweb/weekly
需要定义好 comment 格式和合并方式什么的
嗯不过我觉得比较麻烦是前面一个,没有一个针对 issue 中的 mention 的webhook
给 repo 加个 issue create 的 webhook 就可以了吧
@ComMouse 诶? create 下一期周报 issue 时自动找上一期么?... 倒是也挺机智的 = =
忽然想到,不需要,可以按照时间来判断
捂脸
......挺好... 每周三 23:59:59 启动, lock, push, close, open......
关于 YAML,
关于 comment 具体规范.
仍然可以简单地投稿, 例如,
https://github.com/mhagger/git-when-merged the `git when-merged` utility.
被转换为
```yaml
name: https://github.com/mhagger/git-when-merged
link: https://github.com/mhagger/git-when-merged
description: >
the `git when-merged` utility.
```
完整的 Comment 则由 yaml 头和正文组成, 头有: name, type, link, description, quote, cc. 除 name 外都可选, 正文也可选.
,
接上完整的例子: (写的时候... 不熟悉的话还是在 Online YAML Parser 里写的好......)
```yaml
name: mhagger/git-when-merged
link: https://github.com/mhagger/git-when-merged
description: >
the `git when-merged` utility.
quote: >
`git when-merged` helps you figure out when and why a commit
was merged into a branch.
cc: gaocegege
```
适用于 "为什么我 merge 了一下 master 编译就跪了 / 原来是这个 commit 的锅, 它怎么进 master 的"
处理后为:
mhagger/git-when-merged, the git when-merged
utility.
git when-merged
helps you figure out when and why a commit was merged into a branch.
_@arrowrowe:_ 适用于 "为什么我 merge 了一下 master 编译就跪了 / 原来是这个 commit 的锅, 它怎么进 master 的"
cc @gaocegege
LGTM,实现的时候可以先实现第二种完整投稿,再支持简单投稿
@arrowrowe for the yaml parser, we can have a naive web page like the weekly mail sender using gh-pages, so we can have more control and don't need to see all the ads
@at15 agree :smiley:
A simple but more expressive version should also be taken into consideration, i.e.:
DongyueWeb
http://dongyueweb.com
The homepage for Dongyue Studio.
> Dongyue Studio is a studio in SJTU.
> - Freshman Friendly
> - Driven by Interest
> - Anything else
Tags: Dongyue, Project
Which is displayed as:
DongyueWeb http://dongyueweb.com
The homepage for Dongyue Studio.
Dongyue Studio is a studio in SJTU.
- Freshman Friendly
- Driven by Interest
- Anything else
Tags: Dongyue, Project
Or, we may use <!--comment-->
to distinguish from different blocks of meta.
Repository established. You can watch it, if you are interested.
Has there been any progress on that front? 😺
@gaocegege All main functional requirements are completed. It can generate weekly for current issues. However, cc
MUST be a yaml list for current version, otherwise this field will be skipped.
OK, I would be the first user :+1:
Close? @gaocegege
We should have a list, to know how many ideas have been implemented.
@gaocegege Like PR and issue count which has been used in dyweb/web-stuff or count the total number?
Hi @gaocegege, seems that @codeworm96 feel it still incomplete?
Yeah, I would reopen it.
Done? @gaocegege
@gaocegege @codeworm96 IMO this issue should be renamed to weekly generator? I was about to open a new issue for GitHub Bot but found this
Done after receiving ack from cece
@codeworm96 @gaocegege @ComMouse so, what about now?
Considering to refactor and transfer the repo to dyweb... It there anyone still writes weekly?
well ... me?
so this is a issue->gh page converter? maybe we do not need any hook or something, just a static github page reading from github API?
@at15 I mean, why do we even need a piece of server, instead of a static github page, using frontend js to fetch&parse&render?
@xplorld github API limit and it would be relatively slow to end user. The generator does not need a server, run locally or on a CI system like Travis also works, just publish to gh-pages branch or using https://www.netlify.com/
@at15 sounds promising. However I do not think that we would have enough pageviews to trigger github api limit (逃
is it online now?
@xplorld if the user has github plugin that show detailed information when hover, he can trigger client API limit easily, it has nothing to do with us, github limits the API rate based on user's ip
cool, seen
Thank @codeworm96 for the implementation, although we have no weekly now.
\cc @dyweb/mos
idea issuer: @at15 & @gaocegege & @arrowrowe
ref https://github.com/dyweb/web-stuff/issues/113#issuecomment-256715463
外国友人 @at15 的 idea
目测要求: