-
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.
# 🤖 Linear Re implements #8 without commit issues ## Description
- Loading branch information
Showing
23 changed files
with
220 additions
and
25 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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
### Example Package | ||
|
||
Easily kickoff a package replicating this structure. |
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,17 @@ | ||
{ | ||
"name": "@hyperhub/example", | ||
"private": true, | ||
"version": "0.0.0", | ||
"scripts": { | ||
"build": "tsc -p tsconfig.json", | ||
"lint": "eslint --fix --ext .js,.jsx,.ts,.tsx src", | ||
"test": "vitest", | ||
"coverage": "vitest run --coverage", | ||
"tsc": "tsc --noEmit" | ||
}, | ||
"devDependencies": { | ||
"@hyperhub/errors": "workspace:*", | ||
"@hyperhub/test-config": "workspace:*", | ||
"@hyperhub/typescript-config": "workspace:*" | ||
} | ||
} |
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,3 @@ | ||
export const example = () => { | ||
// Implement | ||
}; |
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,9 @@ | ||
{ | ||
"extends": "@hyperhub/typescript-config/base.json", | ||
"include": ["./src/**/*.ts"], | ||
"exclude": ["dist", "node_modules"], | ||
"compilerOptions": { | ||
"rootDir": "./src", | ||
"outDir": "./dist" | ||
} | ||
} |
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,11 @@ | ||
import { baseConfig } from "@hyperhub/test-config"; | ||
import { mergeConfig, defineConfig } from "vitest/config"; | ||
|
||
export default mergeConfig( | ||
baseConfig, | ||
defineConfig({ | ||
test: { | ||
exclude: ["coverage/*"], | ||
}, | ||
}), | ||
); |
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 @@ | ||
## Errors package |
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,7 @@ | ||
import { describe, test, expect } from 'vitest' | ||
|
||
describe('exampleHandler', () => { | ||
test('Sample exampleHandler test', () => { | ||
expect(true).toBe(true); | ||
}) | ||
}); |
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,17 @@ | ||
{ | ||
"name": "@hyperhub/errors", | ||
"version": "0.0.0", | ||
"private": true, | ||
"license": "MIT", | ||
"main": "dist/index.js", | ||
"scripts": { | ||
"build": "tsc -p tsconfig.json" | ||
}, | ||
"publishConfig": { | ||
"access": "public" | ||
}, | ||
"devDependencies": { | ||
"@hyperhub/test-config": "workspace:*", | ||
"@hyperhub/typescript-config": "workspace:*" | ||
} | ||
} |
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,15 @@ | ||
export abstract class BaseError extends Error { | ||
readonly name: string; | ||
readonly description: string; | ||
|
||
constructor({ name, description }: { name: string; description: string }) { | ||
super(description); | ||
this.name = name; | ||
this.description = description; | ||
Object.setPrototypeOf(this, BaseError.prototype); | ||
} | ||
|
||
public getDescription(): string { | ||
return this.description; | ||
} | ||
} |
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,11 @@ | ||
{ | ||
"extends": "@hyperhub/typescript-config/base.json", | ||
"include": ["./src/**/*.ts"], | ||
"exclude": ["dist", "node_modules"], | ||
"compilerOptions": { | ||
"outDir": "./dist", | ||
"rootDir": "./src", | ||
"declaration": true, | ||
"declarationMap": true | ||
} | ||
} |
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,3 @@ | ||
## Coingecko Package | ||
|
||
Adds coingecko API utilities. |
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,17 @@ | ||
{ | ||
"name": "@hyperhub/coingecko", | ||
"private": true, | ||
"version": "0.0.0", | ||
"scripts": { | ||
"build": "tsc -p tsconfig.json", | ||
"lint": "eslint --fix --ext .js,.jsx,.ts,.tsx src", | ||
"test": "vitest", | ||
"coverage": "vitest run --coverage", | ||
"tsc": "tsc --noEmit" | ||
}, | ||
"devDependencies": { | ||
"@hyperhub/errors": "workspace:*", | ||
"@hyperhub/test-config": "workspace:*", | ||
"@hyperhub/typescript-config": "workspace:*" | ||
} | ||
} |
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,7 @@ | ||
import { BaseError } from "@hyperhub/errors"; | ||
|
||
export class CoingeckoError extends BaseError { | ||
constructor(description: string) { | ||
super({ name: "CoingeckoError", description }); | ||
} | ||
} |
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,24 @@ | ||
import type { AxiosInstance, CreateAxiosDefaults } from "axios"; | ||
import axios from "axios"; | ||
|
||
export default class CoingeckoService { | ||
private instance: AxiosInstance; | ||
|
||
constructor(private url: string, private apiKey:string){ | ||
const config: CreateAxiosDefaults = { | ||
baseURL: url, | ||
headers: { | ||
"x-cg-demo-api-key": this.apiKey, | ||
}, | ||
}; | ||
|
||
this.instance = axios.create(config); | ||
} | ||
|
||
get(): AxiosInstance { | ||
if (!this.instance) { | ||
throw new Error("Client not initialized"); | ||
} | ||
return this.instance; | ||
} | ||
} |
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,9 @@ | ||
{ | ||
"extends": "@hyperhub/typescript-config/base.json", | ||
"include": ["./src/**/*.ts"], | ||
"exclude": ["dist", "node_modules"], | ||
"compilerOptions": { | ||
"rootDir": "./src", | ||
"outDir": "./dist" | ||
} | ||
} |
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,11 @@ | ||
import { baseConfig } from "@hyperhub/test-config"; | ||
import { mergeConfig, defineConfig } from "vitest/config"; | ||
|
||
export default mergeConfig( | ||
baseConfig, | ||
defineConfig({ | ||
test: { | ||
exclude: ["coverage/*"], | ||
}, | ||
}), | ||
); |
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 @@ | ||
EXAMPLE_VAR="" |
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,4 @@ | ||
## Serverless Package | ||
|
||
|
||
Adds serverless utils to build lambda functions. |
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,7 @@ | ||
import { BaseError } from "@hyperhub/errors"; | ||
|
||
export default class LambdaError extends BaseError { | ||
constructor(description: string) { | ||
super({ name: "LambdaError", description }); | ||
} | ||
}; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
export { example } from './handlers/exampleHandler'; | ||
export const buildHandler = () => { | ||
console.log('@@//TODO'); | ||
}; |
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