Skip to content

Commit

Permalink
fixing path for UI files
Browse files Browse the repository at this point in the history
  • Loading branch information
tee8z committed Jan 5, 2025
1 parent c8753b8 commit 2c815f2
Show file tree
Hide file tree
Showing 10 changed files with 60 additions and 59 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion doppler/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
edition = "2021"
name = "doppler"
version = "0.4.0"
version = "0.4.1"
repository = "https://github.com/tee8z/doppler.git"

[package.metadata.dist]
Expand Down
100 changes: 50 additions & 50 deletions doppler_ui/package.json
Original file line number Diff line number Diff line change
@@ -1,51 +1,51 @@
{
"name": "doppler",
"version": "0.4.0",
"repository": "github:tee8z/doppler",
"bin": {
"doppler_ui": "build/index.js"
},
"scripts": {
"dev": "vite dev",
"build": "vite build",
"dist": "node dist.cjs",
"preview": "vite preview",
"check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
"check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch",
"test": "vitest",
"lint": "prettier --plugin-search-dir . --check . && eslint .",
"format": "prettier --plugin-search-dir . --write ."
},
"devDependencies": {
"@sveltejs/kit": "2.7.2",
"@types/ini": "^4.1.0",
"@typescript-eslint/eslint-plugin": "8.10.0",
"@typescript-eslint/parser": "8.10.0",
"autoprefixer": "^10.4.15",
"eslint": "^9.12.0",
"eslint-config-prettier": "9.1.0",
"eslint-plugin-svelte": "^2.45.1",
"postcss": "^8.4.29",
"prettier": "3.3.3",
"prettier-plugin-svelte": "3.2.7",
"svelte": "5.0.2",
"@sveltejs/adapter-node": "5.2.8",
"svelte-check": "4.0.5",
"tailwindcss": "^3.3.3",
"tslib": "^2.4.1",
"typescript": "^5.0.0",
"vite": "5.4.9",
"vitest": "2.1.3"
},
"type": "module",
"dependencies": {
"bun": "^1.0.0",
"chokidar": "^4.0.1",
"cytoscape": "^3.30.2",
"cytoscape-cose-bilkent": "^4.1.0",
"ini": "5.0.0",
"node-fetch": "^3.3.2",
"path-browserify": "^1.0.1",
"uuid": "^10.0.0"
}
}
"name": "doppler",
"version": "0.4.1",
"repository": "github:tee8z/doppler",
"bin": {
"doppler_ui": "build/index.js"
},
"scripts": {
"dev": "vite dev",
"build": "vite build",
"dist": "node dist.cjs",
"preview": "vite preview",
"check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
"check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch",
"test": "vitest",
"lint": "prettier --plugin-search-dir . --check . && eslint .",
"format": "prettier --plugin-search-dir . --write ."
},
"devDependencies": {
"@sveltejs/kit": "2.7.2",
"@types/ini": "^4.1.0",
"@typescript-eslint/eslint-plugin": "8.10.0",
"@typescript-eslint/parser": "8.10.0",
"autoprefixer": "^10.4.15",
"eslint": "^9.12.0",
"eslint-config-prettier": "9.1.0",
"eslint-plugin-svelte": "^2.45.1",
"postcss": "^8.4.29",
"prettier": "3.3.3",
"prettier-plugin-svelte": "3.2.7",
"svelte": "5.0.2",
"@sveltejs/adapter-node": "5.2.8",
"svelte-check": "4.0.5",
"tailwindcss": "^3.3.3",
"tslib": "^2.4.1",
"typescript": "^5.0.0",
"vite": "5.4.9",
"vitest": "2.1.3"
},
"type": "module",
"dependencies": {
"bun": "^1.0.0",
"chokidar": "^4.0.1",
"cytoscape": "^3.30.2",
"cytoscape-cose-bilkent": "^4.1.0",
"ini": "5.0.0",
"node-fetch": "^3.3.2",
"path-browserify": "^1.0.1",
"uuid": "^10.0.0"
}
}
2 changes: 1 addition & 1 deletion doppler_ui/src/routes/api/connections/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ function safeReadFileSync(path: string): Buffer | null {
}
}

const configPath = UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const configPath = UI_CONFIG_PATH || process.env.UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');

//TODO: have the info.conf be change based on the run script
export const GET: RequestHandler = async function () {
Expand Down
3 changes: 2 additions & 1 deletion doppler_ui/src/routes/api/download/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ import path from 'path';
import { parse } from 'ini';
import { UI_CONFIG_PATH } from '$env/static/private';

const configPath = UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const configPath = UI_CONFIG_PATH || process.env.UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');

const config = parse(fs.readFileSync(`${configPath}/server.conf.ini`, 'utf-8'));

const DOPPLER_SCRIPTS_FOLDER = config.paths.dopplerScriptsFolder;
Expand Down
2 changes: 1 addition & 1 deletion doppler_ui/src/routes/api/logs/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import chokidar from 'chokidar';
import { parse } from 'ini';
import { UI_CONFIG_PATH } from '$env/static/private';

const configPath = UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const configPath = UI_CONFIG_PATH || process.env.UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const config = parse(fs.readFileSync(`${configPath}/server.conf.ini`, 'utf-8'));
const LOGS_FOLDER = config.paths.logsFolder;

Expand Down
2 changes: 1 addition & 1 deletion doppler_ui/src/routes/api/reset/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { logStreamManager } from '$lib/log_stream_manager';
import { UI_CONFIG_PATH } from '$env/static/private';

// Read and parse the INI config file
const configPath = UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const configPath = UI_CONFIG_PATH || process.env.UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const config = parse(fs.readFileSync(`${configPath}/server.conf.ini`, 'utf-8'));

const LOGS_FOLDER = config.paths.logsFolder;
Expand Down
2 changes: 1 addition & 1 deletion doppler_ui/src/routes/api/run/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { createLogParser } from '$lib/log_transformers';
import { logStreamManager } from '$lib/log_stream_manager';
import { UI_CONFIG_PATH } from '$env/static/private';

const configPath = UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const configPath = UI_CONFIG_PATH || process.env.UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const config = parse(fs.readFileSync(`${configPath}/server.conf.ini`, 'utf-8'));

const DOPPLER_SCRIPTS_FOLDER = config.paths.dopplerScriptsFolder;
Expand Down
2 changes: 1 addition & 1 deletion doppler_ui/src/routes/api/save/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import path from 'path';
import { parse } from 'ini';
import { UI_CONFIG_PATH } from '$env/static/private';

const configPath = UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const configPath = UI_CONFIG_PATH || process.env.UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const config = parse(fs.readFileSync(`${configPath}/server.conf.ini`, 'utf-8'));

const DOPPLER_SCRIPTS_FOLDER = config.paths.dopplerScriptsFolder;
Expand Down
2 changes: 1 addition & 1 deletion doppler_ui/src/routes/api/scripts/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { parse } from 'ini';
import { getDirectoryTree } from '$lib/file_accessor';
import { UI_CONFIG_PATH } from '$env/static/private';

const configPath = UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const configPath = UI_CONFIG_PATH || process.env.UI_CONFIG_PATH || path.join(process.cwd(), '/build/ui_config');
const config = parse(fs.readFileSync(`${configPath}/server.conf.ini`, 'utf-8'));

const DOPPLER_SCRIPTS_FOLDER = config.paths.dopplerScriptsFolder;
Expand Down

0 comments on commit 2c815f2

Please sign in to comment.