From 901d010741485bff96d18b4c1706d87e269f436d Mon Sep 17 00:00:00 2001 From: Waldir Pimenta Date: Fri, 16 Jan 2026 19:15:47 +0000 Subject: docs: Various improvements to the `atuin import` docs (#3062) Recreation of PR https://github.com/atuinsh/docs/pull/111, after the migration of the docs to this repo (#3018). Copying the description from that PR, for convenience: This PR implements a few improvements to the import doc page. 1. **Fix name of `zsh-hist-db` and `xonsh-sqlite` subcommands** The `atuin import` subcommands `zsh-hist-db` and `xonsh-sqlite` were incorrectly documented as `zsh_histdb` and `xonsh_sqlite`, respectively. This is likely due to the actual modules that implement the import functionality being indeed named `zsh_histdb` and `xonsh_sqlite` (see [here](https://github.com/atuinsh/atuin/blob/v18.10.0/crates/atuin/src/command/client/import.rs#L14) and [here](https://github.com/atuinsh/atuin/blob/v18.10.0/crates/atuin-client/src/import/mod.rs#L19-L21)), but for the end-user, that results in documentation that's confusing at best, and error-inducing at worst. Fixes issue [atuinsh/atuin#2533](https://github.com/atuinsh/atuin/issues/2533). 2. **Document the `powershell` and `replxx` import subcommands** These importers were introduced in PRs [atuinsh/atuin#2864](https://github.com/atuinsh/atuin/pull/2864) and [atuinsh/atuin#2024](https://github.com/atuinsh/atuin/pull/2024), respectively, but the documentation was not updated to account for them. 3. **Fix alphabetic sorting of sections** Move the `nu-hist-db` and `zsh-hist-db` sections to be after `nu` and `zsh`, respectively. This is more intuitive, and matches the existing sort used for the `xonsh` / `xonsh-sqlite` sections. 4. **Minor whitespace correction** Fix line wrapping in the `resh` section ~~and remove trailing whitespace in the `nu*` sections.~~ ## Checks - [x] I am happy for maintainers to push small adjustments to this PR, to speed up the review cycle - [x] I have checked that there are no existing pull requests for the same thing Fixes #2533. --- docs/docs/reference/import.md | 38 +++++++++++++++++++++++++++----------- 1 file changed, 27 insertions(+), 11 deletions(-) (limited to 'docs') diff --git a/docs/docs/reference/import.md b/docs/docs/reference/import.md index a618e2c8..05a4e466 100644 --- a/docs/docs/reference/import.md +++ b/docs/docs/reference/import.md @@ -41,21 +41,37 @@ will be `{session}_history` in `$XDG_DATA_HOME/fish/` (or `$HOME/.local/share/fi Not all of the data in the fish history is preserved, some data about filenames used for each command are not used by Atuin, so it is discarded. +## nu + +This importer reads from Nushell's text history format, which is stored in +`$XDG_CONFIG_HOME/nushell/history.txt` or `$HOME/.config/nushell/history.txt`. +There is no way to set the filename otherwise. + ## nu-hist-db This importer reads from Nushell's SQLite history database, which is stored in `$XDG_CONFIG_HOME/nushell/history.sqlite3` or `$HOME/.config/nushell/history.sqlite3`. There is no way to set the filename otherwise. -## nu +## powershell -This importer reads from Nushell's text history format, which is stored in -`$XDG_CONFIG_HOME/nushell/history.txt` or `$HOME/.config/nushell/history.txt`. -There is no way to set the filename otherwise. +This importer reads from +[PowerShell's history file](https://learn.microsoft.com/en-us/powershell/module/psreadline/about/about_psreadline#command-history). +On Windows, the file is located at +`$APPDATA\Microsoft\Windows\PowerShell\PSReadLine\ConsoleHost_history.txt`. +On other systems, it is located at +`$XDG_DATA_HOME/powershell/PSReadLine/ConsoleHost_history.txt` +or `$HOME/.local/share/powershell/PSReadLine/ConsoleHost_history.txt`. + +## replxx + +The [replxx](https://github.com/AmokHuginnsson/replxx) importer will read from +`$HISTFILE` or `$HOME/.histfile`. ## resh -The [RESH](https://github.com/curusarn/resh) importer will read from `$HISTFILE` or `$HOME/.resh_history.json`. +The [RESH](https://github.com/curusarn/resh) importer will read from `$HISTFILE` +or `$HOME/.resh_history.json`. ## xonsh @@ -72,7 +88,7 @@ environment variables present when each session was initiated, but this data is discarded by Atuin. Xonsh optionally stores the output of each command; if present this data is also ignored by Atuin. -## xonsh_sqlite +## xonsh-sqlite The Xonsh SQLite importer will read from the Xonsh SQLite history file. The history file's location is determined by the same process as the regular Xonsh importer, @@ -82,12 +98,12 @@ The Xonsh SQLite backend does not store environment variables, but like the JSON backend it can optionally store the output of each command. As with the JSON backend, if present this data will be ignored by Atuin. -## zsh_histdb - -This will read the Zsh histdb SQLite file from `$HISTDB_FILE` or -`$HOME/.histdb/zsh-history.db`. - ## zsh This will read the Zsh history from `$HISTFILE` or `$HOME/.zhistory` or `$HOME/.zsh_history` in either the simple or extended format. + +## zsh-hist-db + +This will read the Zsh histdb SQLite file from `$HISTDB_FILE` or +`$HOME/.histdb/zsh-history.db`. -- cgit v1.3.1