+
    Ki	  c                   sD    R t ^ RIt^ RIHt ^ RIHt R tRR ltRR ltR# )z1Controls execution of programs in separate shellsN)dedent)settingsc                s   \         P                  P                  \        P                  R4      pRVR&   RP                  R VP                  4        4       4      pRP                  V  Uu. uF  pRV,          NK  	  up4      p \        VRR	R
7      ;_uu_ 4       pVP                  \        R4      WV 3,          4       \         P                  ! VR4       RRR4       V# u upi   + '       g   i     T# ; i)zWrite command in a script file and run it.

Running it from a file is likely the only way to set env vars only
for the command (not for the terminal app).
It's also the only reliable way to keep the term open when the
game is quit.
zrun_in_term.shxtermTERM
c              3   <   "   T F  w  rR V: RV: R2x  K  	  R# 5i)export ="z" N Z.0ZkeyZvalue   &  6/usr/lib/python3.14/site-packages/lutris/util/shell.py	<genexpr>Z&get_terminal_script.<locals>.<genexpr>   s     $dXc*#u#u%EXc   Z z"%s"wutf-8Zencodingzm            #!/bin/sh
            cd "%s"
            %s
            exec %s
            exit $?
            i  N)
ospathjoinr   	CACHE_DIRitemsopenwriter    Zchmod)Zcommandcwdenvscript_pathexported_environmentZtokenscript_files   &&&    r   get_terminal_scriptr   	   s     '',,x113CDKCK99$dX[XaXaXc$ddhhG<G5G<=G	k3	1	1[ '2	3	
 	e$ 
2  =	1	1 s   )C;C""C3	c                s   \         P                  P                  \        P                  R4      pRVR&   RP                  R VP                  4        4       4      pT;'       g    / pRP                  R VP                  4        4       4      p\         P                  P                  R4      p\        VRR	R
7      ;_uu_ 4       pVP                  \        RV: RV: RV: RV : R2	4      4       RRR4       V#   + '       g   i     T# ; i)zRReturn a bash prompt configured with pre-defined environment variables and aliasesz	bashrc.shr   r   r   c              3   r   )r   r   "Nr   r	   r
   r   r   #get_bash_rc_file.<locals>.<genexpr>*   s     $cWbee%DWbr   c              3   r   )zalias r   r   Nr   r	   r
   r   r   r   ,   s     `P_*#u#u=P_r   z	~/.bashrcr   r   r   z
            . z

            z
            z
            cd "z"
            N)
r   r   r   r   r   r   Z
expanduserr   r   r    )r   r   aliasesr   r   Zalias_commandsZcurrent_bashrcr   s   &&&     r   get_bash_rc_filer!   &   s    '',,x11;?KCK99$cWZW`W`Wb$ccmmGYY`PWP]P]P_``NWW''4N	k3	1	1[ #("	
 
2$ % 
2	1$ s   ,C77D	c                s8    \        WV4      p\        RRV.W4      # )zgGenerates a scripts whichs opens a bash shell configured with given
environment variables and aliases.
Zbashz--rcfile)r!   r   )r   r   r    Zbashrc_files   &&& r   get_shell_commandr"   C   s$     #3W5K
K@#KK    )N)	Z__doc__r   Ztextwrapr    Zlutrisr   r   r!   r"   r   r#   r   <module>r$      s!    7 	  ::Lr#   