Automated Workflow Test - Google Sheets Data Capture to GitHub Landing Page
Issue Description:
Documenting the automated workflow for capturing data from Google Sheets and utilizing it to update a landing page in GitHub.
Objective:
To establish an automated process that captures data from a Google Sheets document and utilizes the retrieved data to compose and update a landing page in HTML hosted on GitHub. This workflow should run weekly on Tuesdays, ensuring the landing page is ready by Wednesday.
Steps:
[x] 1. Set up Google Sheets:
Create a Google Sheets document.
Define the necessary columns to capture the desired data.
Populate the sheet with the relevant data.
[ ] 2. Configure Google Apps Script:
Access the Google Sheets document and open the Script Editor by navigating to "Tools" -> "Script editor".
Implement a script that retrieves the data from the Google Sheets document.
Use the getRange() method to specify the desired range of cells to capture.
Leverage the Google Apps Script's UrlFetchApp.fetch() function to send a POST request to the GitHub API, creating or updating a file with the captured data.
[ ] 3. Configure GitHub:
Create a repository on GitHub to host the HTML landing page.
Ensure the repository contains a basic HTML structure for the landing page, which will be updated with the captured data.
[ ] 4. Set up GitHub Actions:
Within the GitHub repository, create a directory named .github/workflows.
Inside the workflows directory, create a YAML file (e.g., update-page.yml) to define the automated workflow.
Configure the workflow to trigger every Tuesday. For example:
on:
schedule:
- cron: "0 0 * * 2" # Execute at 00:00 on every Tuesday
Utilize the google-sheet-to-json action to extract the data from the Google Sheets document and save it as a JSON file.
Use the github-script action to read the JSON file, process the data, and update the content of the HTML landing page in the GitHub repository.
After updating the HTML page, employ the commit and push actions to push the changes back to the GitHub repository.
[ ] 5. Create the HTML Landing Page:
Inside the GitHub repository, create or modify an existing HTML file that represents the landing page.
Utilize HTML and CSS syntax to format the page and display the captured data from the Google Sheets document.
See #8
Additional Notes:
Ensure that the required Google Sheets API and GitHub API credentials are set up for the automation workflow to function properly.
Automated Workflow Test - Google Sheets Data Capture to GitHub Landing Page
Issue Description: Documenting the automated workflow for capturing data from Google Sheets and utilizing it to update a landing page in GitHub.
Objective: To establish an automated process that captures data from a Google Sheets document and utilizes the retrieved data to compose and update a landing page in HTML hosted on GitHub. This workflow should run weekly on Tuesdays, ensuring the landing page is ready by Wednesday.
Steps:
[x] 1. Set up Google Sheets:
[ ] 2. Configure Google Apps Script:
getRange()
method to specify the desired range of cells to capture.UrlFetchApp.fetch()
function to send a POST request to the GitHub API, creating or updating a file with the captured data.[ ] 3. Configure GitHub:
[ ] 4. Set up GitHub Actions:
.github/workflows
.workflows
directory, create a YAML file (e.g.,update-page.yml
) to define the automated workflow.google-sheet-to-json
action to extract the data from the Google Sheets document and save it as a JSON file.github-script
action to read the JSON file, process the data, and update the content of the HTML landing page in the GitHub repository.commit
andpush
actions to push the changes back to the GitHub repository.[ ] 5. Create the HTML Landing Page:
Additional Notes: Ensure that the required Google Sheets API and GitHub API credentials are set up for the automation workflow to function properly.