Skip to content

Commit

Permalink
first commit
Browse files Browse the repository at this point in the history
  • Loading branch information
septs committed Mar 30, 2021
0 parents commit f5c59d0
Show file tree
Hide file tree
Showing 20 changed files with 966 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/node_modules
1 change: 1 addition & 0 deletions .husky/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
_
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npm start
4 changes: 4 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"quoteProps": "consistent",
"singleQuote": true
}
6 changes: 6 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.fixAll": true
}
}
7 changes: 7 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Copyright 2021 NiceLabs

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
50 changes: 50 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# Setup Rclone

Unofficial Rclone action

## Usage

### Pre-requisites

Create a workflow `.yml` file in your repositories `.github/workflows` directory.
An [example workflow](#example-workflow) is available below.
For more information, reference the GitHub Help Documentation for [Creating a workflow file][creating-a-workflow-file].

### Inputs

| Field | Description |
| -------------------- | ------------------------------------ |
| `github-token` | Provide an allow update secret token |
| `config` | Read config from secret |
| `config-secret-name` | Save config to secret |

### Example workflow

```yaml
name: Release

on:
push:
branches: [master]

jobs:
build:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- uses: NiceLabs/rclone-action@master
with:
github-token: ${{ secrets.SECRET_TOKEN }}
config: ${{ secrets.RCLONE_CONFIG }}
config-secret-name: RCLONE_CONFIG
- name: Upload Pre-built images
run: rclone copy source:sourcepath dest:destpath
env:
RCLONE_CONFIG_PASS: ${{ secrets.RCLONE_CONFIG_PASS }}
```
## License
[MIT LICENSE](LICENSE)
[creating-a-workflow-file]: https://help.github.com/en/articles/configuring-a-workflow#creating-a-workflow-file
24 changes: 24 additions & 0 deletions action.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Setup Rclone
description: Unofficial Rclone action
author: septs

inputs:
github-token:
description: Provide an allow update secret token
default: ${{ github.token }}
required: true
config:
description: Rclone config file
required: true
config-secret-name:
description: Rclone config save to secret name
required: false

runs:
using: node12
main: dist/main/index.js
post: dist/post/index.js

branding:
icon: shield
color: yellow
1 change: 1 addition & 0 deletions dist/main/index.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/post/index.js

Large diffs are not rendered by default.

Loading

0 comments on commit f5c59d0

Please sign in to comment.