Skip to content
This repository was archived by the owner on Feb 11, 2022. It is now read-only.

Commit 9b977fa

Browse files
committed
fix README
1 parent 0280c74 commit 9b977fa

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

README.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ This Action for hexo enables arbitrary actions with the hexo command-line client
66

77
An example workflow to clean, generate, and deploy an hexo to the default public registry follows:
88

9+
### 1. HCL syntax (not recommend, [it will be deprecated on September 30, 2019](https://help.github.com/en/articles/migrating-github-actions-from-hcl-syntax-to-yaml-syntax#about-the-new-yaml-syntax-for-github-actions))
10+
911
```hcl
1012
workflow "Clean, Generate, and Deploy" {
1113
on = "push"
@@ -34,6 +36,33 @@ action "Deploy" {
3436
}
3537
```
3638

39+
### 2. YAML syntax (recommed, [how to migration](https://help.github.com/en/articles/migrating-github-actions-from-hcl-syntax-to-yaml-syntax#converting-workflow-files-in-your-repository-to-yaml-syntax))
40+
41+
```yaml
42+
on: push
43+
name: Deploy
44+
jobs:
45+
build:
46+
name: Build
47+
runs-on: ubuntu-latest
48+
steps:
49+
- name: Clean
50+
uses: heowc/action-hexo@master
51+
with:
52+
args: clean
53+
- name: Generate
54+
uses: heowc/action-hexo@master
55+
with:
56+
args: generate
57+
- name: Deploy
58+
uses: heowc/action-hexo@master
59+
env:
60+
EMAIL: input emial ...
61+
NAME: input name ...
62+
with:
63+
args: deploy
64+
65+
```
3766
### Environment variables
3867

3968
If using `hexo-deployer-git` when `Deploy` action,

0 commit comments

Comments
 (0)