Filter out more broad paths

This commit is contained in:
mtkennerly 2024-04-21 20:16:03 -04:00
parent 22bae27388
commit c19bea11e5
No known key found for this signature in database
GPG key ID: E764BE00BE6E6408
4 changed files with 32 additions and 67 deletions

View file

@ -69824,11 +69824,6 @@ Bigscreen Beta:
- config - config
when: when:
- os: windows - os: windows
"<winDocuments>/*.b2g":
tags:
- save
when:
- os: windows
gog: gog:
id: 1959845271 id: 1959845271
"Biing!: Sex, Intrigue and Scalpels": "Biing!: Sex, Intrigue and Scalpels":
@ -76696,15 +76691,6 @@ BloXoR:
steam: steam:
id: 1079910 id: 1079910
Blob From Space: Blob From Space:
files:
"<winAppData>/**/*.blobfromspace":
when:
- os: windows
store: steam
"<winAppData>/**/*.jos":
when:
- os: windows
store: steam
id: id:
steamExtra: steamExtra:
- 348370 - 348370
@ -145202,15 +145188,6 @@ Dandara:
steam: steam:
id: 612390 id: 612390
Dandelion - Wishes brought to you -: Dandelion - Wishes brought to you -:
files:
"<home>/Library/RenPy":
when:
- os: mac
store: steam
"<winAppData>/RenPy":
when:
- os: windows
store: steam
id: id:
steamExtra: steamExtra:
- 404450 - 404450
@ -196834,10 +196811,6 @@ ElectricVLab:
when: when:
- os: windows - os: windows
store: steam store: steam
"<winDocuments>/**/*.lab":
when:
- os: windows
store: steam
installDir: installDir:
ElectricVLab: {} ElectricVLab: {}
launch: launch:
@ -297479,14 +297452,6 @@ Hunger:
"<base>/SavesDir/*.sav": "<base>/SavesDir/*.sav":
when: when:
- store: steam - store: steam
"<winLocalAppData>/*/**/SaveItem.sav":
when:
- os: windows
store: steam
"<winLocalAppData>/*/**/levelcomplete.ini":
when:
- os: windows
store: steam
"<winLocalAppData>/SavesDir/**/Settings.ini": "<winLocalAppData>/SavesDir/**/Settings.ini":
when: when:
- store: steam - store: steam
@ -308316,16 +308281,14 @@ IndustrialVR - Hoover Dam:
id: 768770 id: 768770
Industries of Titan: Industries of Titan:
files: files:
"<winLocalAppData>/*.met": "<winLocalAppData>/Titan/**/*.met":
tags:
- save
when: when:
- os: windows - os: windows
"<winLocalAppData>/*.sav": store: steam
tags: "<winLocalAppData>/Titan/**/*.sav":
- save
when: when:
- os: windows - os: windows
store: steam
id: id:
lutris: industries-of-titan lutris: industries-of-titan
installDir: installDir:
@ -521497,11 +521460,6 @@ SimPark:
- config - config
when: when:
- os: windows - os: windows
"<winDocuments>/*.prk":
tags:
- save
when:
- os: windows
SimRail - The Railway Simulator: SimRail - The Railway Simulator:
files: files:
"<home>/AppData/LocalLow/SimKol/SimRail/buttons.conf": "<home>/AppData/LocalLow/SimKol/SimRail/buttons.conf":
@ -521536,13 +521494,6 @@ SimSafari:
- config - config
when: when:
- os: windows - os: windows
SimTown:
files:
"<winDocuments>/*.twn":
tags:
- save
when:
- os: windows
SimTunes: SimTunes:
files: files:
"<base>/Tunes": "<base>/Tunes":
@ -609263,12 +609214,6 @@ The Pinball Wizard:
steam: steam:
id: 2101800 id: 2101800
The Pink Panther in Hokus Pokus Pink: The Pink Panther in Hokus Pokus Pink:
files:
"<winDocuments>/*.pk2":
tags:
- save
when:
- os: windows
registry: registry:
HKEY_CURRENT_USER/Software/Wanderlust/The Pink Panther in Hokus Pokus Pink: HKEY_CURRENT_USER/Software/Wanderlust/The Pink Panther in Hokus Pokus Pink:
tags: tags:
@ -646972,13 +646917,6 @@ Ultimate War:
store: steam store: steam
steam: steam:
id: 514490 id: 514490
Ultimate Yahtzee:
files:
"<winDocuments>/*.yat":
tags:
- save
when:
- os: windows
Ultimate Zombie Defense: Ultimate Zombie Defense:
installDir: installDir:
Ultimate Zombie Defense: {} Ultimate Zombie Defense: {}

