Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/devblackops/psake-github-actions

GitHub Action to execute psake tasks
https://github.com/devblackops/psake-github-actions

github-actions powershell psake

Last synced: 23 days ago
JSON representation

GitHub Action to execute psake tasks

Awesome Lists containing this project

README

        

# psake GitHub Action

This official psake [GitHub Action](https://github.com/features/actions) allow you to run [psake](https://github.com/psake/psake) tasks as part of your GitHub workflow.

## Actions

### Task

Runs one or more psake tasks defined in a `psakeFile.ps1` in the root of the repository.
The file containing your psake tasks can be overridden via environment variables.

## Success Criteria

This action succeeds if the `psake` task(s) complete without error.

## Usage

```hcl
action "psake test" {
# Replace with the latest tag from
# https://github.com/devblackops/psake-github-action/releases
uses = "devblackops/psake-github-action@"

# If you need to change the default psakeFile name, PSDepend requirements file,
# or skip requirements installation entirely, specify here.
# See Environment Variables below for details.
env = {
PSAKE_FILE = "./psakeFile.ps1"
}

# The psake task(s) to execute
args = ["Test"]
}
```

## Environment Variables

| Name | Default | Description |
|------|---------|-------------|
| PSAKE_FILE | "./psakeFile.ps1" | The default psake task file to execute
| PSDEPEND_FILE | "./requirements.psd1" | The default PSDepend file to install dependencies from
| SKIP_REQS | "false" | Set to `"true"` to skip installing dependencies via `PSDepend`

## Arguments

Arguments to the `Task` action determine what `psake` tasks to execute.
By default, `psake` will execute a task called `Default` that is defined in the psakeFile.

Execute the `test` psake task.

```hcl
action "psake test" {
...
args = ["Test"]
}
```

Execute the `init`, `build`, and `test` psake tasks.

```hcl
action "psake test" {
...
args = ["init, build, test"]
}
```