Skip to content
This repository has been archived by the owner on Mar 6, 2021. It is now read-only.

Commit

Permalink
Enhancement: Update README.md to reflect migration to yml format
Browse files Browse the repository at this point in the history
  • Loading branch information
localheinz committed Aug 14, 2019
1 parent a5b5902 commit 09dd8aa
Showing 1 changed file with 27 additions and 19 deletions.
46 changes: 27 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,30 +10,38 @@ That is, when you enable this action, the action will fail when a `composer.json

## Usage

Define a workflow in `.github/main.workflow` like this:
Define a workflow in `.github/workflows/ci.yml` (or add a job if you alread have defined workflows) like this:

```
workflow "Main" {
on = "push"
resolves = ["composer-normalize"]
}
action "composer-normalize" {
uses = "docker://localheinz/composer-normalize-action"
}
```yaml
name: CI

on: push

jobs:
composer-normalize:
name: composer-normalize
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Run localheinz/composer-normalize
uses: docker://localheinz/composer-normalize-action
```
You can also use a specific tag, for example, `x.y.z` (otherwise, `latest` will be used).

```
workflow "Main" {
on = "push"
resolves = ["composer-normalize"]
}
action "composer-normalize" {
uses = "docker://localheinz/composer-normalize-action:x.y.z"
}
```yaml
name: CI
on: push
jobs:
composer-normalize:
name: composer-normalize
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Run localheinz/composer-normalize
uses: docker://localheinz/composer-normalize-action:x.y.z
```

:bulb: Also see [GitHub Actions: Using a Dockerfile image in an action](https://developer.github.com/actions/managing-workflows/workflow-configuration-options/#using-a-dockerfile-image-in-an-action)
Expand Down

0 comments on commit 09dd8aa

Please sign in to comment.