修改变量

lessc --modify-var="color1=red" { modifyVars: { color1: 'red' } }

与全局变量选项相反,这会将声明放在基础文件的末尾,这意味着它将覆盖 Less 文件中定义的任何内容。