This commit is contained in:
Marcel Dias 2025-03-05 23:18:04 +01:00 committed by GitHub
commit 929bec3f15
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -341,6 +341,12 @@ export class Github implements INodeType {
description: 'Get a release',
action: 'Get a release',
},
{
name: 'Get by Tag',
value: 'getByTag',
description: 'Get a release by Tag',
action: 'Get a release by Tag',
},
{
name: 'Get Many',
value: 'getAll',
@ -1287,6 +1293,13 @@ export class Github implements INodeType {
default: false,
description: 'Whether to point out that the release is non-production ready',
},
{
displayName: 'Latest',
name: 'make_latest',
type: 'boolean',
default: true,
description: 'Whether to mark the release as latest or not',
},
{
displayName: 'Target Commitish',
name: 'target_commitish',
@ -1365,6 +1378,13 @@ export class Github implements INodeType {
default: false,
description: 'Whether to point out that the release is non-production ready',
},
{
displayName: 'Latest',
name: 'make_latest',
type: 'boolean',
default: true,
description: 'Whether to mark the release as latest or not',
},
{
displayName: 'Tag Name',
name: 'tag_name',
@ -1416,6 +1436,23 @@ export class Github implements INodeType {
default: 50,
description: 'Max number of results to return',
},
// ----------------------------------
// release:getByTag
// ----------------------------------
{
displayName: 'Tag Name',
name: 'tag_name',
type: 'string',
required: true,
displayOptions: {
show: {
resource: ['release'],
operation: ['getByTag'],
},
},
default: '',
description: 'Release Tag Name',
},
// ----------------------------------
// repository
@ -2045,6 +2082,7 @@ export class Github implements INodeType {
'repository:listReferrers',
'user:getRepositories',
'release:getAll',
'release:getByTag',
'review:getAll',
'organization:getRepositories',
];
@ -2321,6 +2359,16 @@ export class Github implements INodeType {
qs.per_page = this.getNodeParameter('limit', 0);
}
}
if (operation === 'getByTag') {
// ----------------------------------
// getbyTag
// ----------------------------------
requestMethod = 'GET';
const tagName = this.getNodeParameter('tag_name', i) as string;
endpoint = `/repos/${owner}/${repository}/releases/tags/${tagName}`;
}
if (operation === 'update') {
// ----------------------------------
// update