Skip to content

Commit

Permalink
Merge branch 'dev' of https://github.com/CIFriends/prp-preprocessor i…
Browse files Browse the repository at this point in the history
…nto dev
  • Loading branch information
brenoepics committed May 25, 2024
2 parents 0ab4e47 + ce762f5 commit 1f7aaac
Showing 1 changed file with 43 additions and 10 deletions.
53 changes: 43 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<img src="https://raw.githubusercontent.com/CIFriends/brandkit/main/no-bg/cifriends.svg" alt="Logo" width="200px">
</a>

# prp-preprocessor
_A versatile GitHub Action that enables variable replacement in files using a simple_ `{_ variable _}` _syntax._
# prp-preprocessor

_A versatile GitHub Action that enables variable replacement in files using a simple_ `{_ variable _}` _syntax._

![Release](https://img.shields.io/github/v/release/CIFriends/prp-preprocessor?include_prereleases&sort=semver&logo=github)
![GitHub Actions Workflow Status](https://img.shields.io/github/actions/workflow/status/cifriends/prp-preprocessor/ci.yml?logo=github)
Expand All @@ -19,33 +19,66 @@
>
> Read our [docs](https://github.com/CIFriends/prp-preprocessor/wiki)

## Installation

> [!TIP]
> [How to Use](https://github.com/CIFriends/prp-preprocessor/wiki/How-to-Use)
> Reference: [How to Use](https://github.com/CIFriends/prp-preprocessor/wiki/How-to-Use)
To install the PRP Preprocessor, you can add it as a step in your [GitHub Actions](https://github.com/features/actions) workflow.
To install the PRP Preprocessor, you can add it as a step in your [GitHub Actions](https://github.com/features/actions)
workflow.
Here's an example of how to
use it:

```yml
steps:
- name: Checkout # Checkout the repository
uses: actions/checkout@v4
# with:
# ref: "main" # uncomment this line to check out a specific branch
- name: PRP Preprocessor
uses: CIFriends/prp-preprocessor@dev
with:
rootDir: './example'
env:
exampleVar: "Hello, World! This is an example variable."
```
## Usage
After installing the PRP Preprocessor, you can use it to replace variables in your `.prp.<any>` files.
Here's an example of how to
use it:

<details>
<summary>Using a variable in a file</summary>

`example.prp.json`
```json
{
"name": "{_ exampleVar _}"
}
```

Output:

`example.json`
```json
{
"name": "Hello, World! This is an example variable."
}
```
</details>

## Inputs

Inputs can be found at [here](https://github.com/CIFriends/prp-preprocessor/wiki/Inputs).

## Contributing

We welcome contributions to this project! Please read our [Contributing Guide](CONTRIBUTING.md) for more information on how to contribute.
We welcome contributions to this project! Please read our [Contributing Guide](CONTRIBUTING.md) for more information on
how to contribute.

If you've found this project useful, please consider giving it a ⭐ on GitHub. This helps to spread the awareness of the project and is a great way to show your support!
If you've found this project useful, please consider giving it a ⭐ on GitHub.
This helps to spread the awareness of the
project and is a great way to show your support!

## License

Expand Down

0 comments on commit 1f7aaac

Please sign in to comment.