Skip to content
This repository has been archived by the owner on May 31, 2023. It is now read-only.

pCYSl5EDgo/cat

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cat

This GitHub Action reads text from path and stores outputs.text with the content.

Usage

Pre-requisites

Create a workflow .yml file in your repositories .github/workflows directory. An example workflow is available below. For more information, reference the GitHub Help Documentation for Creating a workflow file.

Inputs

  • path - A file to read from
  • trim - Remove whitespace from both ends of a string when true. Default is false.

Outputs

  • text - A string value to hold the content

Example workflow

name: Example

on: push

jobs:
  echo:
    runs-on: ubuntu-latest
    
    steps:
    - run: echo -n -e "HELLO\n !\n World!" > text.txt

    - uses: pCYSl5EDgo/cat@master
      id: hello
      with:
        path: text.txt

    - run: echo $TEXT
      env:
        TEXT: ${{ steps.hello.outputs.text }}

License

The scripts and documentation in this project are released under the MIT License