Compare commits

...

17 Commits

Author SHA1 Message Date
Ali BARIN
43cd8859bc Release v0.1.4 2022-10-08 14:38:27 +02:00
Ali BARIN
37548e6c39 chore: upgrade cli version with 0.1.4 in Dockerfiles 2022-10-08 14:37:55 +02:00
Ali BARIN
47930eca10 fix(backend): make getInterval optional 2022-10-08 14:36:38 +02:00
Ali BARIN
1b405728c4 Release v0.1.3 2022-10-08 13:03:31 +02:00
Ali BARIN
5d7bf38d13 chore: upgrade vers in Dockerfiles 2022-10-08 13:03:31 +02:00
Ali BARIN
2c2c1e8d89 chore: add 0.1.2 version in Dockerfiles 2022-10-08 12:57:27 +02:00
Ali BARIN
7f7ec6c115 docs: remove unnecessary text in READMEs 2022-10-08 12:56:29 +02:00
Ali BARIN
c9061b24a0 chore(backend): remove dist folder before building 2022-10-08 12:38:41 +02:00
Ali BARIN
a3dc7d2cde Release v0.1.1 2022-10-08 12:34:50 +02:00
Ömer Faruk Aydın
cf90e7cfd6 Merge pull request #568 from automatisch/revise-scheduler-outputs
fix: correct scheduler outputs
2022-10-08 12:21:17 +03:00
Ali BARIN
bbc9ea9571 fix: correct scheduler outputs 2022-10-08 10:37:26 +02:00
Ali BARIN
577abde2e9 fix: make auth in global variable optional 2022-10-08 10:36:48 +02:00
Ömer Faruk Aydın
8e972fd875 Merge pull request #566 from automatisch/fix/dynamic-import-fix
fix: dynamic import statements for get app
2022-10-07 19:21:41 +03:00
Faruk AYDIN
c7b290a380 fix: dynamic import statements for get app 2022-10-07 19:18:56 +03:00
Faruk AYDIN
3d14208175 chore: Remove local registry from docker files 2022-10-07 17:51:30 +02:00
Ömer Faruk Aydın
04ad03cfd9 Merge pull request #562 from automatisch/release/0.1.0
Release v0.1.0
2022-10-07 18:44:48 +03:00
Ali BARIN
48e9053124 chore: mark root package.json as private 2022-10-07 17:39:44 +02:00
19 changed files with 35 additions and 65 deletions

View File

@@ -2,10 +2,4 @@
FROM node:16 FROM node:16
WORKDIR /automatisch WORKDIR /automatisch
# npm registry for dev purposes RUN yarn global add @automatisch/cli@0.1.4
RUN npm config set fetch-retry-maxtimeout 5000
RUN npm config set fetch-retry-mintimeout 3000
RUN npm set registry http://localhost:5000
# npm registry for dev purposes
RUN yarn global add @automatisch/cli

View File

@@ -5,17 +5,11 @@ WORKDIR /automatisch
RUN apt-get update && apt-get install -y postgresql-client RUN apt-get update && apt-get install -y postgresql-client
COPY ./wait-for-postgres.sh /automatisch/wait-for-postgres.sh COPY ./wait-for-postgres.sh /automatisch/wait-for-postgres.sh
# npm registry for dev purposes
RUN npm config set fetch-retry-maxtimeout 5000
RUN npm config set fetch-retry-mintimeout 3000
RUN npm set registry http://localhost:5000
# npm registry for dev purposes
RUN mkdir -p /automatisch/storage RUN mkdir -p /automatisch/storage
RUN touch /automatisch/storage/.env RUN touch /automatisch/storage/.env
RUN echo "ENCRYPTION_KEY=$(openssl rand -base64 36)" >> /automatisch/storage/.env RUN echo "ENCRYPTION_KEY=$(openssl rand -base64 36)" >> /automatisch/storage/.env
RUN echo "APP_SECRET_KEY=$(openssl rand -base64 36)" >> /automatisch/storage/.env RUN echo "APP_SECRET_KEY=$(openssl rand -base64 36)" >> /automatisch/storage/.env
RUN yarn global add @automatisch/cli RUN yarn global add @automatisch/cli@0.1.4
EXPOSE 3000 EXPOSE 3000
CMD sh /automatisch/wait-for-postgres.sh automatisch start --env-file=/automatisch/storage/.env CMD sh /automatisch/wait-for-postgres.sh automatisch start --env-file=/automatisch/storage/.env

