Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support fast github #74

Merged
merged 3 commits into from
Jul 22, 2019
Merged

feat: support fast github #74

merged 3 commits into from
Jul 22, 2019

Conversation

chenshuai2144
Copy link
Contributor

@chenshuai2144 chenshuai2144 commented Jul 20, 2019

use fast github .

Cloning into 'ant-design-pro'...
remote: Enumerating objects: 162, done. 
remote: Counting objects: 100% (162/162), done.
remote: Compressing objects: 100% (141/141), done
remote: Total 162 (delta 22), reused 78 (delta 13), pack-reused 0 ) 
Receiving objects: 100% (162/162), 110.43 KiB | 443.00 KiB/s, done.
Resolving deltas: 100% (22/22), done.

package.json Outdated Show resolved Hide resolved
return ' https://github.com.cnpmjs.org/ant-design/ant-design-pro';
}
return 'https://github.com/ant-design/ant-design-pro';
};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
};
return `${fastGithub}/ant-design/ant-design-pro`;

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

前面有了这个 if (fastGithub === 'github.com.cnpmjs.org') {
变量名已经被固定了

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这样写简单很多,不用写这么多代码。

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

字符串更易读一点,搜一下就找到了

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

不是这样的,这个文件里不关心具体的源地址,不应该耦合。

@chenshuai2144
Copy link
Contributor Author

加了个packack.json 的排序

@sorrycc sorrycc changed the title support fast github feat: support fast github Jul 22, 2019
@sorrycc sorrycc merged commit 22c3c35 into master Jul 22, 2019
@delete-merged-branch delete-merged-branch bot deleted the fastGithub branch July 22, 2019 02:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants