diff --git a/.github/workflows/client.yaml b/.github/workflows/client.yaml
new file mode 100644
index 00000000..dc91c978
--- /dev/null
+++ b/.github/workflows/client.yaml
@@ -0,0 +1,60 @@
+name: client
+
+on:
+ workflow_dispatch:
+ push:
+ paths:
+ - 'packages/client/**'
+ branches:
+ - main
+ tags:
+ - "v*.*.*"
+ pull_request:
+ paths:
+ - 'packages/client/**'
+ branches:
+ - main
+
+jobs:
+ lint:
+ runs-on: ubuntu-latest
+ name: Check for Linting Errors
+ steps:
+ - name: Checkout Repository
+ uses: actions/checkout@v3
+ with:
+ ref: ${{ github.event.pull_request.head.ref }}
+
+ - name: Setup NodeJS
+ uses: actions/setup-node@v3
+ with:
+ node-version: 18
+
+ - name: NPM Install
+ run: npm install --only=dev
+ shell: bash
+
+ - name: Check for Linting Issues
+ run: npm run prettier --workspace=packages/client
+
+ build:
+ runs-on: ubuntu-latest
+ name: Build Code
+ defaults:
+ run:
+ working-directory: packages/client
+ steps:
+ - name: Checkout Repository
+ uses: actions/checkout@v3
+
+ - name: Setup NodeJS
+ uses: actions/setup-node@v3
+ with:
+ node-version: 18
+
+ - name: NPM Install
+ run: npm install
+ shell: bash
+
+ - name: Build
+ run: npm run build
diff --git a/.github/workflows/gateway.yaml b/.github/workflows/gateway.yaml
new file mode 100644
index 00000000..78a21b9d
--- /dev/null
+++ b/.github/workflows/gateway.yaml
@@ -0,0 +1,60 @@
+name: gateway
+
+on:
+ workflow_dispatch:
+ push:
+ paths:
+ - 'packages/gateway/**'
+ branches:
+ - main
+ tags:
+ - "v*.*.*"
+ pull_request:
+ paths:
+ - 'packages/gateway/**'
+ branches:
+ - main
+
+jobs:
+ lint:
+ runs-on: ubuntu-latest
+ name: Check for Linting Errors
+ steps:
+ - name: Checkout Repository
+ uses: actions/checkout@v3
+ with:
+ ref: ${{ github.event.pull_request.head.ref }}
+
+ - name: Setup NodeJS
+ uses: actions/setup-node@v3
+ with:
+ node-version: 18
+
+ - name: NPM Install
+ run: npm install --only=dev
+ shell: bash
+
+ - name: Check for Linting Issues
+ run: npm run prettier --workspace=packages/gateway
+
+ build:
+ runs-on: ubuntu-latest
+ name: Build Code
+ defaults:
+ run:
+ working-directory: packages/gateway
+ steps:
+ - name: Checkout Repository
+ uses: actions/checkout@v3
+
+ - name: Setup NodeJS
+ uses: actions/setup-node@v3
+ with:
+ node-version: 18
+
+ - name: NPM Install
+ run: npm install
+ shell: bash
+
+ - name: Build
+ run: npm run build
diff --git a/.github/workflows/server.yaml b/.github/workflows/server.yaml
new file mode 100644
index 00000000..e5d8b210
--- /dev/null
+++ b/.github/workflows/server.yaml
@@ -0,0 +1,60 @@
+name: server
+
+on:
+ workflow_dispatch:
+ push:
+ paths:
+ - 'packages/server/**'
+ branches:
+ - main
+ tags:
+ - "v*.*.*"
+ pull_request:
+ paths:
+ - 'packages/server/**'
+ branches:
+ - main
+
+jobs:
+ lint:
+ runs-on: ubuntu-latest
+ name: Check for Linting Errors
+ steps:
+ - name: Checkout Repository
+ uses: actions/checkout@v3
+ with:
+ ref: ${{ github.event.pull_request.head.ref }}
+
+ - name: Setup NodeJS
+ uses: actions/setup-node@v3
+ with:
+ node-version: 18
+
+ - name: NPM Install
+ run: npm install --only=dev
+ shell: bash
+
+ - name: Check for Linting Issues
+ run: npm run prettier --workspace=packages/server
+
+ build:
+ runs-on: ubuntu-latest
+ name: Build Code
+ defaults:
+ run:
+ working-directory: packages/server
+ steps:
+ - name: Checkout Repository
+ uses: actions/checkout@v3
+
+ - name: Setup NodeJS
+ uses: actions/setup-node@v3
+ with:
+ node-version: 18
+
+ - name: NPM Install
+ run: npm install
+ shell: bash
+
+ - name: Build
+ run: npm run build
diff --git a/.prettierrc.js b/.prettierrc.js
new file mode 100644
index 00000000..7ea56ce4
--- /dev/null
+++ b/.prettierrc.js
@@ -0,0 +1,5 @@
+module.exports = {
+ printWidth: 120,
+ singleQuote: true,
+ trailingComma: "none"
+}
diff --git a/package.json b/package.json
index 332c58b6..e5c6df20 100644
--- a/package.json
+++ b/package.json
@@ -4,7 +4,9 @@
"description": "",
"main": "index.js",
"scripts": {
- "test": "echo \"Error: no test specified\" && exit 1"
+ "build": "npm run build --workspaces --if-present",
+ "prettier": "npm run prettier --workspaces --if-present",
+ "prettier:fix": "npm run prettier:fix --workspaces --if-present"
},
"workspaces": [
"packages/*"
diff --git a/packages/client/.prettierrc b/packages/client/.prettierrc
deleted file mode 100644
index eb55e100..00000000
--- a/packages/client/.prettierrc
+++ /dev/null
@@ -1,5 +0,0 @@
-{
- "printWidth": 180,
- "singleQuote": true,
- "trailingComma": "none"
-}
diff --git a/packages/client/.prettierrc.cjs b/packages/client/.prettierrc.cjs
new file mode 100644
index 00000000..2d293bab
--- /dev/null
+++ b/packages/client/.prettierrc.cjs
@@ -0,0 +1,3 @@
+module.exports = {
+ ...require('../../.prettierrc.js'),
+}
diff --git a/packages/client/src/App.tsx b/packages/client/src/App.tsx
index c0de019f..4a2d8cd5 100644
--- a/packages/client/src/App.tsx
+++ b/packages/client/src/App.tsx
@@ -57,9 +57,9 @@ const App: FC = () => {
return {
headers: {
...headers,
- authorization: token ? `Bearer ${token}` : '',
+ authorization: token ? `Bearer ${token}` : ''
}
- }
+ };
});
const apolloClient = new ApolloClient({
@@ -81,7 +81,7 @@ const App: FC = () => {
);
-}
+};
const AppInternal: FC = () => {
const [drawerOpen, setDrawerOpen] = useState(true);
@@ -107,7 +107,7 @@ const AppInternal: FC = () => {
);
- return (<>{ authenticated ? mainView : }>);
+ return <>{authenticated ? mainView : }>;
};
const UnauthenticatedView: FC = () => {
diff --git a/packages/client/src/components/AddDataset.component.tsx b/packages/client/src/components/AddDataset.component.tsx
index 9dfc7f79..8ec4af1c 100644
--- a/packages/client/src/components/AddDataset.component.tsx
+++ b/packages/client/src/components/AddDataset.component.tsx
@@ -65,7 +65,14 @@ export const AddDataset: React.FC = (props: ShowProps) => {