Skip to content

Latest commit

 

History

History

commit

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

garden github-commit

The latest commit SHA provided by a CI environment or remote GitHub repository and branch.

Usage

import { githubCommit } from '@zendeskgarden/scripts';

const args: {
  path?: string;
  branch?: string;
  token?: string;
} = {
  /* optional overrides */
};

(async () => {
  const commit = await githubCommit(args);

  console.log(commit);
})();

Arguments

  • path optional path to a git directory; defaults to the current directory.
  • branch optional GitHub branch name; defaults to the value provided by githubBranch.
  • token optional GitHub personal access token; defaults to the value provided by githubToken.

Command

garden github-commit [--branch <branch>] [--token <token>] [path]