-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
style(prettier): run prettier for whole project
\
- Loading branch information
Showing
640 changed files
with
23,795 additions
and
24,187 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,6 @@ | ||
name: build-and-deploy | ||
|
||
on: | ||
workflow_dispatch | ||
on: workflow_dispatch | ||
# on: | ||
# push: | ||
# branches: | ||
|
@@ -50,8 +49,7 @@ jobs: | |
- name: Build image for web | ||
run: docker build -t linkerry/web -f ./apps/web/Dockerfile . --platform=linux/amd64 | ||
- name: Tag web image | ||
run: | ||
docker tag linkerry/web registry.digitalocean.com/linkerry/web:latest | ||
run: docker tag linkerry/web registry.digitalocean.com/linkerry/web:latest | ||
- name: Push image to DO Container Registry | ||
run: docker push registry.digitalocean.com/linkerry/web:latest | ||
# - run: npx [email protected] affected -t docker-compose --base=origin/master~1 --head=origin/master |
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,7 +1,6 @@ | ||
name: deploy-changed-apps | ||
|
||
on: | ||
workflow_dispatch | ||
on: workflow_dispatch | ||
# on: | ||
# push: | ||
# branches: | ||
|
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,49 +1,49 @@ | ||
export enum ErrorCode { | ||
APP_CONNECTION_NOT_FOUND = 'APP_CONNECTION_NOT_FOUND', | ||
AUTHENTICATION = 'AUTHENTICATION', | ||
AUTHORIZATION = 'AUTHORIZATION', | ||
CONFIG_NOT_FOUND = 'CONFIG_NOT_FOUND', | ||
APP_CONNECTION_NOT_FOUND = 'APP_CONNECTION_NOT_FOUND', | ||
AUTHENTICATION = 'AUTHENTICATION', | ||
AUTHORIZATION = 'AUTHORIZATION', | ||
CONFIG_NOT_FOUND = 'CONFIG_NOT_FOUND', | ||
} | ||
|
||
type CustomErrorMetadata = Record<string, any> | ||
|
||
export class CustomError extends Error { | ||
name = 'CustomError' | ||
isOperational = true | ||
metadata: CustomErrorMetadata | null | ||
code: ErrorCode | ||
name = 'CustomError' | ||
isOperational = true | ||
metadata: CustomErrorMetadata | null | ||
code: ErrorCode | ||
|
||
constructor( | ||
message: string, | ||
code: ErrorCode, | ||
metadata?: CustomErrorMetadata, | ||
// isOperational = true | ||
) { | ||
super(`${code} ${message}`) | ||
this.metadata = metadata ?? null | ||
this.code = code | ||
Error.captureStackTrace(this, this.constructor) | ||
} | ||
constructor( | ||
message: string, | ||
code: ErrorCode, | ||
metadata?: CustomErrorMetadata, | ||
// isOperational = true | ||
) { | ||
super(`${code} ${message}`) | ||
this.metadata = metadata ?? null | ||
this.code = code | ||
Error.captureStackTrace(this, this.constructor) | ||
} | ||
} | ||
|
||
const main = async () => { | ||
try { | ||
throw new CustomError('Test error without metadata', ErrorCode.AUTHENTICATION) | ||
} catch (error) { | ||
console.log(error) | ||
console.log(error.name) | ||
} | ||
try { | ||
throw new CustomError('Test error without metadata', ErrorCode.AUTHENTICATION) | ||
} catch (error) { | ||
console.log(error) | ||
console.log(error.name) | ||
} | ||
|
||
try { | ||
throw new CustomError('Test error witj metadata', ErrorCode.AUTHENTICATION, { | ||
test: true, | ||
action: 'TEST', | ||
}) | ||
} catch (error) { | ||
console.log(error) | ||
} | ||
try { | ||
throw new CustomError('Test error witj metadata', ErrorCode.AUTHENTICATION, { | ||
test: true, | ||
action: 'TEST', | ||
}) | ||
} catch (error) { | ||
console.log(error) | ||
} | ||
} | ||
|
||
main() | ||
.then() | ||
.catch((err) => console.log(err)) | ||
.then() | ||
.catch((err) => console.log(err)) |
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,14 +1,14 @@ | ||
const main = async () => { | ||
const response = await fetch('https://pro-api.coingecko.com/api/v3/coins/list/new?&x_cg_pro_api_key={YOUR_KEY}', { | ||
method: 'GET', | ||
}) | ||
const response = await fetch('https://pro-api.coingecko.com/api/v3/coins/list/new?&x_cg_pro_api_key={YOUR_KEY}', { | ||
method: 'GET', | ||
}) | ||
|
||
// console.log(response.ok) | ||
console.log(await response.json()) | ||
console.log(await response.status) | ||
console.log(await response.statusText) | ||
// console.log(response.ok) | ||
console.log(await response.json()) | ||
console.log(await response.status) | ||
console.log(await response.statusText) | ||
} | ||
|
||
main() | ||
.then((c) => c) | ||
.catch((err) => console.log(err)) | ||
.then((c) => c) | ||
.catch((err) => console.log(err)) |
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,39 +1,39 @@ | ||
import merge from 'lodash.merge' | ||
|
||
const base = { | ||
name: 'trigger_1', | ||
valid: false, | ||
displayName: 'Top trending coins', | ||
type: 'CONNECTOR', | ||
settings: { | ||
connectorName: '@linkerry/coingecko', | ||
connectorVersion: '0.0.1', | ||
triggerName: 'trending_coins', | ||
connectorType: 'Official', | ||
input: {}, | ||
inputUiInfo: { | ||
before:1 | ||
}, | ||
}, | ||
nextActionName: '', | ||
name: 'trigger_1', | ||
valid: false, | ||
displayName: 'Top trending coins', | ||
type: 'CONNECTOR', | ||
settings: { | ||
connectorName: '@linkerry/coingecko', | ||
connectorVersion: '0.0.1', | ||
triggerName: 'trending_coins', | ||
connectorType: 'Official', | ||
input: {}, | ||
inputUiInfo: { | ||
before: 1, | ||
}, | ||
}, | ||
nextActionName: '', | ||
} | ||
|
||
const main = async () => { | ||
console.log( | ||
merge(base, { | ||
valid: true, | ||
settings: { | ||
inputUiInfo: { | ||
currentData: [], | ||
testXD: 123, | ||
}, | ||
}, | ||
}), | ||
) | ||
console.log( | ||
merge(base, { | ||
valid: true, | ||
settings: { | ||
inputUiInfo: { | ||
currentData: [], | ||
testXD: 123, | ||
}, | ||
}, | ||
}), | ||
) | ||
|
||
process.exit(0) | ||
process.exit(0) | ||
} | ||
|
||
main() | ||
.then() | ||
.catch((err) => console.log(err)) | ||
.then() | ||
.catch((err) => console.log(err)) |
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,7 +1,3 @@ | ||
{ | ||
"recommendations": [ | ||
"nrwl.angular-console", | ||
"esbenp.prettier-vscode", | ||
"firsttris.vscode-jest-runner" | ||
] | ||
"recommendations": ["nrwl.angular-console", "esbenp.prettier-vscode", "firsttris.vscode-jest-runner"] | ||
} |
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.