Something went wrong while fetching comments. Please try again.
Created by: artemruts
These changes slightly change the copy and enables Sync all repositories
radio button when the user has the AllowUserExternalServicePrivate
tag. Radio button are behind the shimmer effect now.
AllowUserExternalServicePrivate
tag controls minor copy changes and enables the Sync all repositories
radio button
Sync all repositories
radio button
Repo selection radio buttons had to be placed behind a shimmer.
When the private code is enabled we need to determine if the user selected all of the affiliate repos, and if we should set Sync all repositories
radio button as active. To do that we need to wait for two queries to complete:
ExternalServices
- to check if code hosts are configure and to build a list of all synced (already selected) affiliated repos;AffiliatedRepositories
- to determine how many affiliated repos user has.Queries need to happen serially because AffiliatedRepositories
endpoint can only be queried when the code host(s) are configured. Executing queries serially gives us control wether we should send the AffiliatedRepositories
request. Serial requests create latency and that's why the shimmer was modified and moved.
Using psql
connect to the sourcegraph
(most likely the default) db and execute the following query:
Set user tag
a. adding user AllowUserExternalServicePrivate
tag:
update users set tags = array_append(tags, 'AllowUserExternalServicePrivate') where username = '<your username>';
https://user-images.githubusercontent.com/1319181/116275902-05b77c80-a752-11eb-96db-01d3bf9c6e6c.mov
b. removing user tag:
update users set tags = array_remove(tags, 'AllowUserExternalServicePrivate') where username = '<your username>';
Use personal access token to add new code host connection
Navigate to Settings
→ Repositories
page
https://user-images.githubusercontent.com/1319181/115652302-050a8a80-a2fb-11eb-852d-4772e1ac4460.mov
https://user-images.githubusercontent.com/1319181/115652499-62064080-a2fb-11eb-9981-676f98cacd7c.mov
https://user-images.githubusercontent.com/1319181/115653158-a5ad7a00-a2fc-11eb-82d8-55eb17cb8741.mov
https://user-images.githubusercontent.com/1319181/115652795-e789f080-a2fb-11eb-90d6-be589ad38817.mov
https://user-images.githubusercontent.com/1319181/115652862-0ee0bd80-a2fc-11eb-9501-1a1348c22b7e.mov
https://user-images.githubusercontent.com/1319181/115653265-d9889f80-a2fc-11eb-982b-f9b218629c1c.mov
AllowUserExternalServicePrivate
tag?Page is accessible only by signed-in users with AllowUserExternalServicePublic
tag. Do we need anything special for Admins?