Skip to content

Commit

Permalink
docs: fix backup script call
Browse files Browse the repository at this point in the history
  • Loading branch information
codeflorist committed Jul 13, 2024
1 parent 412afea commit 210cc19
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
13 changes: 6 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,8 @@ The restore script is able to individually restore the the resources from the ba

```shell

# simply auto-download and run via npx
## for backup:
# simply auto-download and run via npx (backup only)
$ npx storyblok-backup
## for restore:
$ npx -p storyblok-backup storyblok-restore

# or install globally
$ npm install -g storyblok-backup
Expand Down Expand Up @@ -185,7 +182,9 @@ Also keep in mind, that there is a limit on artifact storage and runner minutes

### Restore

Call `npx -p storyblok-backup storyblok-restore` with the following options:
Make sure to install the package first (see [Installation](#installation)).

Call `npx storyblok-restore` with the following options:

#### Restore options

Expand Down Expand Up @@ -235,15 +234,15 @@ Call `npx -p storyblok-backup storyblok-restore` with the following options:
#### Minimal restore example

```shell
npx -p storyblok-backup storyblok-restore --token 1234567890abcdef --space 12345 --type story --file ./.output/backup/123456789.json
npx storyblok-restore --token 1234567890abcdef --space 12345 --type story --file ./.output/backup/123456789.json
```

This will restore the story from the stated file by updating it.

#### Maximal restore example

```shell
npx -p storyblok-backup storyblok-restore \
npx storyblok-restore \
--token 1234567890abcdef \
--space 12345 \
--region ap \
Expand Down
6 changes: 3 additions & 3 deletions bin/storyblok-restore.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ const args = minimist(process.argv.slice(2))

if ('help' in args) {
console.log(`USAGE
$ npx -p storyblok-backup storyblok-restore
$ npx storyblok-restore
OPTIONS
--token <token> (required) Personal OAuth access token created
Expand Down Expand Up @@ -65,10 +65,10 @@ OPTIONS
--help Show this help
MINIMAL EXAMPLE
$ npx -p storyblok-backup storyblok-restore --token 1234567890abcdef --space 12345 --type story --file ./.output/backup/123456789.json
$ npx storyblok-restore --token 1234567890abcdef --space 12345 --type story --file ./.output/backup/123456789.json
MAXIMAL EXAMPLE
$ npx -p storyblok-backup storyblok-restore \\
$ npx storyblok-restore \\
--token 1234567890abcdef \\
--space 12345 \\
--region ap \\
Expand Down

0 comments on commit 210cc19

Please sign in to comment.