Skip to content

Commit

Permalink
chore: update workflow and readme guideline
Browse files Browse the repository at this point in the history
  • Loading branch information
yanglbme committed Dec 23, 2021
1 parent a2abf37 commit 7902ce5
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 99 deletions.
67 changes: 0 additions & 67 deletions .github/workflows/codeql-analysis.yml

This file was deleted.

17 changes: 6 additions & 11 deletions .github/workflows/compress.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
name: Compress

on:
push:
branches: [main]
paths:
- "**.jpg"
- "**.jpeg"
- "**.png"
- "**.webp"
schedule:
- cron: "0 0 * * 3"
workflow_dispatch:

jobs:
Expand All @@ -22,20 +17,20 @@ jobs:
id: calibre
uses: calibreapp/image-actions@main
with:
githubToken: ${{ secrets.GITHUB_TOKEN }}
githubToken: ${{ secrets.ACTION_TOKEN }}
compressOnly: true

- name: Commit Files
if: |
steps.calibre.outputs.markdown != ''
run: |
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git config --local user.email "szuyanglb@outlook.com"
git config --local user.name "yanglbme"
git commit -m "chore: auto compress images" -a
- name: Push Changes
if: |
steps.calibre.outputs.markdown != ''
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
github_token: ${{ secrets.ACTION_TOKEN }}
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@

由于 Gitee Pages 的访问速度很快,很多朋友会选择 Gitee Pages 部署项目(如:个人博客、开源项目国内镜像站点)。但是它不像 GitHub Pages 那样,一提交代码就能自动更新 Pages,因为 Gitee 的自动部署属于 Gitee Pages Pro 的服务。

为了实现 Gitee Pages 的自动部署,我开发了 [Gitee Pages Action](https://github.com/marketplace/actions/gitee-pages-action) ,只需要在 GitHub 项目的 Settings 页面下配置 keys,然后在 `.github/workflows/` 下创建一个工作流,引入一些配置参数即可。欢迎体验,若有使用上的问题,也欢迎随时在 [Issues](https://github.com/yanglbme/gitee-pages-action/issues) 反馈。
为了实现 Gitee Pages 的自动部署,我开发了 [Gitee Pages Action](https://github.com/marketplace/actions/gitee-pages-action) ,只需要在 GitHub 项目的 Settings 页面下配置 keys,然后在 `.github/workflows/` 下创建一个工作流,引入一些配置参数即可。欢迎 Star ⭐ 关注本项目。

欢迎体验,若有使用上的问题,也欢迎随时提交 [Issues](https://github.com/yanglbme/gitee-pages-action/issues) 反馈。

注:首次需要**手动**登录 Gitee ,点击“启动”进行 Gitee Pages 服务的部署。

Expand Down Expand Up @@ -213,6 +215,8 @@ Run yanglbme/gitee-pages-action@main

## 联系我

对于 Gitee Pages Action 有任何的疑问,还可以通过以下方式找到我。

<table>
<tr>
<td align="center" style="width: 200px;">
Expand All @@ -230,6 +234,6 @@ Run yanglbme/gitee-pages-action@main
</tr>
</table>

## License
## 许可证

MIT
35 changes: 16 additions & 19 deletions action.yml
Original file line number Diff line number Diff line change
@@ -1,34 +1,31 @@
name: 'Gitee Pages Action'
description: 'GitHub Action for Gitee Pages'
author: 'yanglbme'
name: "Gitee Pages Action"
description: "GitHub Action for Gitee Pages"
author: "yanglbme"
branding:
icon: 'git-branch'
color: 'gray-dark'
icon: "git-branch"
color: "gray-dark"
inputs:
gitee-username:
description: 'The Gitee username, like yanglbme'
description: "The Gitee username, like yanglbme"
required: true
gitee-password:
description: 'The Gitee password'
description: "The Gitee password"
required: true
gitee-repo:
description: 'The Gitee repository, like doocs/leetcode'
description: "The Gitee repository, like doocs/leetcode"
required: true
branch:
description: 'Which branch to build'
description: "Which branch to build"
required: false
default: 'master'
default: "master"
directory:
description: 'Which directory to build'
description: "Which directory to build"
required: false
default: ''
default: ""
https:
description: 'Use force https or not'
description: "Use force https or not"
required: false
default: 'true'
outputs:
result:
description: 'The result of api'
default: "true"
runs:
using: 'docker'
image: 'Dockerfile'
using: "docker"
image: "Dockerfile"

0 comments on commit 7902ce5

Please sign in to comment.