bleachbit / wishlist

Wishlist enhancements related to BleachBit
GNU General Public License v3.0
7 stars 1 forks source link

Support cleaning parts of XML using CleanerML #29

Open Tobias-B-Besemer opened 5 years ago

Tobias-B-Besemer commented 5 years ago

BleachBit should have a XML Cleaner.

Programs found so far that store data in XML files:

Tobias-B-Besemer commented 5 years ago

I included in the file notepad++.xml some code (as comment) that shows how I think it should/can look later like... Here is the PR with the file: https://github.com/az0/cleanerml/pull/201

Tobias-B-Besemer commented 5 years ago

I did a other sample in the double_commander.xml... -> https://github.com/az0/cleanerml/pull/202

az0 commented 5 years ago

I agree this would be nice

Tobias-B-Besemer commented 5 years ago

I saw that the Python Standard Library includes limited support for XPath expressions... https://en.wikipedia.org/wiki/XPath#Python

az0 commented 5 years ago

Yes, that might help. There actually is an old XML cleaner for OpenOffice, but it's not in cleanerml.

Tobias-B-Besemer commented 5 years ago

I want to docu a bit the cleaners that need XML-Support for later... (...to come back to them...)

Cleaners that need XML, too:

Tobias-B-Besemer commented 5 years ago

I found a other scenario in filezilla.xml... ...here is a syntax that I can imagine... <action command="xml" search="file" path="$$profile$$/filezilla.xml" element="FileZilla3/Settings/Setting" attribute="name=Last Server Path"/> Explanation: Deletes with a "name=value" as value of "attribute" the content of "". ...Example: <FileZilla3 version="3.32.0" platform="windows"> <Settings> <Setting name="Last Server Path">ftp://ftp.demo.org</Setting> -> Deletes "ftp://ftp.demo.org"

Tobias-B-Besemer commented 5 years ago

I found a other scenario in filezilla.xml... ...here is a syntax how I can imagine... <action command="xml" search="file" path="$$profile$$/filezilla.xml" element="FileZilla3/Settings/Setting" attribute="name=Last Server Path"/> Explanation: Deletes with a "name=value" as value of "attribute" the content of "". ...Example: `

ftp://ftp.demo.org` -> Deletes "ftp://ftp.demo.org"