Skip to content

Commit 5a03e0a

Browse files
committed
Update README.
1 parent ed611ba commit 5a03e0a

File tree

1 file changed

+40
-1
lines changed

1 file changed

+40
-1
lines changed

Diff for: README.md

+40-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,46 @@ Manage and sync your [Miniflux](https://github.com/miniflux/v2) feeds with YAML.
1515
- Download the [latest release](https://github.com/revett/miniflux-sync/releases)
1616
- For macOS, follow these [steps](https://support.apple.com/en-il/guide/mac-help/mchleab3a043/mac)
1717

18-
## Usage
18+
## GitHub Action
19+
20+
```yaml
21+
name: Sync feeds via revett/miniflux-sync
22+
23+
on: [push]
24+
25+
jobs:
26+
Run:
27+
runs-on: ubuntu-latest
28+
29+
steps:
30+
- name: Checkout repository
31+
uses: actions/checkout@v2
32+
33+
- name: Download and read version
34+
id: get_version
35+
run: |
36+
VERSION=$(curl -s https://raw.githubusercontent.com/revett/miniflux-sync/main/VERSION)
37+
echo "VERSION=$VERSION" >> $GITHUB_ENV
38+
39+
- name: Download and extract latest release
40+
run: |
41+
curl -L https://github.com/revett/miniflux-sync/releases/download/${{ env.VERSION }}/miniflux-sync_Linux_x86_64.tar.gz | tar -xz
42+
43+
- name: Run CLI with arguments
44+
env:
45+
MINIFLUX_SYNC_ENDPOINT: ${{ secrets.MINIFLUX_SYNC_ENDPOINT }}
46+
MINIFLUX_SYNC_API_KEY: ${{ secrets.MINIFLUX_SYNC_API_KEY }}
47+
run: |
48+
if [ "${{ github.ref_name }}" == "main" ]; then
49+
./miniflux-sync sync --path feeds.yml
50+
else
51+
./miniflux-sync sync --dry-run --path feeds.yml
52+
fi
53+
```
54+
55+
> See [revett/feeds](https://github.com/revett/feeds) for an example repo.
56+
57+
## CLI
1958
2059
Configure the CLI to use and authenticate with your Miniflux instance:
2160

0 commit comments

Comments
 (0)