Skip to content

Commit

Permalink
Add sudo to sed
Browse files Browse the repository at this point in the history
  • Loading branch information
enyachoke committed Jul 11, 2024
1 parent 1c995e5 commit ca49929
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion node-scripts/src/pipeline3/scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -711,7 +711,7 @@ module.exports = {

// 'sed' will need an escaped string at runtime. Escaping.
var valueEscaped = value.replace(/\//g, "\\/");
script += `\tsed -i "s/^[#]*\\s*${propertyName}\\b.*/${propertyName}=${valueEscaped}/" ${filename}\n`;
script += `\tsudo sed -i "s/^[#]*\\s*${propertyName}\\b.*/${propertyName}=${valueEscaped}/" ${filename}\n`;
script += "fi\n";
return script;
},
Expand Down

0 comments on commit ca49929

Please sign in to comment.