View File

@@ -2,7 +2,7 @@
"packages": [ "packages": [
"packages/*" "packages/*"
], ],
"version": "0.1.0", "version": "0.1.4",
"npmClient": "yarn", "npmClient": "yarn",
"useWorkspaces": true, "useWorkspaces": true,
"command": { "command": {

View File

@@ -1,6 +1,7 @@
{ {
"name": "@automatisch/root", "name": "@automatisch/root",
"license": "AGPL-3.0", "license": "AGPL-3.0",
"private": true,
"scripts": { "scripts": {
"start": "lerna run --stream --parallel --scope=@*/{web,backend} dev", "start": "lerna run --stream --parallel --scope=@*/{web,backend} dev",
"start:web": "lerna run --stream --scope=@*/web dev", "start:web": "lerna run --stream --scope=@*/web dev",

View File

@@ -2,11 +2,3 @@
The open source Zapier alternative. Build workflow automation without spending The open source Zapier alternative. Build workflow automation without spending
time and money. time and money.
## Usage
```
const backend = require('backend');
// TODO: DEMONSTRATE API
```

View File

@@ -1,6 +1,6 @@
{ {
"name": "@automatisch/backend", "name": "@automatisch/backend",
"version": "0.1.0", "version": "0.1.4",
"license": "AGPL-3.0", "license": "AGPL-3.0",
"description": "The open source Zapier alternative. Build workflow automation without spending time and money.", "description": "The open source Zapier alternative. Build workflow automation without spending time and money.",
"scripts": { "scripts": {
@@ -18,10 +18,11 @@
"db:rollback": "knex migrate:rollback", "db:rollback": "knex migrate:rollback",
"db:migrate": "knex migrate:latest", "db:migrate": "knex migrate:latest",
"copy-statics": "copyfiles src/**/*.{graphql,json,svg} dist", "copy-statics": "copyfiles src/**/*.{graphql,json,svg} dist",
"prepack": "yarn build" "prepack": "yarn build",
"prebuild": "rm -rf ./dist"
}, },
"dependencies": { "dependencies": {
"@automatisch/web": "^0.1.0", "@automatisch/web": "^0.1.4",
"@bull-board/express": "^3.10.1", "@bull-board/express": "^3.10.1",
"@gitbeaker/node": "^35.6.0", "@gitbeaker/node": "^35.6.0",
"@graphql-tools/graphql-file-loader": "^7.3.4", "@graphql-tools/graphql-file-loader": "^7.3.4",
@@ -99,7 +100,7 @@
"url": "https://github.com/automatisch/automatisch/issues" "url": "https://github.com/automatisch/automatisch/issues"
}, },
"devDependencies": { "devDependencies": {
"@automatisch/types": "^0.1.0", "@automatisch/types": "^0.1.4",
"@types/bcrypt": "^5.0.0", "@types/bcrypt": "^5.0.0",
"@types/bull": "^3.15.8", "@types/bull": "^3.15.8",
"@types/cors": "^2.8.12", "@types/cors": "^2.8.12",

View File

@@ -158,13 +158,13 @@ export default {
const dateTime = DateTime.fromJSDate(startDateTime); const dateTime = DateTime.fromJSDate(startDateTime);
const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(dateTime) as IJSONValue; const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(dateTime) as IJSONValue;
return [dateTimeObjectRepresentation] as IJSONValue; return { data: [dateTimeObjectRepresentation] };
}, },
async testRun($: IGlobalVariable) { async testRun($: IGlobalVariable) {
const nextCronDateTime = getNextCronDateTime(this.getInterval($.db.step.parameters)); const nextCronDateTime = getNextCronDateTime(this.getInterval($.db.step.parameters));
const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(nextCronDateTime) as IJSONValue; const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(nextCronDateTime) as IJSONValue;
return [dateTimeObjectRepresentation] as IJSONValue; return { data: [dateTimeObjectRepresentation] };
}, },
}; };

View File

@@ -52,13 +52,13 @@ export default {
const dateTime = DateTime.fromJSDate(startDateTime); const dateTime = DateTime.fromJSDate(startDateTime);
const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(dateTime) as IJSONValue; const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(dateTime) as IJSONValue;
return [dateTimeObjectRepresentation] as IJSONValue; return { data: [dateTimeObjectRepresentation] };
}, },
async testRun($: IGlobalVariable) { async testRun($: IGlobalVariable) {
const nextCronDateTime = getNextCronDateTime(this.getInterval($.db.step.parameters)); const nextCronDateTime = getNextCronDateTime(this.getInterval($.db.step.parameters));
const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(nextCronDateTime) as IJSONValue; const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(nextCronDateTime) as IJSONValue;
return [dateTimeObjectRepresentation] as IJSONValue; return { data: [dateTimeObjectRepresentation] };
}, },
}; };

View File

@@ -271,13 +271,13 @@ export default {
const dateTime = DateTime.fromJSDate(startDateTime); const dateTime = DateTime.fromJSDate(startDateTime);
const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(dateTime) as IJSONValue; const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(dateTime) as IJSONValue;
return [dateTimeObjectRepresentation] as IJSONValue; return { data: [dateTimeObjectRepresentation] };
}, },
async testRun($: IGlobalVariable) { async testRun($: IGlobalVariable) {
const nextCronDateTime = getNextCronDateTime(this.getInterval($.db.step.parameters)); const nextCronDateTime = getNextCronDateTime(this.getInterval($.db.step.parameters));
const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(nextCronDateTime) as IJSONValue; const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(nextCronDateTime) as IJSONValue;
return [dateTimeObjectRepresentation] as IJSONValue; return { data: [dateTimeObjectRepresentation] };
}, },
}; };

View File

@@ -175,13 +175,13 @@ export default {
const dateTime = DateTime.fromJSDate(startDateTime); const dateTime = DateTime.fromJSDate(startDateTime);
const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(dateTime) as IJSONValue; const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(dateTime) as IJSONValue;
return [dateTimeObjectRepresentation] as IJSONValue; return { data: [dateTimeObjectRepresentation] };
}, },
async testRun($: IGlobalVariable) { async testRun($: IGlobalVariable) {
const nextCronDateTime = getNextCronDateTime(this.getInterval($.db.step.parameters)); const nextCronDateTime = getNextCronDateTime(this.getInterval($.db.step.parameters));
const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(nextCronDateTime) as IJSONValue; const dateTimeObjectRepresentation = getDateTimeObjectRepresentation(nextCronDateTime) as IJSONValue;
return [dateTimeObjectRepresentation] as IJSONValue; return { data: [dateTimeObjectRepresentation] };
}, },
}; };

