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

Add isRepoHome #13

Merged
merged 6 commits into from
Jun 21, 2020
Merged

Add isRepoHome #13

merged 6 commits into from
Jun 21, 2020

Conversation

yakov116
Copy link
Member

@yakov116
Copy link
Member Author

Hmm not sure how to fix it

/sindresorhus/edit
/sindresorhus/notifications/

Should not match

@fregante
Copy link
Member

They should match, they're not special URLs

@fregante
Copy link
Member

@yakov116
Copy link
Member Author

yakov116 commented Jun 21, 2020

I should have said we don't want it to match

@fregante
Copy link
Member

You can move most of those URLs to isRepoHome and then use this pattern:

https://github.com/fregante/github-url-detection/blob/aa530b93bf865f0203a3a23e79a2c26e71901c81/index.ts#L329-L330

e.g.

collect.set('isRepoRoot', 
	...collect.get('isRepoHome') as string[], 
	'etc'
);
collect.set('isRepoTree', 
	...collect.get('isRepoRoot') as string[], 
	'etc'
);

@fregante
Copy link
Member

I should have said we don't want it to match

We do.

@fregante
Copy link
Member

https://github.com/fregante/notifications is repoHome, repoRoot and repoTree

@fregante fregante added the enhancement New feature or request label Jun 21, 2020
index.ts Outdated Show resolved Hide resolved
index.ts Outdated Show resolved Hide resolved
index.ts Outdated Show resolved Hide resolved
Co-authored-by: Fregante <opensource@bfred.it>
Copy link
Member

@fregante fregante left a comment

Choose a reason for hiding this comment

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

As a followup PR, this would also be good: refined-github/refined-github#3254 (review)

@fregante fregante merged commit 63f5f49 into refined-github:master Jun 21, 2020
@yakov116 yakov116 deleted the pathch-1 branch June 22, 2020 00:06
@yakov116
Copy link
Member Author

@fregante can you make a release?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Development

Successfully merging this pull request may close these issues.

None yet

2 participants