fix(tools): update default branch name to main (#41178)
This commit is contained in:
@ -20,12 +20,12 @@ const FilenameResults = ({ searchValue, results, rateLimitMessage }) => {
|
||||
return <ListItem number={number} username={username} prTitle={title} />;
|
||||
});
|
||||
|
||||
const fileOnMaster = `https://github.com/freeCodeCamp/freeCodeCamp/blob/master/${filename}`;
|
||||
const fileOnMain = `https://github.com/freeCodeCamp/freeCodeCamp/blob/main/${filename}`;
|
||||
return (
|
||||
<Result key={filename}>
|
||||
<span style={filenameTitle}>{filename}</span>{' '}
|
||||
<a href={fileOnMaster} rel="noopener noreferrer" target="_blank">
|
||||
(File on Master)
|
||||
<a href={fileOnMain} rel="noopener noreferrer" target="_blank">
|
||||
(File on Main)
|
||||
</a>
|
||||
<List>{prs}</List>
|
||||
</Result>
|
||||
|
@ -137,12 +137,12 @@ class Pareto extends React.Component {
|
||||
const prsList = prs.map(({ number, username, title }) => {
|
||||
return <ListItem key={number} number={number} username={username} prTitle={title} />;
|
||||
});
|
||||
const fileOnMaster = `https://github.com/freeCodeCamp/freeCodeCamp/blob/master/${filename}`;
|
||||
const fileOnMain = `https://github.com/freeCodeCamp/freeCodeCamp/blob/main/${filename}`;
|
||||
return (
|
||||
<Result key={filename}>
|
||||
<span style={filenameTitle}>{filename}</span>{' '}
|
||||
<a href={fileOnMaster} rel="noopener noreferrer" target="_blank">
|
||||
(File on Master)
|
||||
<a href={fileOnMain} rel="noopener noreferrer" target="_blank">
|
||||
(File on Main)
|
||||
</a>
|
||||
<br />
|
||||
<details style={detailsStyle}>
|
||||
|
@ -13,12 +13,12 @@ const PrResults = ({ searchValue, results, rateLimitMessage }) => {
|
||||
const elements = results.map((result, idx) => {
|
||||
const { number, filenames, username, title } = result;
|
||||
const files = filenames.map((filename, index) => {
|
||||
const fileOnMaster = `https://github.com/freeCodeCamp/freeCodeCamp/blob/master/${filename}`;
|
||||
const fileOnMain = `https://github.com/freeCodeCamp/freeCodeCamp/blob/main/${filename}`;
|
||||
return (
|
||||
<li key={`${number}-${index}`}>
|
||||
{filename}{' '}
|
||||
<a href={fileOnMaster} rel="noopener noreferrer" target="_blank">
|
||||
(File on Master)
|
||||
<a href={fileOnMain} rel="noopener noreferrer" target="_blank">
|
||||
(File on Main)
|
||||
</a>
|
||||
</li>
|
||||
);
|
||||
|
@ -19,8 +19,6 @@ const getPRs = async () => {
|
||||
};
|
||||
|
||||
const openPRs = await octokit.paginate(octokit.pulls.list, methodProps);
|
||||
// const openPRs = await octokit.pulls.list(methodProps);
|
||||
// console.log(openPRs[0])
|
||||
return openPRs;
|
||||
};
|
||||
|
||||
|
@ -2,7 +2,7 @@ GITHUB_USERNAME='camperbot'
|
||||
GITHUB_ACCESS_TOKEN=
|
||||
REPOSITORY_OWNER='freeCodeCamp'
|
||||
REPOSITORY='freeCodeCamp'
|
||||
DEFAULT_BASE='master'
|
||||
DEFAULT_BASE='main'
|
||||
PORT=3001
|
||||
MONGO_HOST=mongodb://localhost/contributor-tools
|
||||
MONGO_PORT=27017
|
||||
|
Reference in New Issue
Block a user