Add text into string between single quotes using regexp
Question:
I am trying to use Python to add some escape characters into a string when I print to the terminal.
import re
string1 = "I am a test string"
string2 = "I have some 'quoted text' to display."
string3 = "I have 'some quotes' plus some more text and 'some other quotes'.
pattern = ... # I do not know what kind of pattern to use here
I then want to add the console color escape (
I am trying to use Python to add some escape characters into a string when I print to the terminal.
import re
string1 = "I am a test string"
string2 = "I have some 'quoted text' to display."
string3 = "I have 'some quotes' plus some more text and 'some other quotes'.
pattern = ... # I do not know what kind of pattern to use here
I then want to add the console color escape (