-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #6 from Design-System-Project/fix/db-scripts
fix db migration script on github action
- Loading branch information
Showing
25 changed files
with
174 additions
and
399 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
apps/dashboard/src/app/(dashboard)/integrations/providers/github/_actions/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1 @@ | ||
export * from './request-tokens.action'; | ||
export * from './select-repository.action'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 0 additions & 17 deletions
17
apps/dashboard/src/app/api/figma/design-systems/link/route.ts
This file was deleted.
Oops, something went wrong.
27 changes: 0 additions & 27 deletions
27
apps/dashboard/src/app/api/figma/design-systems/list/route.ts
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import { eq } from '@ds-project/database'; | ||
import type { DSContext } from '../types/context'; | ||
|
||
export const selectGithubIntegration = async ({ ctx }: { ctx: DSContext }) => { | ||
const queryResult = await ctx.database.query.Integrations.findFirst({ | ||
columns: { | ||
data: true, | ||
}, | ||
where: (integrations) => eq(integrations.type, 'github'), | ||
with: { | ||
project: { | ||
columns: { | ||
id: true, | ||
}, | ||
with: { | ||
accountsToProjects: { | ||
columns: { | ||
projectId: true, | ||
}, | ||
where: (accountsToProjects) => | ||
eq(accountsToProjects.accountId, ctx.account.id), | ||
}, | ||
}, | ||
}, | ||
}, | ||
}); | ||
|
||
if (queryResult?.data?.type === 'github') { | ||
return { | ||
...queryResult, | ||
data: queryResult.data, | ||
}; | ||
} | ||
|
||
return undefined; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.