Skip to content

Bump debian from 12.7-slim to 12.8-slim in /action-a #165

Bump debian from 12.7-slim to 12.8-slim in /action-a

Bump debian from 12.7-slim to 12.8-slim in /action-a #165

name: Multiline output
on: push
jobs:
test:
runs-on: ubuntu-20.04
steps:
- name: define list
id: files
run: |
echo "list=test.tex \"test 2.tex\"" >>${GITHUB_OUTPUT}
- name: show space separated list
run: echo ${{ steps.files.outputs.list }}
- name: make list newline separated
id: lines
run: |
import os
import shlex
import secrets
output = '\n'.join(shlex.split(os.environ['INPUT_LIST']))
delimiter = secrets.token_hex()
with open(os.environ['GITHUB_OUTPUT'], 'a') as fh:
print(f'list<<{delimiter}\n{output}\n{delimiter}', file=fh)
shell: python3 {0}
env:
INPUT_LIST: ${{ steps.files.outputs.list }}
- name: show line separated list
run: echo "${LIST}"
env:
LIST: ${{ steps.lines.outputs.list }}
multiple_outputs:
runs-on: ubuntu-20.04
steps:
- name: set outputs
id: colors
run: |
echo "FIRST=green" >>$GITHUB_OUTPUT
echo "SECOND=pink" >>$GITHUB_OUTPUT
- name: show outputs
run: |
echo "The first color is ${{ steps.colors.outputs.FIRST }}"
echo "The second color is ${{ steps.colors.outputs.SECOND }}"