mirror of
https://github.com/docker/setup-buildx-action
synced 2024-11-22 11:01:42 +00:00
2e23606dc9
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
12 lines
406 B
TypeScript
12 lines
406 B
TypeScript
import * as httpm from '@actions/http-client';
|
|
|
|
export interface GitHubRelease {
|
|
id: number;
|
|
tag_name: string;
|
|
}
|
|
|
|
export const getRelease = async (version: string): Promise<GitHubRelease | null> => {
|
|
const url = `https://github.com/docker/buildx/releases/${version}`;
|
|
const http: httpm.HttpClient = new httpm.HttpClient('setup-buildx');
|
|
return (await http.getJson<GitHubRelease>(url)).result;
|
|
};
|