Skip to content

Commit

Permalink
fix: having to hit the up arrow key so many times to get to the previ…
Browse files Browse the repository at this point in the history
…ous command
  • Loading branch information
joeyguerra committed Aug 15, 2024
1 parent 93b5583 commit 49d35e4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/adapters/Shell.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ class Shell extends Adapter {
})

const existingHistory = (await fs.promises.readFile(historyPath, 'utf8')).split('\n')
existingHistory.forEach(line => this.#rl.history.push(line))
existingHistory.reverse().forEach(line => this.#rl.history.push(line))

try {
this.#rl.prompt()
Expand Down

0 comments on commit 49d35e4

Please sign in to comment.