View File

@@ -33,7 +33,7 @@ const updateFlowStatus = async (
const triggerStep = await flow.getTriggerStep(); const triggerStep = await flow.getTriggerStep();
const trigger = await triggerStep.getTrigger(); const trigger = await triggerStep.getTrigger();
const interval = trigger?.getInterval(triggerStep.parameters); const interval = trigger.getInterval?.(triggerStep.parameters);
const repeatOptions = { const repeatOptions = {
cron: interval || EVERY_15_MINUTES_CRON, cron: interval || EVERY_15_MINUTES_CRON,
}; };

View File

@@ -40,7 +40,7 @@ async function getChildrenContentInDirectory<C>(
const filesInSubdirectory = fs.readdirSync(appSubdirectory); const filesInSubdirectory = fs.readdirSync(appSubdirectory);
for (const filename of filesInSubdirectory) { for (const filename of filesInSubdirectory) {
const filePath = join(appSubdirectory, filename, 'index.ts'); const filePath = join(appSubdirectory, filename);
const fileContent = await getFileContent<C>(filePath, stripFuncs); const fileContent = await getFileContent<C>(filePath, stripFuncs);
childrenContent.push(fileContent); childrenContent.push(fileContent);
@@ -56,7 +56,7 @@ const getApp = async (appKey: string, stripFuncs = true) => {
const appData: IApp = await getDefaultExport(`../apps/${appKey}`); const appData: IApp = await getDefaultExport(`../apps/${appKey}`);
appData.auth = await getFileContent<IAuth>( appData.auth = await getFileContent<IAuth>(
`../apps/${appKey}/auth/index.ts`, `../apps/${appKey}/auth`,
stripFuncs stripFuncs
); );
appData.triggers = await getChildrenContentInDirectory<ITrigger>( appData.triggers = await getChildrenContentInDirectory<ITrigger>(

View File

@@ -15,16 +15,18 @@ const globalVariable = async (
return { return {
auth: { auth: {
set: async (args: IJSONObject) => { set: async (args: IJSONObject) => {
await connection.$query().patchAndFetch({ if (connection) {
formattedData: { await connection.$query().patchAndFetch({
...connection.formattedData, formattedData: {
...args, ...connection.formattedData,
}, ...args,
}); },
});
}
return null; return null;
}, },
data: connection.formattedData, data: connection?.formattedData,
}, },
app: appData, app: appData,
http: createHttpClient({ baseURL: appData.baseUrl }), http: createHttpClient({ baseURL: appData.baseUrl }),

View File

@@ -2,9 +2,3 @@
The open source Zapier alternative. Build workflow automation without spending The open source Zapier alternative. Build workflow automation without spending
time and money. time and money.
## Usage
```
// TODO: DEMONSTRATE API
```

View File

@@ -1,6 +1,6 @@
{ {
"name": "@automatisch/cli", "name": "@automatisch/cli",
"version": "0.1.0", "version": "0.1.4",
"license": "AGPL-3.0", "license": "AGPL-3.0",
"description": "The open source Zapier alternative. Build workflow automation without spending time and money.", "description": "The open source Zapier alternative. Build workflow automation without spending time and money.",
"contributors": [ "contributors": [
@@ -33,7 +33,7 @@
"version": "oclif readme && git add README.md" "version": "oclif readme && git add README.md"
}, },
"dependencies": { "dependencies": {
"@automatisch/backend": "^0.1.0", "@automatisch/backend": "^0.1.4",
"@oclif/core": "^1", "@oclif/core": "^1",
"@oclif/plugin-help": "^5", "@oclif/plugin-help": "^5",
"@oclif/plugin-plugins": "^2.0.1", "@oclif/plugin-plugins": "^2.0.1",

View File

@@ -1,6 +1,6 @@
{ {
"name": "@automatisch/docs", "name": "@automatisch/docs",
"version": "0.1.0", "version": "0.1.4",
"license": "AGPL-3.0", "license": "AGPL-3.0",
"description": "The open source Zapier alternative. Build workflow automation without spending time and money.", "description": "The open source Zapier alternative. Build workflow automation without spending time and money.",
"private": true, "private": true,

View File

@@ -2,11 +2,3 @@
The open source Zapier alternative. Build workflow automation without spending The open source Zapier alternative. Build workflow automation without spending
time and money. time and money.
## Usage
```
const types = require('@automatisch/types');
// TODO: DEMONSTRATE API
```

View File

@@ -1,6 +1,6 @@
{ {
"name": "@automatisch/types", "name": "@automatisch/types",
"version": "0.1.0", "version": "0.1.4",
"license": "AGPL-3.0", "license": "AGPL-3.0",
"description": "Type definitions for automatisch", "description": "Type definitions for automatisch",
"homepage": "https://github.com/automatisch/automatisch", "homepage": "https://github.com/automatisch/automatisch",

View File

@@ -1,11 +1,11 @@
{ {
"name": "@automatisch/web", "name": "@automatisch/web",
"version": "0.1.0", "version": "0.1.4",
"license": "AGPL-3.0", "license": "AGPL-3.0",
"description": "The open source Zapier alternative. Build workflow automation without spending time and money.", "description": "The open source Zapier alternative. Build workflow automation without spending time and money.",
"dependencies": { "dependencies": {
"@apollo/client": "^3.6.9", "@apollo/client": "^3.6.9",
"@automatisch/types": "^0.1.0", "@automatisch/types": "^0.1.4",
"@emotion/react": "^11.4.1", "@emotion/react": "^11.4.1",
"@emotion/styled": "^11.3.0", "@emotion/styled": "^11.3.0",
"@hookform/resolvers": "^2.8.8", "@hookform/resolvers": "^2.8.8",