@pulumi/github
Version:
A Pulumi package for creating and managing github cloud resources.
62 lines • 2.02 kB
JavaScript
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.getUserOutput = exports.getUser = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("./utilities");
/**
* Use this data source to retrieve information about a GitHub user.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as github from "@pulumi/github";
*
* // Retrieve information about a GitHub user.
* const example = github.getUser({
* username: "example",
* });
* // Retrieve information about the currently authenticated user.
* const current = github.getUser({
* username: "",
* });
* export const currentGithubLogin = current.then(current => current.login);
* ```
*/
function getUser(args, opts) {
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invoke("github:index/getUser:getUser", {
"username": args.username,
}, opts);
}
exports.getUser = getUser;
/**
* Use this data source to retrieve information about a GitHub user.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as github from "@pulumi/github";
*
* // Retrieve information about a GitHub user.
* const example = github.getUser({
* username: "example",
* });
* // Retrieve information about the currently authenticated user.
* const current = github.getUser({
* username: "",
* });
* export const currentGithubLogin = current.then(current => current.login);
* ```
*/
function getUserOutput(args, opts) {
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invokeOutput("github:index/getUser:getUser", {
"username": args.username,
}, opts);
}
exports.getUserOutput = getUserOutput;
//# sourceMappingURL=getUser.js.map
;