mirror of
				https://github.com/community-scripts/ProxmoxVE.git
				synced 2025-11-04 10:22:50 +00:00 
			
		
		
		
	add invalid / wontdo check
This commit is contained in:
		
							
								
								
									
										11
									
								
								.github/workflows/changelog-pr.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										11
									
								
								.github/workflows/changelog-pr.yml
									
									
									
									
										vendored
									
									
								
							@@ -70,8 +70,12 @@ jobs:
 | 
			
		||||
              per_page: 100,
 | 
			
		||||
            });
 | 
			
		||||
 | 
			
		||||
            const excludedLabels = ["invalid", "wontdo", process.env.AUTOMATED_PR_LABEL];
 | 
			
		||||
 | 
			
		||||
pulls.filter((pr) => 
 | 
			
		||||
              pr.merged_at && new Date(pr.merged_at) > latestDateInChangelog
 | 
			
		||||
  pr.merged_at && 
 | 
			
		||||
  new Date(pr.merged_at) > latestDateInChangelog && 
 | 
			
		||||
  !pr.labels.some((label) => excludedLabels.includes(label.name.toLowerCase()))
 | 
			
		||||
).forEach((pr) => {
 | 
			
		||||
  const prLabels = pr.labels.map((label) => label.name.toLowerCase());
 | 
			
		||||
  const prNote = `- ${pr.title} [@${pr.user.login}](https://github.com/${pr.user.login}) ([#${pr.number}](${pr.html_url}))`;
 | 
			
		||||
@@ -79,12 +83,11 @@ jobs:
 | 
			
		||||
  for (const { labels, notes } of categorizedPRs) {
 | 
			
		||||
    const prHasCategoryLabel = labels.some((label) => prLabels.includes(label));
 | 
			
		||||
    const isUnlabelledCategory = labels.length === 0;
 | 
			
		||||
                const prShouldBeExcluded = prLabels.includes(process.env.AUTOMATED_PR_LABEL);
 | 
			
		||||
                if ((prHasCategoryLabel || isUnlabelledCategory) && !prShouldBeExcluded) {
 | 
			
		||||
    if (prHasCategoryLabel || isUnlabelledCategory) {
 | 
			
		||||
      notes.push(prNote);
 | 
			
		||||
      break;
 | 
			
		||||
    }
 | 
			
		||||
              };
 | 
			
		||||
  }
 | 
			
		||||
});
 | 
			
		||||
 | 
			
		||||
            return categorizedPRs;
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user