gatsby-source-github-api | Pull data into Gatsby from Github API v4 | GraphQL library
kandi X-RAY | gatsby-source-github-api Summary
kandi X-RAY | gatsby-source-github-api Summary
Pull data into Gatsby from Github API v4
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of gatsby-source-github-api
gatsby-source-github-api Key Features
gatsby-source-github-api Examples and Code Snippets
Community Discussions
Trending Discussions on gatsby-source-github-api
QUESTION
I am new to Gatsby and just tried a GH Actions workflow for my site today. I see this error at the build stage:
error "gatsby-source-github-api" threw an error while running the sourceNodes lifecycle: token is undefined
I am using this to pull all repos on my Github into the site.
What I have tried so far:
- Checked the Github personal access token
- the build is working locally
Versions:
"gatsby-source-github-api": "^0.2.1" "gatsby": "^2.26.1"
This is my node.js.yml GH Actions workflow file:
...ANSWER
Answered 2021-Jan-25 at 01:55So that was it -- the .env file which wasn't being pushed to Github. So I needed to make the token available to the GH Action build somehow. I tried the action SpicyPizza/create-envfile@v1. It isn't supported by Github but seemed to do the job. It creates a .env file at build with the keys you provide it.
You could also create a .env file manually. See thread.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install gatsby-source-github-api
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page