View file

@ -3102,6 +3102,7 @@
* [Blitzkrieg 2](https://www.pcgamingwiki.com/wiki/?curid=13949) * [Blitzkrieg 2](https://www.pcgamingwiki.com/wiki/?curid=13949)
* [Blitzkrieg 3](https://www.pcgamingwiki.com/wiki/?curid=34192) * [Blitzkrieg 3](https://www.pcgamingwiki.com/wiki/?curid=34192)
* [Blixten Quest](https://www.pcgamingwiki.com/wiki/?curid=122494) * [Blixten Quest](https://www.pcgamingwiki.com/wiki/?curid=122494)
* [Blob From Space](https://www.pcgamingwiki.com/wiki/?curid=49508)
* [Blobby Tennis](https://www.pcgamingwiki.com/wiki/?curid=62032) * [Blobby Tennis](https://www.pcgamingwiki.com/wiki/?curid=62032)
* [Block](https://www.pcgamingwiki.com/wiki/?curid=140804) * [Block](https://www.pcgamingwiki.com/wiki/?curid=140804)
* [Block bat invasion](https://www.pcgamingwiki.com/wiki/?curid=134429) * [Block bat invasion](https://www.pcgamingwiki.com/wiki/?curid=134429)
@ -5960,6 +5961,7 @@
* [Dancing Queen](https://www.pcgamingwiki.com/wiki/?curid=148597) * [Dancing Queen](https://www.pcgamingwiki.com/wiki/?curid=148597)
* [Dancing with Anime Girls VR](https://www.pcgamingwiki.com/wiki/?curid=156766) * [Dancing with Anime Girls VR](https://www.pcgamingwiki.com/wiki/?curid=156766)
* [DanCop - Daniela on Duty](https://www.pcgamingwiki.com/wiki/?curid=135217) * [DanCop - Daniela on Duty](https://www.pcgamingwiki.com/wiki/?curid=135217)
* [Dandelion - Wishes brought to you -](https://www.pcgamingwiki.com/wiki/?curid=37691)
* [Dandy & Randy](https://www.pcgamingwiki.com/wiki/?curid=121409) * [Dandy & Randy](https://www.pcgamingwiki.com/wiki/?curid=121409)
* [Dandy Dungeon - Legend of Brave Yamada -](https://www.pcgamingwiki.com/wiki/?curid=152871) * [Dandy Dungeon - Legend of Brave Yamada -](https://www.pcgamingwiki.com/wiki/?curid=152871)
* [Dandy: Or a Brief Glimpse Into the Life of the Candy Alchemist](https://www.pcgamingwiki.com/wiki/?curid=46993) * [Dandy: Or a Brief Glimpse Into the Life of the Candy Alchemist](https://www.pcgamingwiki.com/wiki/?curid=46993)
@ -23981,6 +23983,7 @@
* [Simraceway](https://www.pcgamingwiki.com/wiki/?curid=186058) * [Simraceway](https://www.pcgamingwiki.com/wiki/?curid=186058)
* [Simson Tuningwerkstatt 3D](https://www.pcgamingwiki.com/wiki/?curid=122346) * [Simson Tuningwerkstatt 3D](https://www.pcgamingwiki.com/wiki/?curid=122346)
* [SimTower](https://www.pcgamingwiki.com/wiki/?curid=51200) * [SimTower](https://www.pcgamingwiki.com/wiki/?curid=51200)
* [SimTown](https://www.pcgamingwiki.com/wiki/?curid=19817)
* [Simulator Gas Station](https://www.pcgamingwiki.com/wiki/?curid=65831) * [Simulator Gas Station](https://www.pcgamingwiki.com/wiki/?curid=65831)
* [Simulator Hipstera 2k17](https://www.pcgamingwiki.com/wiki/?curid=69643) * [Simulator Hipstera 2k17](https://www.pcgamingwiki.com/wiki/?curid=69643)
* [Sin Castle](https://www.pcgamingwiki.com/wiki/?curid=58360) * [Sin Castle](https://www.pcgamingwiki.com/wiki/?curid=58360)
@ -30765,6 +30768,7 @@
* [Ultimate Tic-Tac-Toe](https://www.pcgamingwiki.com/wiki/?curid=48068) * [Ultimate Tic-Tac-Toe](https://www.pcgamingwiki.com/wiki/?curid=48068)
* [Ultimate War](https://www.pcgamingwiki.com/wiki/?curid=98914) * [Ultimate War](https://www.pcgamingwiki.com/wiki/?curid=98914)
* [Ultimate Word Search 2: Letter Boxed](https://www.pcgamingwiki.com/wiki/?curid=36151) * [Ultimate Word Search 2: Letter Boxed](https://www.pcgamingwiki.com/wiki/?curid=36151)
* [Ultimate Yahtzee](https://www.pcgamingwiki.com/wiki/?curid=7462)
* [Ultimate Zombie Defense](https://www.pcgamingwiki.com/wiki/?curid=156436) * [Ultimate Zombie Defense](https://www.pcgamingwiki.com/wiki/?curid=156436)
* [Ultimo Reino](https://www.pcgamingwiki.com/wiki/?curid=122460) * [Ultimo Reino](https://www.pcgamingwiki.com/wiki/?curid=122460)
* [Ultimus bellum](https://www.pcgamingwiki.com/wiki/?curid=74530) * [Ultimus bellum](https://www.pcgamingwiki.com/wiki/?curid=74530)

View file

@ -26,6 +26,20 @@ pub mod placeholder {
XDG_CONFIG, XDG_CONFIG,
]; ];
/// These are paths where `<placeholder>/*/` is suspicious.
pub const AVOID_WILDCARDS: &[&str] = &[
ROOT,
HOME,
WIN_APP_DATA,
WIN_LOCAL_APP_DATA,
WIN_DOCUMENTS,
WIN_PUBLIC,
WIN_PROGRAM_DATA,
WIN_DIR,
XDG_DATA,
XDG_CONFIG,
];
pub const ROOT: &str = "<root>"; pub const ROOT: &str = "<root>";
pub const GAME: &str = "<game>"; pub const GAME: &str = "<game>";
pub const BASE: &str = "<base>"; pub const BASE: &str = "<base>";

View file

@ -51,7 +51,7 @@ pub fn normalize(path: &str) -> String {
} }
pub fn too_broad(path: &str) -> bool { pub fn too_broad(path: &str) -> bool {
use placeholder::{BASE, HOME, ROOT, STORE_USER_ID, WIN_DIR, WIN_DOCUMENTS, XDG_CONFIG, XDG_DATA}; use placeholder::{BASE, HOME, ROOT, STORE_USER_ID, WIN_APP_DATA, WIN_DIR, WIN_DOCUMENTS, XDG_CONFIG, XDG_DATA};
for item in placeholder::ALL { for item in placeholder::ALL {
if path == *item { if path == *item {
@ -59,6 +59,12 @@ pub fn too_broad(path: &str) -> bool {
} }
} }
for item in placeholder::AVOID_WILDCARDS {
if path.starts_with(&format!("{item}/*")) {
return true;
}
}
// These paths are present whether or not the game is installed. // These paths are present whether or not the game is installed.
// If possible, they should be narrowed down on the wiki. // If possible, they should be narrowed down on the wiki.
for item in [ for item in [
@ -73,8 +79,11 @@ pub fn too_broad(path: &str) -> bool {
format!("{HOME}/Documents/My Games"), format!("{HOME}/Documents/My Games"),
format!("{HOME}/Library/Application Support"), format!("{HOME}/Library/Application Support"),
format!("{HOME}/Library/Preferences"), format!("{HOME}/Library/Preferences"),
format!("{HOME}/.renpy"),
format!("{HOME}/Library/RenPy"),
format!("{HOME}/Telltale Games"), format!("{HOME}/Telltale Games"),
format!("{ROOT}/config"), format!("{ROOT}/config"),
format!("{WIN_APP_DATA}/RenPy"),
format!("{WIN_DIR}/win.ini"), format!("{WIN_DIR}/win.ini"),
format!("{WIN_DIR}/SysWOW64"), format!("{WIN_DIR}/SysWOW64"),
format!("{WIN_DOCUMENTS}/My Games"), format!("{WIN_DOCUMENTS}/My Games"),