@@ -32,6 +32,10 @@ fs.writeFileSync(flagPath, 'full');
3232const qoderFlagPath = path . join ( home , '.qoder' , '.ponytail-active' ) ;
3333fs . mkdirSync ( path . dirname ( qoderFlagPath ) , { recursive : true } ) ;
3434fs . writeFileSync ( qoderFlagPath , 'ultra' ) ;
35+ const qoderCustomDir = path . join ( temp , 'qoder-custom-config' ) ;
36+ const qoderCustomFlagPath = path . join ( qoderCustomDir , '.ponytail-active' ) ;
37+ fs . mkdirSync ( qoderCustomDir , { recursive : true } ) ;
38+ fs . writeFileSync ( qoderCustomFlagPath , 'lite' ) ;
3539
3640const nudgeFlagPath = path . join ( claudeDir , '.ponytail-statusline-nudged' ) ;
3741fs . writeFileSync ( nudgeFlagPath , '' ) ;
@@ -80,6 +84,7 @@ let result = runUninstall(env);
8084assert . equal ( result . status , 0 , result . stderr ) ;
8185assert . equal ( fs . existsSync ( flagPath ) , false , 'mode flag must be removed' ) ;
8286assert . equal ( fs . existsSync ( qoderFlagPath ) , false , 'Qoder mode flag must be removed' ) ;
87+ assert . equal ( fs . existsSync ( qoderCustomFlagPath ) , true , 'default Qoder uninstall must not touch a separate custom config' ) ;
8388assert . equal ( fs . existsSync ( nudgeFlagPath ) , false , 'statusline nudge flag must be removed' ) ;
8489assert . equal ( fs . existsSync ( configPath ) , false , 'config file must be removed' ) ;
8590assert . equal ( fs . existsSync ( cursorFlagPath ) , false , 'Cursor mode flag must be removed' ) ;
@@ -141,6 +146,10 @@ assert.equal(
141146 'a combined statusLine must keep the non-ponytail command' ,
142147) ;
143148
149+ result = runUninstall ( { ...env , QODER_CONFIG_DIR : qoderCustomDir } ) ;
150+ assert . equal ( result . status , 0 , result . stderr ) ;
151+ assert . equal ( fs . existsSync ( qoderCustomFlagPath ) , false , 'Qoder custom config mode flag must be removed' ) ;
152+
144153// #434: a malformed settings.json must not crash the script mid-cleanup. It
145154// can't be safely edited, so uninstall warns and leaves the file byte-for-byte
146155// intact instead of throwing a SyntaxError after other state was already removed.
0 commit comments