Skip to content

Commit bd5c427

Browse files
author
AzureAD\IoannisTsironis
committed
Merge branch 'main' into angular-typed-context-outlet-challenge
2 parents 33cc5ae + a964e4d commit bd5c427

File tree

1,171 files changed

+4972
-3493
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,171 files changed

+4972
-3493
lines changed

.all-contributorsrc

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,15 @@
100100
"challenge"
101101
]
102102
},
103+
{
104+
"login": "alcaidio",
105+
"name": "Timothy Alcaide",
106+
"avatar_url": "https://avatars.githubusercontent.com/u/17033036?v=4",
107+
"profile": "https://twitter.com/alcaidio",
108+
"contributions": [
109+
"challenge"
110+
]
111+
},
103112
{
104113
"login": "alan-bio",
105114
"name": "Alan Dragicevich",
@@ -231,6 +240,24 @@
231240
"contributions": [
232241
"translation-ru"
233242
]
243+
},
244+
{
245+
"login": "Dinozavvvr",
246+
"name": "Dinar Shagaliev",
247+
"avatar_url": "https://avatars.githubusercontent.com/u/45518871?v=4",
248+
"profile": "https://github.com/Dinozavvvr",
249+
"contributions": [
250+
"translation-ru"
251+
]
252+
},
253+
{
254+
"login": "vimulatus",
255+
"name": "Vimulatus",
256+
"avatar_url": "https://avatars.githubusercontent.com/u/63696128?v=4",
257+
"profile": "https://github.com/vimulatus",
258+
"contributions": [
259+
"doc"
260+
]
234261
}
235262
],
236263
"contributorsPerLine": 7,

.github/github-action/action.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: 'Hello World'
2+
description: 'Greet someone and record the time'
3+
inputs:
4+
github_token:
5+
description: A GitHub token.
6+
required: false
7+
default: ${{ github.token }}
8+
repo:
9+
description: The owner and repository name.
10+
required: false
11+
default: ${{ github.repository }}
12+
runs:
13+
using: 'node20'
14+
main: 'index.js'
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
const contributors = [
2+
'alcaidio',
3+
'svenson95',
4+
'jdegand',
5+
'DeveshChau',
6+
'stillst',
7+
'wandri',
8+
'webbomj',
9+
'kabrunko-dev',
10+
'Sanjar1304',
11+
];
12+
13+
const sponsors = ['ddotx', 'LMFinney'];
14+
15+
module.exports = {
16+
contributors,
17+
sponsors,
18+
};

.github/github-action/index.js

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
const github = require('@actions/github');
2+
const core = require('@actions/core');
3+
const { contributors, sponsors } = require('./contributors');
4+
5+
async function run() {
6+
try {
7+
const title = github.context.payload.pull_request.title;
8+
const labels = ['answer'];
9+
10+
const match = title.match(/Answer(:?)\s*(\d+)/);
11+
if (match) {
12+
labels.push(String(parseInt(match[2], 10)));
13+
}
14+
15+
const actor = github.context.actor;
16+
if (contributors.includes(actor)) {
17+
labels.push('contributor');
18+
labels.push('to be reviewed');
19+
}
20+
21+
if (sponsors.includes(actor)) {
22+
labels.push('sponsor');
23+
labels.push('to be reviewed');
24+
}
25+
26+
const githubToken = core.getInput('github_token');
27+
28+
const number = github.context.payload.pull_request.number;
29+
30+
const octokit = github.getOctokit(githubToken);
31+
await octokit.rest.issues.addLabels({
32+
labels,
33+
owner: github.context.repo.owner,
34+
repo: github.context.repo.repo,
35+
issue_number: number,
36+
});
37+
} catch (e) {
38+
if (e instanceof Error) {
39+
core.error(e);
40+
core.setFailed(e.message);
41+
}
42+
}
43+
}
44+
45+
run();
Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: Close inactive issues
22
on:
33
schedule:
4-
- cron: '20 1 * * *'
4+
- cron: '0 0 * * *'
55

66
jobs:
77
close-issues:
@@ -10,18 +10,18 @@ jobs:
1010
issues: write
1111
pull-requests: write
1212
steps:
13-
- uses: actions/stale@v5
13+
- uses: actions/stale@v9
1414
with:
1515
days-before-issue-stale: 20
1616
days-before-issue-close: -1
1717
stale-issue-label: 'stale'
18-
stale-issue-message: 'This issue is stale because it has been open for 20 days with no activity.'
18+
stale-issue-message: 'This issue is stale because it has been open for 15 days with no activity.'
1919
exempt-issue-labels: 'long-term'
20-
days-before-pr-stale: 20
21-
days-before-pr-close: 7
20+
days-before-pr-stale: 10
21+
days-before-pr-close: 2
2222
stale-pr-label: 'stale'
23-
stale-pr-message: 'This pull request is stale because it has been open for 20 days with no activity.'
24-
close-pr-message: 'This pull request was closed because it has been inactive for 7 days since being marked as stale.'
23+
stale-pr-message: 'This pull request is stale because it has been open for 15 days with no activity.'
24+
close-pr-message: 'This pull request was closed because it has been inactive for 5 days since being marked as stale.'
2525
only-pr-labels: 'answer'
2626
exempt-pr-labels: 'challenge-creation, long-term'
2727
repo-token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/label-issue.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Add Labels
2+
3+
on:
4+
pull_request_target:
5+
types: [ opened ]
6+
7+
jobs:
8+
add_labels:
9+
runs-on: ubuntu-latest
10+
if: ${{ startsWith(github.event.pull_request.title, 'Answer') }}
11+
steps:
12+
- name: checkout
13+
uses: actions/checkout@v2
14+
15+
- name: Install dependencies
16+
run: npm i @actions/core @actions/github
17+
18+
- name: Add labels
19+
uses: ./.github/github-action/
20+
with:
21+
github_token: ${{ secrets.GITHUB_TOKEN }}

README.md

Lines changed: 10 additions & 5 deletions
File renamed without changes.

apps/angular/projection/jest.config.ts renamed to apps/angular/1-projection/jest.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ export default {
44
preset: '../../../jest.preset.js',
55
setupFilesAfterEnv: ['<rootDir>/src/test-setup.ts'],
66
globals: {},
7-
coverageDirectory: '../../../coverage/apps/angular/projection',
7+
coverageDirectory: '../../../coverage/apps/angular/1-projection',
88
transform: {
99
'^.+\\.(ts|mjs|js|html)$': [
1010
'jest-preset-angular',

0 commit comments

Comments
 (0)