feat(desktop,launcher): default to ~/.waggle-community (P1.3c)
The Tauri shell's bundled npm environment and its first-launch flag, the server installer's --data-dir default and the NSIS installer config fell back to ~/.waggle. Use ~/.waggle-community (ADR-0011). The Rust shell keeps the name in DEFAULT_DATA_DIR_NAME in lib.rs and the launcher, which uses only Node built-ins, in DATA_DIR_NAME. packages/shared/tests/data-dir.test.ts fails when either copy, or the marketplace's, differs from @waggle/shared.
This commit is contained in:
@@ -92,7 +92,8 @@ describe('platform paths', () => {
|
||||
});
|
||||
|
||||
it('follows the sidecar data directory rule', () => {
|
||||
expect(defaultDataDir(host('linux'))).toBe('/home/ana/.waggle');
|
||||
expect(defaultDataDir(host('linux'))).toBe('/home/ana/.waggle-community');
|
||||
expect(defaultDataDir(host('win32'))).toBe('C:\\Users\\ana\\.waggle-community');
|
||||
expect(defaultDataDir(host('linux', { WAGGLE_DATA_DIR: '/srv/waggle' }))).toBe('/srv/waggle');
|
||||
});
|
||||
|
||||
@@ -107,7 +108,7 @@ describe('payload helpers', () => {
|
||||
it('gives the server the environment the desktop shell gives it', () => {
|
||||
const env = serviceEnvironment({
|
||||
appDir: '/opt/w/app',
|
||||
dataDir: '/home/ana/.waggle',
|
||||
dataDir: '/home/ana/.waggle-community',
|
||||
port: 4000,
|
||||
platform: 'linux',
|
||||
baseEnv: { PATH: '/usr/bin', WAGGLE_DATA_DIR: '/stale' },
|
||||
@@ -119,8 +120,8 @@ describe('payload helpers', () => {
|
||||
WAGGLE_FRONTEND_DIR: '/opt/w/app/web',
|
||||
NODE_PATH: '/opt/w/app/node_modules:/opt/w/app/native',
|
||||
PATH: '/opt/w/app/node_modules/waggle-node-runtime/bin:/opt/w/app:/usr/bin',
|
||||
NPM_CONFIG_PREFIX: '/home/ana/.waggle/npm/prefix',
|
||||
NPM_CONFIG_CACHE: '/home/ana/.waggle/npm/cache',
|
||||
NPM_CONFIG_PREFIX: '/home/ana/.waggle-community/npm/prefix',
|
||||
NPM_CONFIG_CACHE: '/home/ana/.waggle-community/npm/cache',
|
||||
});
|
||||
expect(env.WAGGLE_DATA_DIR).toBeUndefined();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user