Variables
Const breakPattern
breakPattern: RegExp = /\n/g
Const breakReplacement
breakReplacement: "\n" = "\n"
Const flags
flags: "gm" = "gm"
Const groupPattern
groupPattern: RegExp = /\$/g
Const groupReplacement
groupReplacement: "$$$" = "$$$"
Const h
h: "[^\S\r\n]" = "[^\S\r\n]"
Const returnPattern
returnPattern: RegExp = /\r/g
Const returnReplacement
returnReplacement: "\r" = "\r"
Edit a .env file. This code was taken from https://github.com/stevenvachon/edit-dotenv and converted to Typescript by myself.