Comments (5)
Looking at your linked PR, it looks like your use case is if you don't want to authenticate at all, right? I think I see a use case there, not sure if I see a use case for alternative auth methods - does that seem right?
from toolkit.
The use case I specifically am running into is needing to authentication with a JWT.
from toolkit.
I'm not sure whether we need to implement this.
The toolkit class is a thin wrapper convenience function for the common case GITHUB_TOKEN
or PAT.
I could see the need if an input accepted a PAT or JWT and a function provided a single abstraction to do the right thing.
Otherwise I would recommend using the Octokit class directly.
Thoughts?
from toolkit.
IMHO, @actions/github
should not duplicate or wrap any of the features provided by @octokit/rest
, but extend them. Therefore, authentication and all regular operations should be done with octokit. When a feature from @actions/github
is required, it should accept an existing octokit object as an argument. It should not be required for @actions/github
to handle authentication at all. For example:
const octokit = new Octokit(getInput('token', { required: false }))
const ghkit = new github.GitHub(octokit)
Moreover, it seems that the only addition of https://github.com/actions/toolkit/tree/master/packages/github is that it provides the context for the current action. Wouldn't it be easier if it did just that, instead of being a passthrough for all octokit features?
from toolkit.
fixed with #314 since the value of github.GitHub expanded to support runner proxy settings
now you can use a different auth mechanism, but still get the proxy settings.
from toolkit.
Related Issues (20)
- Tracking
- @actions/artefacts weighs 100mb. this cant be right
- Bug: `context.job` fails to take into account `jobs.<job_id>.name` value HOT 2
- https://www.facebook.com/nara.istri.jisung
- `continue-on-error` should not return `success` in ` needs_job_result`
- Make uploadZipToBlobStorage() log raw and compressed sizes ?
- Annotations using environment files
- amin HOT 1
- npm i @actions/glob
- Bug
- Spacextool
- @actions/cache tar doesn't specify --xattrs
- @actions/github hasn't been published in 8 months
- Support storing and restoring cache entries as buffers. HOT 1
- mkdir service-selling-app cd service-selling-app HOT 1
- mkdir service-selling-app
- @actions/core: Add support for full width tables and column width
- BornNk
- Plan for transition to ESM?
- actions/exec: Allow timeout on running a process
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from toolkit.