P
P
passstrada2020-06-22 11:51:37
Regular Expressions
passstrada, 2020-06-22 11:51:37

What regular expression to write?

How to remove the beginning of a line?

What would from:
Removed file – Data/license.htm (34.03 KiB)
Removed file – Data/license-image001.png.dvpl (7.97 KiB)
Removed file – Data/UI/Screens3/Lobby/Story/StoryBoxSimple.style.yaml.dvpl (261 B)
Removed file – Data/UI/Screens3/Lobby/Showcase/ShowcaseFullscreen.animation.dvpl (281 B)
Added file – Data/3d/Configs/Presets/hangar_prem_2018_birthday_6
Added file – Data/3d/Configs/Presets/hangar_prem_2018_birthday_6/presets.yaml.dvpl (193 B)
Added file – Data/3d/FX/hangar_prem_2018_birthday_6
Added file – Data/3d/FX/hangar_prem_2018_birthday_6/bronze.sc2.dvpl (2.21 KiB)
Modified file – Data/3d/Customization.yaml.dvpl (-108 B)
Modified file – Data/3d/FX/01_tutorial_tut/hit_surface/groundHit_AP1.sc2.dvpl
Modified file – Data/3d/FX/01_tutorial_tut/hit_surface/groundHit_AP2.sc2.dvpl
Modified file – Data/3d/FX/01_tutorial_tut/hit_surface/groundHit_AP3.sc2.dvpl

Happened:
Data/license.htm
Data/license-image001.png.dvpl
Data/UI/Screens3/Lobby/Story/StoryBoxSimple.style.yaml.dvpl
Data/UI/Screens3/Lobby/Showcase/ShowcaseFullscreen.animation.dvpl
Data/3d/Configs/Presets/hangar_prem_2018_birthday_6
Data/3d/Configs/Presets/hangar_prem_2018_birthday_6/presets.yaml.dvpl
Data/3d/FX/hangar_prem_2018_birthday_6
Data/3d/FX/hangar_prem_2018_birthday_6/bronze.sc2.dvpl
Data/3d/Customization.yaml.dvpl
Data/3d/FX/01_tutorial_tut/hit_surface/groundHit_AP1.sc2.dvpl
Data/3d/FX/01_tutorial_tut/hit_surface/groundHit_AP2.sc2.dvpl
Data/3d/FX/01_tutorial_tut/hit_surface/groundHit_AP3.sc2.dvpl

The size near the file is removed with "\s*\([^()]+\)$", is it possible to combine several regular expressions at once in Python?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Mikhail Osher, 2020-06-22
@passstrada

If files will always start with "Data", then you can (Data\S+).

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question