MCPcopy Create free account
hub / github.com/Microck/opencode-studio / getGitHubToken

Function getGitHubToken

server/index.js:2055–2065  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2053// ============================================
2054
2055function getGitHubToken() {
2056 return new Promise((resolve, reject) => {
2057 exec('gh auth token', (err, stdout, stderr) => {
2058 if (err) {
2059 resolve(null);
2060 } else {
2061 resolve(stdout.trim());
2062 }
2063 });
2064 });
2065}
2066
2067async function getGitHubUser(token) {
2068 const response = await fetch('https://api.github.com/user', {

Callers 2

performGitHubBackupFunction · 0.85
index.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected