Skip to content
box

GitHub Action

googlesheet-actions

0.1.1 Latest version

googlesheet-actions

box

googlesheet-actions

Github action for google spreadsheets to fetch data

Installation

Copy and paste the following snippet into your .yml file.

              

- name: googlesheet-actions

uses: rjoydip-zz/[email protected]

Learn more about this action in rjoydip-zz/googlesheet-actions

Choose a version

googlesheet-actions

Github action for google spreadsheets to fetch data.

Inputs

sheet-id

Required - string - Google spreadsheets id which is published on web.

Outputs

result

steps.googlesheet_actions.outputs.result - json - Get all data as json format. The output is dependant on the output input.

Example usage

Simple example

- name: googlesheet-actions
  uses: rjoydip/[email protected]

Full example

# bare minimal
name: googlesheet

on:
    push:
      branches:
        - master

jobs:
    fetch:
      runs-on: ubuntu-latest
      steps:
        - id: googlesheet_actions
          uses: rjoydip/[email protected]
          with:
            sheet-id: ${{ secrets.SHEET_ID }}
        - id: echo
          uses: actions/github-script@v2
          with:
            github-token: ${{secrets.GITHUB_TOKEN}}
            script: |
                console.log(${{steps.googlesheet_actions.outputs.data}})
        - name: test
          run: |
            cat $HOME/data.json

Getting Started

Create the Google spreadsheet and publish it: