BASH integration: No longer modify .bashrc to load shell integration
I think I have things setup robustly so that the shell integration is loaded transparently via env vars and the normal bash startup files are sourced, in the same way that vanilla bash does it. Let's hope I haven't overlooked something.
This commit is contained in:
@@ -190,13 +190,11 @@ update-checking
|
||||
|
||||
shell-integration
|
||||
|kitty| by default injects its :ref:`shell_integration` code into the user's
|
||||
shell using environment variables or (for bash only) modifying
|
||||
the user's :file:`~/.bashrc` file.
|
||||
For a package, it might make more sense to distribute the shell
|
||||
integration scripts into the system-wide shell vendor locations. The
|
||||
shell integration files are found in the :file:`shell-integration`
|
||||
directory. Copy them to the system wide shell vendor locations for each
|
||||
shell, and use::
|
||||
shell using environment variables. For a package, it might make more sense
|
||||
to distribute the shell integration scripts into the system-wide shell
|
||||
vendor locations. The shell integration files are found in the
|
||||
:file:`shell-integration` directory. Copy them to the system wide shell
|
||||
vendor locations for each shell, and use::
|
||||
|
||||
./setup.py linux-package --shell-integration=enabled\ no-rc
|
||||
|
||||
|
||||
@@ -78,6 +78,8 @@ Detailed list of changes
|
||||
0.24.3 [future]
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
- BASH integration: No longer modify :file:`~/.bashrc` to load :ref:`shell integration <shell_integration>`
|
||||
|
||||
- macOS: Allow kitty to handle various URL types. Can be configured via
|
||||
:ref:`launch_actions` (:pull:`4618`)
|
||||
|
||||
|
||||
@@ -148,8 +148,10 @@ different shells.
|
||||
|
||||
.. tab:: bash
|
||||
|
||||
For bash, kitty adds a couple of lines to the bottom of :file:`~/.bashrc`
|
||||
(in an atomic manner) to load the shell integration code.
|
||||
For bash, kitty starts bash in POSIX mode and implements the loading of the
|
||||
bash startup files in the integration script itself, after disabling POSIX
|
||||
mode. From the perspective of those scripts there should be no difference
|
||||
to running vanilla bash.
|
||||
|
||||
|
||||
Then, when launching the shell, kitty sets the environment variable
|
||||
|
||||
Reference in New Issue
Block a user