diff --git a/lib/system-status.js b/lib/system-status.js index 918e1b8..c8103a4 100644 --- a/lib/system-status.js +++ b/lib/system-status.js @@ -156,8 +156,8 @@ customElements.define('system-status', class extends HTMLElement { } else { const bash = this.paths.some((bin) => fs.existsSync(path.join(bin, 'bash'))) const zsh = this.paths.some((bin) => fs.existsSync(path.join(bin, 'zsh'))) - fs.writeFileSync(path.join(os.homedir(), bash ? '.bashrc' : '.profile'), this.statement + '\n') - if (zsh) fs.writeFileSync(path.join(os.homedir(), '.zshrc'), this.statement + '\n') + fs.writeFileSync(path.join(os.homedir(), bash ? '.bashrc' : '.profile'), this.statement + '\n', { flags: 'a' }) + if (zsh) fs.writeFileSync(path.join(os.homedir(), '.zshrc'), this.statement + '\n', { flags: 'a' }) } const pear = path.join(BIN, 'pear')