Closed AlexanderZhirov closed 2 years ago
PS1 might be overridden by thinstation.global. Put your PS1 in thinstation.conf.buildtime and see if that works.
Put your PS1 in thinstation.conf.buildtime and see if that works.
Unfortunately, it doesn't work either.
I see PS1 defined in two places. base/etc/ashrc:PS1='\h:\w\$ ' # for busybox base/etc/thinstation.env:PS1='\h:\w\$ ' # for bash
@Thinstation I can change the configuration files, but I don't want to go into the settings of the TS itself. I'm thinking how to change it through my package.
Use sed with a finalize script in your package to update the config inside the new image.
On Fri, May 20, 2022 at 7:00 AM Alexander Zhirov @.***> wrote:
@Thinstation https://github.com/Thinstation I can change the configuration files, but I don't want to go into the settings of the TS itself. I'm thinking how to change it through my package.
— Reply to this email directly, view it on GitHub https://github.com/Thinstation/thinstation/issues/725#issuecomment-1132934214, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAVW47SNVVHYJ5AH4HJKHR3VK6LGVANCNFSM5WNXHAJA . You are receiving this because you were mentioned.Message ID: @.***>
Or keep modified copies of those files in your package.
On Fri, May 20, 2022 at 7:16 AM Donald Cupp @.***> wrote:
Use sed with a finalize script in your package to update the config inside the new image.
On Fri, May 20, 2022 at 7:00 AM Alexander Zhirov @.***> wrote:
@Thinstation https://github.com/Thinstation I can change the configuration files, but I don't want to go into the settings of the TS itself. I'm thinking how to change it through my package.
— Reply to this email directly, view it on GitHub https://github.com/Thinstation/thinstation/issues/725#issuecomment-1132934214, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAVW47SNVVHYJ5AH4HJKHR3VK6LGVANCNFSM5WNXHAJA . You are receiving this because you were mentioned.Message ID: @.***>
Use sed with a finalize script in your package to update the config inside the new image.
Here is such a perversion turned out, but it works!
I put all this in finalize
:
sed -i 's/PS1='\''\\h:\\w\\$ '\''/PS1='\''\\[\\033[38;5;081m\\]\\u\\[\\033[38;5;245m\\]@\\[\\033[38;5;206m\\]\$CLIENT_IP \\[\\033[38;5;245m\\]\\w \\[\\033[38;5;081m\\]\\n # \\[\\e[0m\\]'\''/g' /etc/thinstation.env
sed -i 's/PS1='\''\\h:\\w\\$ '\''/PS1='\''\\[\\033[38;5;081m\\]\\u\\[\\033[38;5;245m\\]@\\[\\033[38;5;206m\\]\$CLIENT_IP \\[\\033[38;5;245m\\]\\w \\[\\033[38;5;081m\\]\\n # \\[\\e[0m\\]'\''/g' /etc/ashrc
P.S. Works by default on the input with ash
.
I want to redefine a variable. I add the installation to the
~/.profile
, but after the launch, the old value remains anyway, although theEDITOR
andXDG_RUNTIME_DIR
is redefined:If I do
source ~/.profile
, then everything is executed