Skip to content

Commit

Permalink
Modify with Copy template, Project Name pattern and String Manipulation
Browse files Browse the repository at this point in the history
  • Loading branch information
bordoni committed Feb 18, 2024
1 parent 6056663 commit a573d39
Show file tree
Hide file tree
Showing 8 changed files with 2,568 additions and 92 deletions.
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,13 @@ Once you've configured your workflow, save it as a `.yml` file in your target Re

## Inputs

- <a name="base-branch-matches">`base-branch-matches`</a> **(optional)** is a regular expression (or glob) to match the base branch name. If not provided, the action will match all base branches
- <a name="base-branch-pattern">`base-branch-pattern`</a> **(optional)** is a glob pattern to match the base branch name. If not provided, the action will match all base branches
_eg: `release/*`_ will match `release/1.0`, `release/2.0`, etc.
- <a name="base-branch-replace">`base-branch-replace`</a> **(optional)** is a regular expression to replace the base branch name to create the Project. If not provided, the base branch name will be used as the project name
_eg: `release/(.*)`_ will replace `release/1.0` with `1.0`
- <a name="name-prefix-remove">`name-prefix-remove`</a> **(optional)** Its a string to remove from the beginning of the base branch before searching for a project. If not provided, the action will use the base branch as is
_eg: `release/`_ will remove `release/` from `release/Z24.kamehameha`
- <a name="name-suffix-remove">`name-suffix-remove`</a> **(optional)** It is a string to remove from the end of the base branch before searching for a project. If not provided, the action will use the base branch as is
_eg: `-hotfix`_ will remove `-hotfix` from `release/Z24.kamehameha-hotfix`
- <a name="name-replace-with-spaces">`name-replace-with-spaces`</a> **(optional)** Its a colection of chars to replace with spaces in the base branch before searching for a project. If not provided, the action will use the base branch as is.
- <a name="template-project-url">`template-project-url`</a> **(optional)** is the URL of the project to use as a template for the new project. If not provided, the action will create a new project
\_eg: `https://github.com/orgs|users/<ownerName>/projects/<projectNumber>`
- <a name="github-token">`github-token`</a> **(required)** is a [personal access
Expand Down
18 changes: 14 additions & 4 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,22 @@ inputs:
required: true
default: 'organization'
description: The type of the owner of the repository. Can be either 'organization' or 'user'
base-branch-matches:
project-owner:
required: true
description: The Login of the owner in case we create a project.
base-branch-pattern:
required: false
description: A glob pattern to match the base branch name. If not provided, the action will match all base branches
name-prefix-remove:
required: false
description: A string that will be removed if it is found at the beginning of the base branch name
name-suffix-remove:
required: false
description: A regular expression to match the base branch name. If not provided, the action will match all base branches
base-branch-replace:
description: A string that will be removed if it is found at the end of the base branch name
name-replace-with-spaces:
default: '_'
required: false
description: A regular expression to replace the base branch name to create the Project. If not provided, the base branch name will be used as the project name
description: A set of chars that will be replaced with spaces in the base branch name
template-project-url:
required: false
description: Which template to use to create the project. If not provided, the default project template will be used.
Expand Down
Loading

0 comments on commit a573d39

Please sign in to comment.