Skip to content
This repository has been archived by the owner on Nov 13, 2023. It is now read-only.

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
benschwarz authored Nov 13, 2023
1 parent d96f339 commit ca349fd
Showing 1 changed file with 4 additions and 40 deletions.
44 changes: 4 additions & 40 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,44 +1,8 @@
# GitHub Actions for [Calibre](https://calibreapp.com)

Calibre’s GitHub actions wrap our powerful [command line interface](https://calibreapp.com/cli) ([source](https://github.com/calibreapp/cli)) so that you can quickly and effortlessly add Calibre to your GitHub workflows.
## Project deprecation

That means that any command from CLI can be run using actions!
`github-actions` has been deprecated in favour of using Calibre's Command-line interface (CLI) directly:

## Usage example

This example will create a snapshot for a given website that Calibre is tracking. It'll filter out non-master branch pushes. (Likely, your production environment).

```workflow
name: Create Snapshot
on:
pull_request:
jobs:
build:
name: calibreapp/github-actions
runs-on: ubuntu-latest
steps:
- name: Create Snapshot
uses: calibreapp/github-actions@main
env:
CALIBRE_API_TOKEN: ${{ secrets.CALIBRE_API_TOKEN }}
with:
command: site create-snapshot --site=${{ secrets.CALIBRE_SITE_SLUG }}
- name: Get result
run: echo "${{steps.set-result.outputs.result}}"
```

Inputs:

- `command` The Calibre CLI command to run e.g. `create snapshot --site=${{ secrets.CALIBRE_SITE_SLUG }}

Secrets:

- `CALIBRE_API_TOKEN` is required. Generate a token in Calibre with the required scopes.
- `CALIBRE_SITE_SLUG` is optional, but required for many site based commands.

References:

- [Repo](https://github.com/calibreapp/github-actions)
- [Calibre CLI](https://calibreapp.com/cli)
- [CLI Source](https://github.com/calibreapp/cli)
- [Command-line Interface documentation](https://calibreapp.com/docs/automation/cli)
- [CI/CD documentation](https://calibreapp.com/docs/integrations/ci-cd)

0 comments on commit ca349fd

Please sign in to comment.