support more %environment variables% in winapp2.ini

Bug #1352683 reported by Andrew Ziem
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
BleachBit
Fix Released
High
Andrew Ziem

Bug Description

BleachBit 1.2 supports only some of those currently used in winapp2.ini. The currently supported variables are those that already defined by Windows (such as TMP).

BleachBit 1.4 fully supports ProgramFiles and CommonProgramFiles

Others below (but not all below) need to be supported

$ grep -Po '%[\w\d]*\%' /tmp/Winapp2.ini | sort -f | uniq -ci
 3 %AllUsersProfile%
   1235 %appdata% **
    592 %CommonAppData%
     21 %CommonProgramFiles%
    312 %Documents%
      4 %HomeDrive% **
   2692 %localappdata% **
     37 %LocalLowAppData%
      4 %Music%
     14 %Pictures%
   1113 %ProgramFiles% **
     14 %Public% **
      1 %RootDir%
    196 %SystemDrive% **
      1 %SystemRoot% **
      3 %temp% **
      1 %user%
    149 %UserProfile% **
      2 %Video%
    237 %WinDir% **

**Already set by Windows: AppData, HomeDrive, localappdata, ProgramFiles, Public, SystemDrive, SystemRoot, Temp, UserProfile, WinDir

Andrew Ziem (ahziem1)
description: updated
Andrew Ziem (ahziem1)
tags: added: easy
Andrew Ziem (ahziem1)
Changed in bleachbit:
milestone: 2.0 → 1.8
importance: Undecided → High
Andrew Ziem (ahziem1)
description: updated
Andrew Ziem (ahziem1)
description: updated
Revision history for this message
Andrew Ziem (ahziem1) wrote :

Commit c722ca7 adds commonappdata, localappdata, music, pictures, video for BleachBit 1.7

Revision history for this message
Andrew Ziem (ahziem1) wrote :

LocalLowAppData does not have a CSIDL for use with SHGetSpecialFolderPath

Instead, it can be identified using its GUID {A520A1A4-1780-4FF6-BD18-167343C5AF16} and SHGetKnownFolderPath

Reference: http://msdn.microsoft.com/en-us/library/windows/desktop/dd378457%28v=vs.85%29.aspx

Andrew Ziem (ahziem1)
Changed in bleachbit:
status: Triaged → In Progress
Revision history for this message
Andrew Ziem (ahziem1) wrote :

GPL v3 Python code here for LocalAppDataLow
https://gist.github.com/mkropat/7550097

Revision history for this message
ROCKNROLLKID (slinger1410-deactivatedaccount) wrote :

Can you also do SpecialDetect= for Firefox, Chrome and other entries. The discussion topic is here: http://bleachbit.sourceforge.net/forum/bug-specialdetect

Revision history for this message
Andrew Ziem (ahziem1) wrote :

ROCKNROLLKID: Please file a separate bug ticket for SpecialDetect=

Revision history for this message
Andrew Ziem (ahziem1) wrote :

Fixed in commit 116b850 by adding %LocalAppDataLow%

Changed in bleachbit:
assignee: nobody → Andrew Ziem (ahziem1)
status: In Progress → Fix Committed
Revision history for this message
Andrew Ziem (ahziem1) wrote :

Link to BleachBit 1.7.5 downloads for testing:
https://sourceforge.net/projects/bleachbit/files/bleachbit/1.7.5alpha/

Revision history for this message
Andrew Ziem (ahziem1) wrote :

cfoellmann: "I tried the 1.7.5 alpha and the $MUSIC variable does not work."

--- https://github.com/az0/bleachbit/issues/90#issuecomment-95487970

Changed in bleachbit:
status: Fix Committed → In Progress
Andrew Ziem (ahziem1)
Changed in bleachbit:
status: In Progress → Fix Committed
Andrew Ziem (ahziem1)
Changed in bleachbit:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.